[U-Boot] [PATCH v3 2/5] usb: dwc2: Use shared wait_for_bit

Mateusz Kulikowski mateusz.kulikowski at gmail.com
Thu Dec 31 12:31:17 CET 2015


Hi Stefan,

On Sun, Dec 27, 2015 at 11:17:55PM +0100, Stefan Bruens wrote:
> On Sonntag, 27. Dezember 2015 18:28:09 CET Mateusz Kulikowski wrote:
> > Use existing library function to poll bit(s).
> > 
> > Signed-off-by: Mateusz Kulikowski <mateusz.kulikowski at gmail.com>
> 
> It might be useful to have not only a relative timeout, but also an absolute 
> timeout. For dwc2, the timeout handling could be moved from the transactions 
> wrappers to the chunk_msg function. As the USB timeouts are specified for the 
> whole transaction, it would be very neat to calculate one deadline for the 
> whole transaction and hand this absolute timeout to the wait_for_bit(..) 
> function. At the end, this would also result in less code.

This may be a good idea, but I prefer to add it to my todo list (or you can 
do it once this series gets submitted or as dependant patch).

I need wait_for_bit for my board/driver. Doing another set of upgrades 
will delay it.
I will also have access to dwc2 device around mid. Jan so will be able to test
"bigger" refactors.

Is it ok with you?

Regards,
Mateusz


More information about the U-Boot mailing list