lkml.org 
[lkml]   [2005]   [May]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRE: 2.6.11 timeval_to_jiffies() wrong for ms resolution timers
Date
From
Awefully sorry about the line-breaks (or absence thereof!)

Stupid Outlook that corporate IT forces us to use!

And I meant 20 ms, not 20 us, of course...

- Bhavesh

Bhavesh P. Davda | Distinguished Member of Technical Staff | Avaya |
1300 West 120th Avenue | B3-B03 | Westminster, CO 80234, U.S.A. |
Voice/Fax: (303) 538-4438 | bhavesh@avaya.com



> -----Original Message-----
> From: Davda, Bhavesh P (Bhavesh)
> Sent: Wednesday, May 25, 2005 1:07 PM
> To: 'Chris Friesen'; 'george@mvista.com'
> Cc: 'linux-kernel@vger.kernel.org'
> Subject: RE: 2.6.11 timeval_to_jiffies() wrong for ms
> resolution timers
>
> > -----Original Message-----
> > From: Chris Friesen [mailto:cfriesen@nortel.com]
> > Sent: Wednesday, May 25, 2005 12:08 PM
> > To: george@mvista.com
> > Cc: Davda, Bhavesh P (Bhavesh); linux-kernel@vger.kernel.org
> > Subject: Re: 2.6.11 timeval_to_jiffies() wrong for ms
> > resolution timers
> >
> > George Anzinger wrote:
> > > Chris Friesen wrote:
> >
> > >> What about telling it to wake up a jiffy earlier, then checking
> > >> whether the scheduling lag was enough to cause it to have
> > waited the
> > >> full specified time. If not, put it to sleep for another jiffy.
> >
> > > The user is, of course, free to do what ever they would like.
> >
> > I actually meant doing this in the kernel.
>
> Ditto.
>
> >
> > > For a
> > > more complete solution you might be interested in HRT (High Res
> > > Timers). See my signature below.
> >
> > Yep. One more patch to apply and worry about versions and
> > maintenance.
> > Not enough of a demand for us to be able to use it, at
> > least at this
> > point.
> >
> > Chris
>
> Ditto ditto :)
>
> BTW, this reminds me an aweful lot of TH2GT2G, and Deep
> Thought taking 7.5 million years to come up with the answer "42!"
>
> Me: Hey Deep Thought! What's 20 us converted into jiffies?
>
> Deep Thought: Let's see: after accounting for all kinds of
> underflow and overflow possibilities, and extending the
> operands to 64-bit to retain the best precision, and
> crunching through a few complex macros, the answer you're
> looking for is... Is... Is... "21!" The real problem is: You
> didn't ask me the right question. You should have asked me
> "What's 19 us converted into jiffies?"
>
> On a more serious note: what is a real-time (read
> SCHED_FIFO/SCHED_RR) task to use to get millisecond accuracy
> wakeup timing services from the kernel? i.e. what are the
> alternatives to setitimer() that wake up the task exactly at
> the interval that is requested of it? You mention high-res
> timers as a possibility, but in the form of a patch. What's
> available in mainline unpatched?
>
> Thanks
>
> - Bhavesh
>
>
>
> Bhavesh P. Davda | Distinguished Member of Technical Staff | Avaya |
> 1300 West 120th Avenue | B3-B03 | Westminster, CO 80234, U.S.A. |
> Voice/Fax: (303) 538-4438 | bhavesh@avaya.com
>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-05-25 21:20    [W:0.888 / U:0.760 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site