mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* sleep in microsecond granularity in linux
@ 2011-01-18 23:33 Leo Prasath
  2011-01-19  0:11 ` David Brown
  0 siblings, 1 reply; 2+ messages in thread
From: Leo Prasath @ 2011-01-18 23:33 UTC (permalink / raw)
  To: linux-kernel; +Cc: Yiying Zhang

Hi there,

Is it possible to sleep in granularity of microseconds ?
>From what i know, there is msleep() which can sleep in milliseconds
and there is udelay() which busy waits for time in microsecond
granularity.
But I need to sleep ( not busy wait ) for granularity of microseconds ...

Is there a way to code a new API in linux kernel to allow this ? For
example using interrupts ..
Or is there a way to some external hardware timer cards that issue
interrupts after certain usecs ?

Any help / pointers/ tips will be very appreciated.

Thanks,
-Leo

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

* Re: sleep in microsecond granularity in linux
  2011-01-18 23:33 sleep in microsecond granularity in linux Leo Prasath
@ 2011-01-19  0:11 ` David Brown
  0 siblings, 0 replies; 2+ messages in thread
From: David Brown @ 2011-01-19  0:11 UTC (permalink / raw)
  To: Leo Prasath; +Cc: linux-kernel, Yiying Zhang

On Tue, Jan 18 2011, Leo Prasath wrote:

> Is it possible to sleep in granularity of microseconds ?
> From what i know, there is msleep() which can sleep in milliseconds
> and there is udelay() which busy waits for time in microsecond
> granularity.
> But I need to sleep ( not busy wait ) for granularity of microseconds ...

usleep_range()  See Documentation/timers/timers-howto.txt for info, and
caveats.

David

-- 
Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.

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

end of thread, other threads:[~2011-01-19  0:11 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-01-18 23:33 sleep in microsecond granularity in linux Leo Prasath
2011-01-19  0:11 ` David Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome