Re: [PATCH] [2/2] Don't complain about disabled irqs when the system has paniced

From: Pavel Machek
Date: Fri Sep 12 2008 - 15:52:45 EST


Hi!

> panic calls smp_send_stop which eventually calls smp_call_function_*.
> smp_call_function warns about disabled interrupts. But it's legal
> to call panic in this case. When this happens panic() prints
> several ugly backtraces. So don't check for disabled interrupts
> in panic state.
>
> Signed-off-by: Andi Kleen <ak@xxxxxxxxxxxxxxx>
...

> /* Can deadlock when called with interrupts disabled */
> - WARN_ON(irqs_disabled());
> + WARN_ON(system_state < SYSTEM_PANIC && irqs_disabled());

Nice trap if someone adds state after panic... replace < with !=?

--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/