X-Git-Url: http://pilppa.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=kernel%2Fstop_machine.c;h=fcee2a8e6da37a79a02a09a4dfaca30887098292;hb=ea74342900dbe79f2a31ed3609b9e2bdb5c7198c;hp=dcfb5d731466257f7f003ba5eb84083f0185d22c;hpb=67ab33db8be1cd466c09dfcba334d69d3e2f92e6;p=linux-2.6-omap-h63xx.git diff --git a/kernel/stop_machine.c b/kernel/stop_machine.c index dcfb5d73146..fcee2a8e6da 100644 --- a/kernel/stop_machine.c +++ b/kernel/stop_machine.c @@ -1,9 +1,15 @@ -#include -#include -#include +/* Copyright 2005 Rusty Russell rusty@rustcorp.com.au IBM Corporation. + * GPL v2 and any later version. + */ #include #include +#include +#include +#include +#include #include +#include + #include #include #include @@ -41,6 +47,7 @@ static int stopmachine(void *cpu) if (stopmachine_state == STOPMACHINE_DISABLE_IRQ && !irqs_disabled) { local_irq_disable(); + hard_irq_disable(); irqs_disabled = 1; /* Ack: irqs disabled. */ smp_mb(); /* Must read state first. */ @@ -111,7 +118,6 @@ static int stop_machine(void) /* If some failed, kill them all. */ if (ret < 0) { stopmachine_set_state(STOPMACHINE_EXIT); - up(&stopmachine_mutex); return ret; } @@ -121,6 +127,7 @@ static int stop_machine(void) /* Make them disable irqs. */ local_irq_disable(); + hard_irq_disable(); stopmachine_set_state(STOPMACHINE_DISABLE_IRQ); return 0; @@ -206,3 +213,4 @@ int stop_machine_run(int (*fn)(void *), void *data, unsigned int cpu) return ret; } +EXPORT_SYMBOL_GPL(stop_machine_run);