From: slash.tmp@free.fr (Mason)
To: linux-arm-kernel@lists.infradead.org
Subject: Guarantee udelay(N) spins at least N microseconds
Date: Sat, 11 Apr 2015 13:57:12 +0200 [thread overview]
Message-ID: <55290C18.8070301@free.fr> (raw)
In-Reply-To: <20150411073022.GJ12732@n2100.arm.linux.org.uk>
On 11/04/2015 09:30, Russell King - ARM Linux wrote:
> On Fri, Apr 10, 2015 at 11:22:56PM +0200, Mason wrote:
>
>> It was you who wrote some time ago: "Timers are preferred
>> because of the problems with the software delay loop."
>> (My system implements DVFS.)
>>
>> It seems to me that a 90 kHz timer is still better than
>> the jiffy counter, or am I mistaken again?
>
> Given the choice of a 90kHz timer vs using a calibrated software
> delay loop, the software delay loop wins. I never envisioned that
> someone would be silly enough to think
I'm full of surprises.
> that a 90kHz timer would somehow be suitable to replace a software
> delay loop calibrated against a timer.
Only one message ago, you were arguing that loop-based delays
could be up to 50% inaccurate. Thus, if one wanted to spin for
500 ?s, they'd have to request 1 ms just to be sure. An 11 ?s
accuracy looks like a better deal to me, overall.
Add DVFS to the mix, and that 500 ?s loop-based delay turns into
a 50 ?s delay when the other core decides to boost the cluster
from 100 MHz to 1 GHz. And then drivers break randomly.
Regards.
next prev parent reply other threads:[~2015-04-11 11:57 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-04-10 11:25 Guarantee udelay(N) spins at least N microseconds Mason
2015-04-10 11:42 ` Willy Tarreau
2015-04-10 14:53 ` Mason
2015-04-10 15:06 ` Willy Tarreau
2015-04-10 11:44 ` Russell King - ARM Linux
2015-04-10 12:41 ` Mason
2015-04-10 15:06 ` Russell King - ARM Linux
2015-04-10 15:30 ` Mason
2015-04-10 16:08 ` Russell King - ARM Linux
2015-04-10 20:01 ` Mason
2015-04-10 20:42 ` Russell King - ARM Linux
2015-04-10 21:22 ` Mason
2015-04-11 7:30 ` Russell King - ARM Linux
2015-04-11 11:57 ` Mason [this message]
2015-04-11 12:10 ` Russell King - ARM Linux
2015-04-11 13:45 ` Mason
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=55290C18.8070301@free.fr \
--to=slash.tmp@free.fr \
--cc=linux-arm-kernel@lists.infradead.org \
/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;
as well as URLs for NNTP newsgroup(s).