]> git.karo-electronics.de Git - karo-tx-linux.git/commit
xhci: Clarify some expressions in the TRB math
authorPaul Zimmerman <Paul.Zimmerman@synopsys.com>
Sat, 12 Feb 2011 22:06:44 +0000 (14:06 -0800)
committerPaul Gortmaker <paul.gortmaker@windriver.com>
Sun, 26 Jun 2011 16:46:51 +0000 (12:46 -0400)
commitdeee88a9137ec28499aa6882050accee2175d718
tree036b3dbed5e520f6b4e420407ac9e7b52cac965e
parentff719ca689909869e77d9ff0ae99099c7d638500
xhci: Clarify some expressions in the TRB math

commit a2490187011cc2263117626615a581927d19f1d3 upstream.

This makes it easier to spot some problems, which will be fixed by the
next patch in the series. Also change dev_dbg to dev_err in
check_trb_math(), so any math errors will be visible even when running
with debug disabled.

Note: This patch changes the expressions containing
"((1 << TRB_MAX_BUFF_SHIFT) - 1)" to use the equivalent
"(TRB_MAX_BUFF_SIZE - 1)". No change in behavior is intended for
those expressions.

This patch should be queued for stable kernels back to 2.6.31.

[PG: 34 doesn't have count_isoc_trbs_needed() hence this has
 one less instance to change vs. the originating release]

Signed-off-by: Paul Zimmerman <paulz@synopsys.com>
Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
drivers/usb/host/xhci-ring.c