diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2010-11-30 12:21:30 +0000 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2010-12-20 15:09:11 +0000 |
commit | f36d340122ae8744e64af0a92a6f77b97542c0a4 (patch) | |
tree | 85f7d8dc6d1407ea0fd7b3673a8b9ce0ec9d7507 /arch/arm | |
parent | bbc81fd4327f9ed4480b05981e38acd48b1d184a (diff) | |
download | blackbird-op-linux-f36d340122ae8744e64af0a92a6f77b97542c0a4.tar.gz blackbird-op-linux-f36d340122ae8744e64af0a92a6f77b97542c0a4.zip |
ARM: CPU hotplug: ensure correct ordering of unplug
Don't call idle_task_exit() with interrupts disabled, and ensure
that we have a memory barrier after interrupts are disabled but
before signalling that this CPU has shut down.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/kernel/smp.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/arm/kernel/smp.c b/arch/arm/kernel/smp.c index 8c81ff9b3732..1a1c5e2b3ef9 100644 --- a/arch/arm/kernel/smp.c +++ b/arch/arm/kernel/smp.c @@ -269,9 +269,11 @@ void __ref cpu_die(void) { unsigned int cpu = smp_processor_id(); - local_irq_disable(); idle_task_exit(); + local_irq_disable(); + mb(); + /* Tell __cpu_die() that this CPU is now safe to dispose of */ complete(&cpu_died); |