[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>
This commit is contained in:
parent
a615fa8395
commit
5aee405c66
1 changed files with 2 additions and 0 deletions
|
@ -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);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue