aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/host/xhci.c
diff options
context:
space:
mode:
authorAndiry Xu <andiry.xu@amd.com>2011-05-05 06:14:05 -0400
committerSarah Sharp <sarah.a.sharp@linux.intel.com>2011-05-09 12:34:47 -0400
commit700b41736c07f357df0a1b8f342fd237f365b58d (patch)
tree0cefc9b0136e070a127ffac752ebc7d18a66f9d4 /drivers/usb/host/xhci.c
parentad106f292369d753d5c75751cb9e760726e3cd00 (diff)
xHCI 1.0: TT_THINK_TIME set
xHCI 1.0 spec says the TT Think Time field shall be set to zero if the device is not a High-speed hub. Signed-off-by: Andiry Xu <andiry.xu@amd.com> Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Diffstat (limited to 'drivers/usb/host/xhci.c')
-rw-r--r--drivers/usb/host/xhci.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c
index 6864759c8d1a..3abf33223b1c 100644
--- a/drivers/usb/host/xhci.c
+++ b/drivers/usb/host/xhci.c
@@ -2699,11 +2699,16 @@ int xhci_update_hub_device(struct usb_hcd *hcd, struct usb_device *hdev,
2699 /* Set TT think time - convert from ns to FS bit times. 2699 /* Set TT think time - convert from ns to FS bit times.
2700 * 0 = 8 FS bit times, 1 = 16 FS bit times, 2700 * 0 = 8 FS bit times, 1 = 16 FS bit times,
2701 * 2 = 24 FS bit times, 3 = 32 FS bit times. 2701 * 2 = 24 FS bit times, 3 = 32 FS bit times.
2702 *
2703 * xHCI 1.0: this field shall be 0 if the device is not a
2704 * High-spped hub.
2702 */ 2705 */
2703 think_time = tt->think_time; 2706 think_time = tt->think_time;
2704 if (think_time != 0) 2707 if (think_time != 0)
2705 think_time = (think_time / 666) - 1; 2708 think_time = (think_time / 666) - 1;
2706 slot_ctx->tt_info |= cpu_to_le32(TT_THINK_TIME(think_time)); 2709 if (xhci->hci_version < 0x100 || hdev->speed == USB_SPEED_HIGH)
2710 slot_ctx->tt_info |=
2711 cpu_to_le32(TT_THINK_TIME(think_time));
2707 } else { 2712 } else {
2708 xhci_dbg(xhci, "xHCI version %x doesn't need hub " 2713 xhci_dbg(xhci, "xHCI version %x doesn't need hub "
2709 "TT think time or number of ports\n", 2714 "TT think time or number of ports\n",