[EXT] Re: [PATCH v1] T1024RDB: USB: Add a 10808 us delay in usb_scan_port
Yinbo Zhu
yinbo.zhu at nxp.com
Wed Dec 18 04:27:49 CET 2019
-----Original Message-----
From: Marek Vasut <marex at denx.de>
Sent: 2019年12月16日 16:33
To: Bin Meng <bmeng.cn at gmail.com>; Yinbo Zhu <yinbo.zhu at nxp.com>
Cc: U-Boot Mailing List <u-boot at lists.denx.de>; Peter Chen <peter.chen at nxp.com>; Xiaobo Xie <xiaobo.xie at nxp.com>; Joe Hershberger <joe.hershberger at ni.com>; Jiafei Pan <jiafei.pan at nxp.com>; Ran Wang <ran.wang_1 at nxp.com>; Jun Li <jun.li at nxp.com>
Subject: [EXT] Re: [PATCH v1] T1024RDB: USB: Add a 10808 us delay in usb_scan_port
Caution: EXT Email
On 12/16/19 4:17 AM, Bin Meng wrote:
> +Marek,
>
> On Mon, Dec 16, 2019 at 11:13 AM Yinbo Zhu <yinbo.zhu at nxp.com> wrote:
>>
>> T1024RDB usb controller doesn't detect usb device at first usb start
>> Add a delay that is greater than 10808 us can fix that issue, which
>> delay if is less than 10808 us, issue is probabilistic occurrence
>>
>> => usb start
>> starting USB...
>> USB0: USB EHCI 1.00
>> USB1: USB EHCI 1.00
>> scanning bus 0 for devices... 1 USB Device(s) found scanning bus 1
>> for devices... 1 USB Device(s) found
>> scanning usb for storage devices... 0 Storage Device(s) found
>> => usb stop stopping USB..
>> => usb start
>> starting USB...
>> USB0: USB EHCI 1.00
>> USB1: USB EHCI 1.00
>> scanning bus 0 for devices... 2 USB Device(s) found scanning bus 1
>> for devices... 1 USB Device(s) found
>> scanning usb for storage devices... 1 Storage Device(s) found
>> =>
>>
>> Signed-off-by: Yinbo Zhu <yinbo.zhu at nxp.com>
>> ---
>> common/usb_hub.c | 3 +++
>> 1 file changed, 3 insertions(+)
>>
>> diff --git a/common/usb_hub.c b/common/usb_hub.c index
>> 33aaeb8e44..6dd06696b2 100644
>> --- a/common/usb_hub.c
>> +++ b/common/usb_hub.c
>> @@ -486,6 +486,9 @@ static int usb_scan_port(struct usb_device_scan *usb_scan)
>> return 0;
>> }
>>
>> +#ifdef CONFIG_TARGET_T1024RDB
>> + udelay(10808);
>> +#endif
>
> This looks like a workaround. Is this a silicon errata?
> Does setting usb_pgood_delay to e.g. 2000 help ?
Hi Marek Casut,
Thanks your feedback, I test it 2000, usb start can list device, in fact, 120 is enough,
In addition, if it is some usb storage issue, I think add it into bootargs it is reasonable, but I test some usb storage,
It is all encounter issue, so I think add it that delay into usb driver code.
=> setenv usb_pgood_delay 120
=> usb start
starting USB...
USB0: USB EHCI 1.00
USB1: USB EHCI 1.00
scanning bus 0 for devices... 2 USB Device(s) found
scanning bus 1 for devices... 1 USB Device(s) found
scanning usb for storage devices... 1 Storage Device(s) found
=>
Thanks,
Yinbo
More information about the U-Boot
mailing list