From: Marek Vasut Date: Wed, 29 Nov 2017 03:54:50 +0100 Subject: [U-Boot] [PATCH] usb: r8a66597: Add support for RZ/A series In-Reply-To: References: <20171113212118.10843-1-chris.brandt@renesas.com> <12919cb0-14cc-811e-6a4d-1495171f4b9a@gmail.com> <86e3ed13-96f4-6a57-11fe-a0d4ecc929a5@denx.de> Message-ID: List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de 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 do a 32-bit read on that address, I actually get a different >>> value. >>> >>> For example: >>> >>> => md.w E8010060 1 >>> e8010060: 0040 >>> => md.l E8010060 1 >>> e8010060: 00400000 >>> >>> >>> 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 coordinating modifying > all those changes at once might be an issue. What about readb_poll_timeout() , would that work ? > Chris > -- Best regards, Marek Vasut