public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: andrew may <acmay@acmay.homeip.net>
To: Robert Love <rml@tech9.net>
Cc: mark manning <mark.manning@fastermail.com>, linux-kernel@vger.kernel.org
Subject: Re: nanosleep
Date: Sat, 13 Apr 2002 14:53:06 -0700	[thread overview]
Message-ID: <20020413145306.A29006@ecam.san.rr.com> (raw)
In-Reply-To: <20020410055708.9474.qmail@fastermail.com> <1018418496.903.228.camel@phantasy>

On Wed, Apr 10, 2002 at 02:01:35AM -0400, Robert Love wrote:
> On Wed, 2002-04-10 at 01:57, mark manning wrote:
> > hrm - im confiused now - how can you do a n NANO second delay when the
> > resolution is 10 mili seconds ?
> 
> Uh, you can't - that was his point.

Well there is a cheap trick if you catch what the man page says.
 
> You can try, and you will certainly sleep at least that long, but any
> time given modulo 10ms is out the door ...

Make all your calls to nanasleep be less than 2ms, and loop through as
many as you need until you are under 2ms.

Don't do it for too long because you get no other use out of your machine
while your doing this but it does work.

  reply	other threads:[~2002-04-13 21:53 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-04-10  5:57 nanosleep mark manning
2002-04-10  6:01 ` nanosleep Robert Love
2002-04-13 21:53   ` andrew may [this message]
2002-04-14 20:37     ` nanosleep H. Peter Anvin
  -- strict thread matches above, loose matches on Subject: below --
2002-04-10  4:42 nanosleep mark manning
2002-04-10  5:47 ` nanosleep H. Peter Anvin
2002-04-10  4:41 nanosleep mark manning
2002-04-10  5:57 ` nanosleep Robert Love
2002-04-10  3:22 nanosleep mark manning
2002-04-09 23:24 nanosleep mark manning

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=20020413145306.A29006@ecam.san.rr.com \
    --to=acmay@acmay.homeip.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.manning@fastermail.com \
    --cc=rml@tech9.net \
    /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