From: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
To: nickpiggin@yahoo.com.au
Cc: linux-kernel@vger.kernel.org, linux-mips@linux-mips.org
Subject: Re: jiffies_64 vs. jiffies
Date: Thu, 02 Mar 2006 01:13:04 +0900 (JST) [thread overview]
Message-ID: <20060302.011304.75185944.anemo@mba.ocn.ne.jp> (raw)
In-Reply-To: <4405B700.1080607@yahoo.com.au>
>>>>> On Thu, 02 Mar 2006 02:00:16 +1100, Nick Piggin <nickpiggin@yahoo.com.au> said:
>> Well, do you mean it should be like this ?
>>
>> jiffies_64++;
>> update_times(jiffies_64);
nick> Yeah. It makes your patch a line smaller too!
Another solution might be simplifying update_times() like this. It
looks there is no point to calculate ticks in update_times().
diff --git a/kernel/timer.c b/kernel/timer.c
index fe3a9a9..6188c99 100644
--- a/kernel/timer.c
+++ b/kernel/timer.c
@@ -906,14 +906,9 @@ void run_local_timers(void)
*/
static inline void update_times(void)
{
- unsigned long ticks;
-
- ticks = jiffies - wall_jiffies;
- if (ticks) {
- wall_jiffies += ticks;
- update_wall_time(ticks);
- }
- calc_load(ticks);
+ wall_jiffies++;
+ update_wall_time(1);
+ calc_load(1);
}
/*
As for long term solution, using an union for jiffies and jiffies_64
would be robust. But it affects so many codes ...
---
Atsushi Nemoto
next prev parent reply other threads:[~2006-03-01 16:13 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-03-01 5:44 Atsushi Nemoto
2006-03-01 12:05 ` Atsushi Nemoto
2006-03-01 12:52 ` Nick Piggin
2006-03-01 14:57 ` Atsushi Nemoto
2006-03-01 15:00 ` Nick Piggin
2006-03-01 16:13 ` Atsushi Nemoto [this message]
2006-03-03 4:06 ` Paul Mackerras
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=20060302.011304.75185944.anemo@mba.ocn.ne.jp \
--to=anemo@mba.ocn.ne.jp \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mips@linux-mips.org \
--cc=nickpiggin@yahoo.com.au \
/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®