> > Hi Marek,
> 
> Hi,
> 
> sorry for the really late reply.
> 
> >> Does it also work if you 'setenv usb_pgood_delay 2000' ?
> >>
> > No, the USB stick is still not initialized.
> >
> >> Can you include the 5ms patch ?
> >
> > I've attached the patch which makes it work. Of course, I'm not sure if 
> > this is
> the correct way to fix the problem. You can apply the patch on the master
> branch.
> 
> Does this delay have to be added to every control message (unlikely) or to
> some specific control message (likely) ?

The delay is necessary, at least for the requests of type: 
- USB_REQ_GET_STATUS (for the communication with the root)
- USB_REQ_GET_DESCRIPTOR (for the communication with the device)

I added the delay one by one to each message type and without the delay for 
these two, it fails as I described. I created the patch which adds delay for 
all the messages since its simpler and it doesn’t seem to affect the 
performance. 

> 
> Could you try and use the debug() statement in xhci_submit_control_msg() ,
> as well as move the mdelay(5) there , to find out which exact control message
> requires this extra delay ? I also suspect this may not really be related to a
> specific control message, but instead some early part of initialization .

Reply via email to