aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/timer.c
diff options
context:
space:
mode:
authorAtsushi Nemoto <anemo@mba.ocn.ne.jp>2006-03-06 18:42:51 -0500
committerLinus Torvalds <torvalds@g5.osdl.org>2006-03-06 21:40:44 -0500
commit5aee405c662ca644980c184774277fc6d0769a84 (patch)
treee8a74f57b4866e2ab0f6adac5dec174e8dbf17c0 /kernel/timer.c
parenta615fa83959896f8eac76c235953fb164cd1a9b9 (diff)
[PATCH] time: add barrier after updating jiffies_64
Add a compiler barrier so that we don't read jiffies before updating jiffies_64. Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Paul Mackerras <paulus@samba.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'kernel/timer.c')
-rw-r--r--kernel/timer.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/kernel/timer.c b/kernel/timer.c
index 8256f3f5ec0d..bf7c4193b936 100644
--- a/kernel/timer.c
+++ b/kernel/timer.c
@@ -941,6 +941,8 @@ static inline void update_times(void)
941void do_timer(struct pt_regs *regs) 941void do_timer(struct pt_regs *regs)
942{ 942{
943 jiffies_64++; 943 jiffies_64++;
944 /* prevent loading jiffies before storing new jiffies_64 value. */
945 barrier();
944 update_times(); 946 update_times();
945 softlockup_tick(regs); 947 softlockup_tick(regs);
946} 948}