From: David Vrabel <dvrabel@cantab.net>
To: Tim Deegan <tim@xen.org>
Cc: xen-devel@lists.xensource.com,
Stefano Stabellini <stefano.stabellini@citrix.com>,
Ian Campbell <ian.campbell@citrix.com>
Subject: Re: [PATCH 02 of 10] arm: implement udelay()
Date: Thu, 23 Feb 2012 19:03:54 +0000 [thread overview]
Message-ID: <4F468D9A.3050000@cantab.net> (raw)
In-Reply-To: <ec051056db2b6d373446.1330018849@whitby.uk.xensource.com>
On 23/02/12 17:40, Tim Deegan wrote:
> arm: implement udelay()
>
> Signed-off-by: Tim Deegan <tim@xen.org>
>
[...]
> diff -r 4a7c14209131 -r ec051056db2b xen/arch/arm/time.c
> --- a/xen/arch/arm/time.c Thu Feb 23 17:39:59 2012 +0000
> +++ b/xen/arch/arm/time.c Thu Feb 23 17:39:59 2012 +0000
> @@ -171,6 +171,16 @@ void __cpuinit init_timer_interrupt(void
> request_irq(30, timer_interrupt, 0, "phytimer", NULL);
> }
>
> +/* Wait a set number of microseconds */
> +void udelay(unsigned long usecs)
> +{
> + s_time_t deadline = get_s_time() + 1000 * (s_time_t) usecs;
> + do {
> + dsb();
> + isb();
What are these barriers for?
David
> + } while ( get_s_time() - deadline < 0 );
> +}
> +
> /*
> * Local variables:
> * mode: C
next prev parent reply other threads:[~2012-02-23 19:03 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-02-23 17:40 [PATCH 00 of 10] arm: SMP boot Tim Deegan
2012-02-23 17:40 ` [PATCH 01 of 10] arm: strip xen binary Tim Deegan
2012-02-23 17:40 ` [PATCH 02 of 10] arm: implement udelay() Tim Deegan
2012-02-23 19:03 ` David Vrabel [this message]
2012-02-27 19:19 ` Tim Deegan
2012-02-23 17:40 ` [PATCH 03 of 10] arm: Move some GIC distributor init out of the per-CPU init function Tim Deegan
2012-02-27 17:32 ` Ian Campbell
2012-02-27 19:30 ` Tim Deegan
2012-02-28 10:24 ` Ian Campbell
2012-02-23 17:40 ` [PATCH 04 of 10] arm: Handle booting on SMP platforms Tim Deegan
2012-02-23 17:40 ` [PATCH 05 of 10] arm: More SMP bringup Tim Deegan
2012-02-23 19:16 ` Ian Campbell
2012-02-27 19:20 ` Tim Deegan
2012-02-23 17:40 ` [PATCH 06 of 10] arm: per-cpu areas Tim Deegan
2012-02-28 10:25 ` Ian Campbell
2012-02-23 17:40 ` [PATCH 07 of 10] arm: start plumbing in SMP bringup in C Tim Deegan
2012-02-28 10:27 ` Ian Campbell
2012-02-23 17:40 ` [PATCH 08 of 10] arm: Boot secondary CPUs into C Tim Deegan
2012-02-28 10:34 ` Ian Campbell
2012-02-23 17:40 ` [PATCH 09 of 10] arm: SMP CPU shutdown Tim Deegan
2012-02-28 10:38 ` Ian Campbell
2012-02-28 18:13 ` Tim Deegan
2012-02-23 17:40 ` [PATCH 10 of 10] arm: Shutdown and reboot Tim Deegan
2012-02-28 10:39 ` Ian Campbell
2012-02-28 10:18 ` [PATCH 00 of 10] arm: SMP boot Ian Campbell
2012-02-29 14:36 ` Ian Campbell
2012-02-29 22:22 ` Tim Deegan
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=4F468D9A.3050000@cantab.net \
--to=dvrabel@cantab.net \
--cc=ian.campbell@citrix.com \
--cc=stefano.stabellini@citrix.com \
--cc=tim@xen.org \
--cc=xen-devel@lists.xensource.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.