Messages in this thread | | | Subject | Re: linux-next: PowerPC WARN_ON_ONCE() after merge of the final tree (tip related) | From | Peter Zijlstra <> | Date | Fri, 16 Apr 2010 12:38:43 +0200 |
| |
On Thu, 2010-04-15 at 19:15 +0200, Frederic Weisbecker wrote: > > that looks rather ugly. Why not do a raw: > > > > this_cpu_inc(lockdep_stats.redundant_hardirqs_on); > > > > which basically open-codes debug_atomic_inc(), but without the warning? > > > Because that would open a race against interrupts that might > touch lockdep_stats.redundant_hardirqs_on too.
How so, its a pure per-cpu variable right? so either the increment happens before the interrupts hits, or after, in either case there should not be a race with interrupts.
| |