
Hi Patrick,
On Wed, 28 Apr 2021 at 00:57, Patrick Wildt patrick@blueri.se wrote:
Am Tue, Apr 27, 2021 at 11:11:19AM +0530 schrieb Anand Moon:
hi Patrick,
On Tue, 27 Apr 2021 at 01:38, Patrick Wildt patrick@blueri.se wrote:
Am Mon, Apr 26, 2021 at 01:26:32PM +0000 schrieb Anand Moon:
Use udelay instead of msleep fix the below warning.
You sure that's correct? the m in msleep means milli, while the u in udelay means micro. That's a factor of 1000 of a difference.
Thanks for your review comments.
Most of the u-boot driver prefers udelay and usleep_range internally calls udelay.
I don't have the HW to test and verify.
-Anand
Sure, I'm not complaining about that. My point is that if you pass e. g. 8 milliseconds to a function that takes microseconds, you need to add the factor.
Not good: msleep(1000) -> udelay(1000) Much better: msleep(1000) -> udelay(1000 * 1000)
Which also means that you either have to rename PERST_WAIT_MS and change its value, or do udelay(PERST_WAIT_MS * 1000)
Thanks for this tip, can we use mdelay as sugged above. . static inline void mdelay(unsigned long msec) { udelay(1000 * msec); }
Thanks -Anand