aboutsummaryrefslogtreecommitdiffstats
path: root/arch/m68knommu/kernel/time.c
diff options
context:
space:
mode:
authorAtsushi Nemoto <anemo@mba.ocn.ne.jp>2006-10-01 02:28:31 -0400
committerLinus Torvalds <torvalds@g5.osdl.org>2006-10-01 03:39:27 -0400
commit8ef386092d7c2891bd7acefb2a87f878f7e9a0d6 (patch)
treeb149f0c63f9b9bb3f43e82097f1ae5972662288f /arch/m68knommu/kernel/time.c
parent70bc42f90a3f4721c89dbe865e6c95da8565b41c (diff)
[PATCH] kill wall_jiffies
With 2.6.18-rc4-mm2, now wall_jiffies will always be the same as jiffies. So we can kill wall_jiffies completely. This is just a cleanup and logically should not change any real behavior except for one thing: RTC updating code in (old) ppc and xtensa use a condition "jiffies - wall_jiffies == 1". This condition is never met so I suppose it is just a bug. I just remove that condition only instead of kill the whole "if" block. [heiko.carstens@de.ibm.com: s390 build fix and cleanup] Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp> Cc: Andi Kleen <ak@muc.de> Cc: Paul Mackerras <paulus@samba.org> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Richard Henderson <rth@twiddle.net> Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru> Cc: Russell King <rmk@arm.linux.org.uk> Cc: Ian Molton <spyro@f2s.com> Cc: Mikael Starvik <starvik@axis.com> Cc: David Howells <dhowells@redhat.com> Cc: Yoshinori Sato <ysato@users.sourceforge.jp> Cc: Hirokazu Takata <takata.hirokazu@renesas.com> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Kyle McMartin <kyle@mcmartin.ca> Cc: Heiko Carstens <heiko.carstens@de.ibm.com> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: Paul Mundt <lethal@linux-sh.org> Cc: Kazumoto Kojima <kkojima@rr.iij4u.or.jp> Cc: Richard Curnow <rc@rc0.org.uk> Cc: William Lee Irwin III <wli@holomorphy.com> Cc: "David S. Miller" <davem@davemloft.net> Cc: Jeff Dike <jdike@addtoit.com> Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it> Cc: Miles Bader <uclinux-v850@lsi.nec.co.jp> Cc: Chris Zankel <chris@zankel.net> Cc: "Luck, Tony" <tony.luck@intel.com> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Roman Zippel <zippel@linux-m68k.org> Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/m68knommu/kernel/time.c')
-rw-r--r--arch/m68knommu/kernel/time.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/arch/m68knommu/kernel/time.c b/arch/m68knommu/kernel/time.c
index db1e1ce0a349..c5667bdddd5e 100644
--- a/arch/m68knommu/kernel/time.c
+++ b/arch/m68knommu/kernel/time.c
@@ -26,8 +26,6 @@
26 26
27#define TICK_SIZE (tick_nsec / 1000) 27#define TICK_SIZE (tick_nsec / 1000)
28 28
29extern unsigned long wall_jiffies;
30
31 29
32static inline int set_rtc_mmss(unsigned long nowtime) 30static inline int set_rtc_mmss(unsigned long nowtime)
33{ 31{
@@ -124,15 +122,12 @@ void time_init(void)
124void do_gettimeofday(struct timeval *tv) 122void do_gettimeofday(struct timeval *tv)
125{ 123{
126 unsigned long flags; 124 unsigned long flags;
127 unsigned long lost, seq; 125 unsigned long seq;
128 unsigned long usec, sec; 126 unsigned long usec, sec;
129 127
130 do { 128 do {
131 seq = read_seqbegin_irqsave(&xtime_lock, flags); 129 seq = read_seqbegin_irqsave(&xtime_lock, flags);
132 usec = mach_gettimeoffset ? mach_gettimeoffset() : 0; 130 usec = mach_gettimeoffset ? mach_gettimeoffset() : 0;
133 lost = jiffies - wall_jiffies;
134 if (lost)
135 usec += lost * (1000000 / HZ);
136 sec = xtime.tv_sec; 131 sec = xtime.tv_sec;
137 usec += (xtime.tv_nsec / 1000); 132 usec += (xtime.tv_nsec / 1000);
138 } while (read_seqretry_irqrestore(&xtime_lock, seq, flags)); 133 } while (read_seqretry_irqrestore(&xtime_lock, seq, flags));