[PATCH] smp_call_function WARN_ON

From: Zwane Mwaikambo
Date: Sat Aug 14 2004 - 22:03:54 EST


The WARN_ON() is really only true if you're waiting for the other
processors.

Signed-off-by: Zwane Mwaikambo <zwane@xxxxxxxxxxx>

Index: linux-2.6.8-rc4-mm1/arch/i386/kernel/smp.c
===================================================================
RCS file: /home/cvsroot/linux-2.6.8-rc4-mm1/arch/i386/kernel/smp.c,v
retrieving revision 1.1.1.1
diff -u -p -B -r1.1.1.1 smp.c
--- linux-2.6.8-rc4-mm1/arch/i386/kernel/smp.c 10 Aug 2004 14:49:26 -0000 1.1.1.1
+++ linux-2.6.8-rc4-mm1/arch/i386/kernel/smp.c 13 Aug 2004 18:46:11 -0000
@@ -538,7 +538,7 @@ int smp_call_function (void (*func) (voi
}

/* Can deadlock when called with interrupts disabled */
- WARN_ON(irqs_disabled());
+ WARN_ON(wait && irqs_disabled());

data.func = func;
data.info = info;
Index: linux-2.6.8-rc4-mm1/arch/x86_64/kernel/smp.c
===================================================================
RCS file: /home/cvsroot/linux-2.6.8-rc4-mm1/arch/x86_64/kernel/smp.c,v
retrieving revision 1.1.1.1
diff -u -p -B -r1.1.1.1 smp.c
--- linux-2.6.8-rc4-mm1/arch/x86_64/kernel/smp.c 10 Aug 2004 14:49:30 -0000 1.1.1.1
+++ linux-2.6.8-rc4-mm1/arch/x86_64/kernel/smp.c 13 Aug 2004 18:45:54 -0000
@@ -417,7 +417,7 @@ int smp_call_function (void (*func) (voi
return 0;

/* Can deadlock when called with interrupts disabled */
- WARN_ON(irqs_disabled());
+ WARN_ON(wait && irqs_disabled());

data.func = func;
data.info = info;
-
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/