Re: [U-Boot] [PATCH] usb: r8a66597: Add support for RZ/A series

2017-11-29 Thread Marek Vasut
On 11/29/2017 04:28 PM, Chris Brandt wrote: > On Tuesday, November 28, 2017, Marek Vasut wrote: > So, I can't use wait_for_bit() Can we somehow extend wait_for_bit() ? >>> >>> It's a nice function, so it would be good if it worked with more than >>> just 32-bit registers. >>> >>>

Re: [U-Boot] [PATCH] usb: r8a66597: Add support for RZ/A series

2017-11-29 Thread Chris Brandt
On Tuesday, November 28, 2017, Marek Vasut wrote: > >>> So, I can't use wait_for_bit() > >> > >> Can we somehow extend wait_for_bit() ? > > > > It's a nice function, so it would be good if it worked with more than > > just 32-bit registers. > > > > However, it's used in 98 places at the moment, so

Re: [U-Boot] [PATCH] usb: r8a66597: Add support for RZ/A series

2017-11-28 Thread Marek Vasut
On 11/28/2017 01:07 PM, Chris Brandt wrote: > On Monday, November 27, 2017 1, Marek Vasut wrote: >>> wait_for_bit() wants you to pass a direct address of a 32-bit register. >>> The register I am waiting for is a 16-bit register and the hardware >>> manual doesn't say 32-bit is allowed. >>> When I

Re: [U-Boot] [PATCH] usb: r8a66597: Add support for RZ/A series

2017-11-28 Thread Chris Brandt
On Monday, November 27, 2017 1, Marek Vasut wrote: > > wait_for_bit() wants you to pass a direct address of a 32-bit register. > > The register I am waiting for is a 16-bit register and the hardware > > manual doesn't say 32-bit is allowed. > > When I do a 32-bit read on that address, I actually

Re: [U-Boot] [PATCH] usb: r8a66597: Add support for RZ/A series

2017-11-27 Thread Marek Vasut
On 11/27/2017 06:27 PM, Chris Brandt wrote: > Hello Marek, > > On Friday, November 17, 2017, Marek Vasut wrote: >>> +#ifdef RZA_USB >>> + dcpctr = r8a66597_read(r8a66597, DCPCTR); >> >> use wait_for_bit() . >> >>> + if ((dcpctr & PID) == PID_BUF) { >>> + timeout2 = 1; >>> +

Re: [U-Boot] [PATCH] usb: r8a66597: Add support for RZ/A series

2017-11-27 Thread Chris Brandt
Hello Marek, On Friday, November 17, 2017, Marek Vasut wrote: > > +#ifdef RZA_USB > > + dcpctr = r8a66597_read(r8a66597, DCPCTR); > > use wait_for_bit() . > > > + if ((dcpctr & PID) == PID_BUF) { > > + timeout2 = 1; > > + while (!(dcpctr & BSTS)) { > > +

Re: [U-Boot] [PATCH] usb: r8a66597: Add support for RZ/A series

2017-11-18 Thread Marek Vasut
On 11/17/2017 08:56 PM, Chris Brandt wrote: > Thanks for the review. > > On Friday, November 17, 2017, Marek Vasut wrote: >>> +#ifndef RZA_USB >> >> This should be turned into Kconfig entry, some CONFIG_... > > So you want RZA_USB in Kconfig, but is it OK if it is automatically > selected when

Re: [U-Boot] [PATCH] usb: r8a66597: Add support for RZ/A series

2017-11-17 Thread Chris Brandt
Thanks for the review. On Friday, November 17, 2017, Marek Vasut wrote: > > +#ifndef RZA_USB > > This should be turned into Kconfig entry, some CONFIG_... So you want RZA_USB in Kconfig, but is it OK if it is automatically selected when an RZ/A device is selected? For example: config

Re: [U-Boot] [PATCH] usb: r8a66597: Add support for RZ/A series

2017-11-17 Thread Marek Vasut
On 11/13/2017 10:21 PM, Chris Brandt wrote: > While the USB HW in the RZ/A is basically the same, there are some > differences from the original versions that were in the SH4 SoCs. > > Signed-off-by: Chris Brandt > --- > drivers/usb/host/r8a66597-hcd.c | 46 >

[U-Boot] [PATCH] usb: r8a66597: Add support for RZ/A series

2017-11-13 Thread Chris Brandt
While the USB HW in the RZ/A is basically the same, there are some differences from the original versions that were in the SH4 SoCs. Signed-off-by: Chris Brandt --- drivers/usb/host/r8a66597-hcd.c | 46 +