summaryrefslogtreecommitdiffstats
path: root/kernel/timer.c
diff options
context:
space:
mode:
authorAtsushi Nemoto <anemo@mba.ocn.ne.jp>2006-03-06 15:42:51 -0800
committerLinus Torvalds <torvalds@g5.osdl.org>2006-03-06 18:40:44 -0800
commit5aee405c662ca644980c184774277fc6d0769a84 (patch)
treee8a74f57b4866e2ab0f6adac5dec174e8dbf17c0 /kernel/timer.c
parenta615fa83959896f8eac76c235953fb164cd1a9b9 (diff)
downloadblackbird-op-linux-5aee405c662ca644980c184774277fc6d0769a84.tar.gz
blackbird-op-linux-5aee405c662ca644980c184774277fc6d0769a84.zip
[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)
void do_timer(struct pt_regs *regs)
{
jiffies_64++;
+ /* prevent loading jiffies before storing new jiffies_64 value. */
+ barrier();
update_times();
softlockup_tick(regs);
}
OpenPOWER on IntegriCloud