summaryrefslogtreecommitdiffstats
path: root/drivers/usb/host/ehci-dbg.c
diff options
context:
space:
mode:
authorSarah Sharp <sarah.a.sharp@linux.intel.com>2009-11-11 10:28:30 -0800
committerGreg Kroah-Hartman <gregkh@suse.de>2009-12-11 11:55:23 -0800
commit04dd950d92f41155ed0cdf39b6bfbeea22eadb34 (patch)
tree6d88c1b0ae7f2b5bbdebd3d29da77c8e1b3eb39b /drivers/usb/host/ehci-dbg.c
parentf176a5d81214864904d285912da02c4bc0e9041a (diff)
downloadlinux-04dd950d92f41155ed0cdf39b6bfbeea22eadb34.tar.bz2
USB: xhci: Set transfer descriptor size field correctly.
The transfer descriptor (TD) is a series of transfer request buffers (TRBs) that describe the buffer pointer, length, and other characteristics. The xHCI controllers want to know an estimate of how long the TD is, for caching reasons. In each TRB, there is a "TD size" field that provides a rough estimate of the remaining buffers to be transmitted, including the buffer pointed to by that TRB. The TD size is 5 bits long, and contains the remaining size in bytes, right shifted by 10 bits. So a remaining TD size less than 1024 would get a zero in the TD size field, and a remaining size greater than 32767 would get 31 in the field. This patches fixes a bug in the TD_REMAINDER macro that is triggered when the URB has a scatter gather list with a size bigger than 32767 bytes. Not all host controllers pay attention to the TD size field, so the bug will not appear on all USB 3.0 hosts. Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/host/ehci-dbg.c')
0 files changed, 0 insertions, 0 deletions