From: Patrick Wildt <patrick@blueri.se>
To: u-boot@lists.denx.de
Subject: [PATCH 3/3] pci: pcie_dw_rockchip: Use udelay instead of msleep
Date: Tue, 27 Apr 2021 21:27:39 +0200 [thread overview]
Message-ID: <YIhlq6C4nyTuF1Hu@mone.fritz.box> (raw)
In-Reply-To: <CANAwSgRiLTSyo5Hvex7vO=-L+8-ogtqTUXA01ZLqNUF2oF2a1g@mail.gmail.com>
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)
next prev parent reply other threads:[~2021-04-27 19:27 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-26 13:26 [PATCH 1/3] pci: pcie_dw_rockchip: Fixed the below compilation error Anand Moon
2021-04-26 13:26 ` [PATCH 2/3] pci: pcie_dw_rockchip: Drop the unused variable warning Anand Moon
2021-05-21 13:21 ` Kever Yang
2021-04-26 13:26 ` [PATCH 3/3] pci: pcie_dw_rockchip: Use udelay instead of msleep Anand Moon
2021-04-26 20:08 ` Patrick Wildt
2021-04-27 5:41 ` Anand Moon
2021-04-27 19:27 ` Patrick Wildt [this message]
2021-05-06 18:40 ` Anand Moon
2021-05-21 13:20 ` Kever Yang
2021-04-26 20:10 ` [PATCH 1/3] pci: pcie_dw_rockchip: Fixed the below compilation error Patrick Wildt
2021-04-27 5:40 ` Anand Moon
2021-05-21 13:21 ` Kever Yang
2021-05-21 16:58 ` Anand Moon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=YIhlq6C4nyTuF1Hu@mone.fritz.box \
--to=patrick@blueri.se \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox