* [U-Boot] [PATCH] common: usb: Adding delay after set configuration to support legacy devices
@ 2015-12-17 9:21 Sriram Dash
2015-12-17 15:18 ` Marek Vasut
0 siblings, 1 reply; 2+ messages in thread
From: Sriram Dash @ 2015-12-17 9:21 UTC (permalink / raw)
To: u-boot
We faced random enumeration failure issue for USB sticks on XHCI driver,
specifically the legacy i.e. USB 2.0 storage devices. It seems they do not
respond to a USB string descriptor submission within the allowed U-Boot
timeout, which is just after sending set configuration.
USB stick where this this problem has been noticed are:
SanDisk U3 Cruzer Micro 0875530C9FC38749 (Vendor: 0x0781, Product 0x5406)
This problem has been reproduced on the Freescale LS2080A, and expected to be
hit for any platform with XHCI controller using legacy USB 2.0 devices.
This patch solves the above problem by:
Adding 10 ms delay after set configuration and let the device to settle down
Signed-off-by: Sriram Dash <sriram.dash@freescale.com>
Signed-off-by: Rajesh Bhagat <rajesh.bhagat@freescale.com>
---
common/usb.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/common/usb.c b/common/usb.c
index 700bfc3..c624a88 100644
--- a/common/usb.c
+++ b/common/usb.c
@@ -1104,6 +1104,7 @@ int usb_select_config(struct usb_device *dev)
"len %d, status %lX\n", dev->act_len, dev->status);
return err;
}
+ mdelay(10); /* Let the SET_CONFIGURATION settle */
debug("new device strings: Mfr=%d, Product=%d, SerialNumber=%d\n",
dev->descriptor.iManufacturer, dev->descriptor.iProduct,
dev->descriptor.iSerialNumber);
--
2.1.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [U-Boot] [PATCH] common: usb: Adding delay after set configuration to support legacy devices
2015-12-17 9:21 [U-Boot] [PATCH] common: usb: Adding delay after set configuration to support legacy devices Sriram Dash
@ 2015-12-17 15:18 ` Marek Vasut
0 siblings, 0 replies; 2+ messages in thread
From: Marek Vasut @ 2015-12-17 15:18 UTC (permalink / raw)
To: u-boot
On Thursday, December 17, 2015 at 10:21:37 AM, Sriram Dash wrote:
> We faced random enumeration failure issue for USB sticks on XHCI driver,
> specifically the legacy i.e. USB 2.0 storage devices. It seems they do not
> respond to a USB string descriptor submission within the allowed U-Boot
> timeout, which is just after sending set configuration.
>
> USB stick where this this problem has been noticed are:
> SanDisk U3 Cruzer Micro 0875530C9FC38749 (Vendor: 0x0781, Product 0x5406)
>
> This problem has been reproduced on the Freescale LS2080A, and expected to
> be hit for any platform with XHCI controller using legacy USB 2.0 devices.
>
> This patch solves the above problem by:
> Adding 10 ms delay after set configuration and let the device to settle
> down
>
> Signed-off-by: Sriram Dash <sriram.dash@freescale.com>
> Signed-off-by: Rajesh Bhagat <rajesh.bhagat@freescale.com>
> ---
> common/usb.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/common/usb.c b/common/usb.c
> index 700bfc3..c624a88 100644
> --- a/common/usb.c
> +++ b/common/usb.c
> @@ -1104,6 +1104,7 @@ int usb_select_config(struct usb_device *dev)
> "len %d, status %lX\n", dev->act_len, dev->status);
> return err;
> }
> + mdelay(10); /* Let the SET_CONFIGURATION settle */
> debug("new device strings: Mfr=%d, Product=%d, SerialNumber=%d\n",
> dev->descriptor.iManufacturer, dev->descriptor.iProduct,
> dev->descriptor.iSerialNumber);
I suppose this should be isolated to USB 3.0 hosts, otherwise it will cause
slowdown on USB < 3.0 hosts as well and that's unwelcome.
Best regards,
Marek Vasut
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-12-17 15:18 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-12-17 9:21 [U-Boot] [PATCH] common: usb: Adding delay after set configuration to support legacy devices Sriram Dash
2015-12-17 15:18 ` Marek Vasut
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox