All of lore.kernel.org
 help / color / mirror / Atom feed
* RE: Timed wait/sleep
@ 2007-07-07  6:47 Amin Azez
  0 siblings, 0 replies; 8+ messages in thread
From: Amin Azez @ 2007-07-07  6:47 UTC (permalink / raw)
  To: The development of GRUB 2

Donzt beat me for this, but grub2 sounds more like a kernel every day.

I almost want to suggest nicking things from hurd.

Grub2 could even be the init on a minimal hurd setup, surely?

Cough

Sam

-----Original Message-----
From: "Alex Roman" <alex.roman@gmail.com>
To: "The development of GRUB 2" <grub-devel@gnu.org>
Sent: 06/07/07 23:21
Subject: Re: Timed wait/sleep

On 06 Jul 2007 17:04:19 -0500, Haudy Kazemi <kaze0010@umn.edu> wrote:
> On Jul 6 2007, Alex Roman wrote:
> I'd avoid straight loops...with those you run into processor speed
> issues...runs too fast on new CPUs, runs too slow on old hardware. Of
> course I guess you could calibrate some straight loops to the RTC, and then
> use the loops rather than polling the RTC periodically, but I don't think
> the extra level of complication would provide any real benefit.

Yes, I am reluctant to use loops for that reason.

I could definitely do a simple read RTC in a loop until the time
difference from when I started the loop is what I want it to be...

I'll try to get that working, but I am open to other suggestions as well!


Thanks!

-- 
Alex Roman <alex.roman@gmail.com>


_______________________________________________
Grub-devel mailing list
Grub-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/grub-devel




^ permalink raw reply	[flat|nested] 8+ messages in thread
* Timed wait/sleep
@ 2007-07-06 21:57 Alex Roman
  2007-07-06 22:04 ` Haudy Kazemi
  2007-07-22 13:48 ` Marco Gerards
  0 siblings, 2 replies; 8+ messages in thread
From: Alex Roman @ 2007-07-06 21:57 UTC (permalink / raw)
  To: The development of GRUB 2

Hello,

Is there any mechanism to wait/sleep for a specified time in GRUB?

The reason I need something like this is that, for the ATA driver I am
working on, I need to be able to wait for a memory mapped register to
change, but I don't want to wait indefinitely. I'd like to be able to
have some sort of loop that will read the register, say, 10 times,
with 10 ms pause in between the reads...

I've searched for this and wasn't able to find anything in the source code...

If there isn't one, what would be the best way to implement something
like this? Perhaps using the RTC, or straight loops? Would there be
any use, besides my driver, in developing an RTC interface?


Thanks!

-- 
Alex Roman <alex.roman@gmail.com>



^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2007-07-22 22:34 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-07-07  6:47 Timed wait/sleep Amin Azez
  -- strict thread matches above, loose matches on Subject: below --
2007-07-06 21:57 Alex Roman
2007-07-06 22:04 ` Haudy Kazemi
2007-07-06 22:21   ` Alex Roman
2007-07-07 10:29     ` Jan C. Kleinsorge
2007-07-22 13:48 ` Marco Gerards
2007-07-22 21:38   ` Alex Roman
2007-07-22 22:33     ` Jeroen Dekkers

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.