summaryrefslogtreecommitdiffstats
path: root/kernel/smp.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2009-03-13 10:47:34 +0100
committerIngo Molnar <mingo@elte.hu>2009-03-13 10:47:34 +0100
commit641cd4cfcdc71ce01535b31cc4d57d59a1fae1fc (patch)
tree84c088d12e68a53cdde2faba49dc01e1b981598b /kernel/smp.c
parent25d500067d5a666d1336598d1b324793554e5496 (diff)
downloadlinux-641cd4cfcdc71ce01535b31cc4d57d59a1fae1fc.tar.bz2
generic-ipi: eliminate WARN_ON()s during oops/panic
Do not output smp-call related warnings in the oops/panic codepath. Reported-by: Jan Beulich <jbeulich@novell.com> Acked-by: Peter Zijlstra <peterz@infradead.org> LKML-Reference: <49B91A7E.76E4.0078.0@novell.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/smp.c')
-rw-r--r--kernel/smp.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/kernel/smp.c b/kernel/smp.c
index 7ad2262d2eca..858baac568ee 100644
--- a/kernel/smp.c
+++ b/kernel/smp.c
@@ -5,6 +5,7 @@
*/
#include <linux/rcupdate.h>
#include <linux/rculist.h>
+#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/percpu.h>
#include <linux/init.h>
@@ -285,7 +286,7 @@ int smp_call_function_single(int cpu, void (*func) (void *info), void *info,
this_cpu = get_cpu();
/* Can deadlock when called with interrupts disabled */
- WARN_ON(irqs_disabled());
+ WARN_ON_ONCE(irqs_disabled() && !oops_in_progress);
if (cpu == this_cpu) {
local_irq_save(flags);
@@ -329,7 +330,7 @@ void __smp_call_function_single(int cpu, struct call_single_data *data,
csd_lock(data);
/* Can deadlock when called with interrupts disabled */
- WARN_ON(wait && irqs_disabled());
+ WARN_ON_ONCE(wait && irqs_disabled() && !oops_in_progress);
generic_exec_single(cpu, data, wait);
}
@@ -365,7 +366,7 @@ void smp_call_function_many(const struct cpumask *mask,
int cpu, next_cpu, this_cpu = smp_processor_id();
/* Can deadlock when called with interrupts disabled */
- WARN_ON(irqs_disabled());
+ WARN_ON_ONCE(irqs_disabled() && !oops_in_progress);
/* So, what's a CPU they want? Ignoring this one. */
cpu = cpumask_first_and(mask, cpu_online_mask);