summaryrefslogtreecommitdiffstats
path: root/kernel/notifier.c
diff options
context:
space:
mode:
authorPeter Zijlstra <a.p.zijlstra@chello.nl>2010-12-09 14:15:34 +0100
committerIngo Molnar <mingo@elte.hu>2010-12-16 11:17:47 +0100
commit8e92c20183ed0579d94501311b81c42b65cb2129 (patch)
tree3a00ccaf8222c994fd7071129dc357321c10c9df /kernel/notifier.c
parentfe44d62122829959e960bc699318d58966922a69 (diff)
downloadlinux-8e92c20183ed0579d94501311b81c42b65cb2129.tar.bz2
sched: Fix the irqtime code for 32bit
Since the irqtime accounting is using non-atomic u64 and can be read from remote cpus (writes are strictly cpu local, reads are not) we have to deal with observing partial updates. When we do observe partial updates the clock movement (in particular, ->clock_task movement) will go funny (in either direction), a subsequent clock update (observing the full update) will make it go funny in the oposite direction. Since we rely on these clocks to be strictly monotonic we cannot suffer backwards motion. One possible solution would be to simply ignore all backwards deltas, but that will lead to accounting artefacts, most notable: clock_task + irq_time != clock, this inaccuracy would end up in user visible stats. Therefore serialize the reads using a seqcount. Reviewed-by: Venkatesh Pallipadi <venki@google.com> Reported-by: Mikael Pettersson <mikpe@it.uu.se> Tested-by: Mikael Pettersson <mikpe@it.uu.se> Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> LKML-Reference: <1292242434.6803.200.camel@twins> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/notifier.c')
0 files changed, 0 insertions, 0 deletions