From: corbet@lwn.net (Jonathan Corbet)
To: Nishanth Aravamudan <nacc@us.ibm.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [RFC][UPDATE PATCH 2/4] convert soft-timer subsystem to timerintervals
Date: Wed, 18 May 2005 09:59:27 -0600 [thread overview]
Message-ID: <20050518155927.8751.qmail@lwn.net> (raw)
In-Reply-To: Your message of "Wed, 18 May 2005 01:21:41 PDT." <20050518082141.GC4205@us.ibm.com>
Hi, Nishanth,
To my uneducated eye, this patch looks like a useful cleaning-up of the
timer API. I do have one question, though...
> @@ -238,15 +327,41 @@ void add_timer_on(struct timer_list *tim
> check_timer(timer);
>
> spin_lock_irqsave(&base->lock, flags);
> + timer->expires = jiffies_to_timerintervals(timer->expires);
It would appear that, depending on where you are, ->expires can be
expressed in two different units. Users of add_timer() and mod_timer()
are expecting jiffies, but the internal code uses timer intervals. What
happens when somebody does something like this?
mod_timer(&my_timer, my_timer.expires + additional_delay);
Might it be better to store the timerintervals value in a different
field, and leave ->expires as part of the legacy interface only?
jon
Jonathan Corbet
Executive editor, LWN.net
corbet@lwn.net
next prev parent reply other threads:[~2005-05-18 16:04 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-05-14 0:16 [RFC][PATCH (1/7)] new timeofday subsystem (v A5) john stultz
2005-05-14 0:17 ` [RFC][PATCH (2/7)] new timeofday i386 arch specific changes " john stultz
2005-05-14 0:19 ` [RFC][PATCH (3/7)] new timeofday x86-64 " john stultz
2005-05-14 0:20 ` [RFC][PATCH (4/7)] new timeofday i386 and x86-64 timesources " john stultz
2005-05-14 0:22 ` [RFC][PATCH (5/7)] new timeofday ia64,ppc32,ppc64 and s390 arch specific hooks " john stultz
2005-05-14 0:23 ` [RFC][PATCH (6/7)] new timeofday ia64,ppc32,ppc64 and s390 timesources " john stultz
2005-05-14 0:27 ` [RFC][PATCH (7/7)] new timeofday i386 vsyscall proof of concept " john stultz
2005-05-16 21:53 ` john stultz
2005-05-14 19:55 ` IA64 implementation of timesource for new time of day subsystem Christoph Lameter
2005-05-15 10:22 ` James Courtier-Dutton
2005-05-15 10:17 ` Andi Kleen
2005-05-16 15:30 ` Chris Friesen
2005-05-16 17:34 ` john stultz
2005-05-16 18:09 ` Christoph Lameter
2005-05-16 18:45 ` john stultz
2005-05-16 18:55 ` john stultz
2005-05-16 19:24 ` Christoph Lameter
2005-05-16 19:29 ` David Mosberger
2005-05-16 19:50 ` john stultz
2005-05-16 20:27 ` Christoph Lameter
2005-05-16 20:53 ` john stultz
2005-05-16 20:58 ` David Mosberger
2005-05-16 21:35 ` john stultz
2005-05-16 21:53 ` Christoph Lameter
2005-05-17 8:05 ` Ulrich Windl
2005-05-16 18:52 ` [RFC][PATCH (3/7)] new timeofday x86-64 specific changes (v A5) john stultz
2005-05-17 23:33 ` [RFC][PATCH 0/4] new timeofday-based soft-timer subsystem Nishanth Aravamudan
2005-05-17 23:34 ` [RFC][PATCH 1/4] move arch-specific timeofday core to asm Nishanth Aravamudan
2005-05-17 23:36 ` [RFC][PATCH 2/4] convert soft-timer subsystem to timerintervals Nishanth Aravamudan
2005-05-18 8:21 ` [RFC][UPDATE PATCH " Nishanth Aravamudan
2005-05-18 15:59 ` Jonathan Corbet [this message]
2005-05-18 17:00 ` Nishanth Aravamudan
2005-05-17 23:37 ` [RFC][PATCH 3/4] convert sys_nanosleep() to use new soft-timer subsystem Nishanth Aravamudan
2005-05-17 23:38 ` [RFC][PATCH 4/4] support new soft-timer subsystem on non-NEWTOD archs Nishanth Aravamudan
2005-05-19 23:29 ` [RFC][PATCH 0/4] new timeofday-based soft-timer subsystem Nishanth Aravamudan
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=20050518155927.8751.qmail@lwn.net \
--to=corbet@lwn.net \
--cc=linux-kernel@vger.kernel.org \
--cc=nacc@us.ibm.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®