From: Matthijs Kooijman Date: Thu, 3 Oct 2013 07:46:25 +0000 (+0200) Subject: staging: dwc2: Make dwc2_hw_params.host_channels large enough X-Git-Tag: omap-for-v3.13/fixes-for-merge-window-take2~62^2~510 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2d1155478fb6f972b3a97cbf13151ee4f078a164;p=pandora-kernel.git staging: dwc2: Make dwc2_hw_params.host_channels large enough The hardware offers a 4-bit register containing the number of host channels. However, the values of these register mean 1-16 host channels, not 0-15. Since the dwc2_hw_params struct stores the actual number of host channels supported instead of the raw register value, it should be 5 bits wide instead of 4. Before this commit, hardware with 16 host channels would overflow the field, making it appear as 0 channels. This bug was introduced in commit 9badec2 (staging: dwc2: interpret all hwcfg and related register at init time). Reported-by: Dinh Nguyen Signed-off-by: Matthijs Kooijman Acked-by: Paul Zimmerman Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed