This second version fixes the ifdeffery issues reported by Paolo Bonzini and includes Rick's reviewed-by tags.
I also intended to include Peterz's patch for lockdep assertion on irqs disabled but unfortunately I get false positives as irqs_disabled() doesn't always imply !current->hardirqs_enabled. This seems to happen during the boot with IRQs interrupting lockdep internals while current->lockdep_recursion == 1. Therefore the trace_hardirqs_off() on x86 IRQ entry gets ignored. I'll investigate further and try to get that fixed in order to introduce lockdep_assert_irqs_disabled() properly but that's outside the scope of this patchset now. git://git.kernel.org/pub/scm/linux/kernel/git/frederic/linux-dynticks.git sched/irqtime-v2 HEAD: e336b2491bf02e95ff3387e7d7a8276b22c8b5f3 Thanks, Frederic --- Frederic Weisbecker (5): irqtime: No need for preempt-safe accessors irqtime: Remove needless IRQs disablement on kcpustat update u64_stats: Introduce IRQs disabled helpers irqtime: Consolidate accounting synchronization with u64_stats API irqtime: Consolidate irqtime flushing code include/linux/u64_stats_sync.h | 45 +++++++++++++++++++---------------- kernel/sched/cputime.c | 54 ++++++++++++++++++------------------------ kernel/sched/sched.h | 53 ++++++++++++----------------------------- 3 files changed, 62 insertions(+), 90 deletions(-)