Messages in this thread | | | Date | Fri, 21 Dec 2007 01:44:16 +0100 | From | Ingo Molnar <> | Subject | Re: Linux 2.6.24-rc5 x86 architecture no longer Oopses... |
| |
* Andrew Morton <akpm@linux-foundation.org> wrote:
> > + raw_local_irq_save(flags); > > __raw_spin_lock(&die.lock); > > - raw_local_save_flags(flags); > > die.lock_owner = smp_processor_id(); > > die.lock_owner_depth = 0; > > bust_spinlocks(1); > > - } > > - else > > - raw_local_save_flags(flags); > > + } else > > + raw_local_irq_save(flags); > > > > if (++die.lock_owner_depth < 3) { > > unsigned long esp; > > Looks sane. > > I suppose there's some reason why we can't just use > spin_lock_irqsave(). But that reason was either so obvious or so > unimportant that a comment was not needed. Sigh.
bug was introduced via:
commit 39743c9ef717fd4f2b5583f010115c5f2482b8ae Author: Andi Kleen <ak@suse.de> Date: Fri Oct 19 20:35:03 2007 +0200
x86: use raw locks during oopses
- spin_lock_irqsave(&die.lock, flags); + __raw_spin_lock(&die.lock); + raw_local_save_flags(flags);
that is not a correct open-coding of spin_lock_irqsave(): both the ordering is wrong (irqs should be disabled _first_), and the wrong flags-saving API was used.
so this is a post-2.6.23 regression and the fix is (now) obvious.
Ingo
| |