summaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
authorNick Piggin <nickpiggin@yahoo.com.au>2004-10-18 09:10:25 -0700
committerLinus Torvalds <torvalds@ppc970.osdl.org>2004-10-18 09:10:25 -0700
commit71da3667be80d30121df3972caa0bf5684228379 (patch)
treef8b78f7547dc91abfe337fd255b76dccf5ab655e /kernel
parent0298ac9c9b2bab88cd64d0ab6f60044c841ff746 (diff)
[PATCH] sched: hotplug add a CPU_DOWN_FAILED notifier
Introduce CPU_DOWN_FAILED notifier, so we can cope with a failure after a CPU_DOWN_PREPARE notice. This fixes 3/8 "add CPU_DOWN_PREPARE notifier" to be useful Signed-off-by: Nick Piggin <nickpiggin@yahoo.com.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/cpu.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/kernel/cpu.c b/kernel/cpu.c
index 84e78a6560bc..719ba42ff5ee 100644
--- a/kernel/cpu.c
+++ b/kernel/cpu.c
@@ -141,6 +141,11 @@ int cpu_down(unsigned int cpu)
p = __stop_machine_run(take_cpu_down, NULL, cpu);
if (IS_ERR(p)) {
+ /* CPU didn't die: tell everyone. Can't complain. */
+ if (notifier_call_chain(&cpu_chain, CPU_DOWN_FAILED,
+ (void *)(long)cpu) == NOTIFY_BAD)
+ BUG();
+
err = PTR_ERR(p);
goto out_allowed;
}