X-Git-Url: https://git.karo-electronics.de/?a=blobdiff_plain;f=kernel%2Fsoftlockup.c;h=50afeb813305d76435e8c6852a80b5b9dc5c8cd9;hb=3e1fbd12c958591695f89b11f9c6ec08d002e358;hp=6b76caa229818811f61aaacf16afd9c2b6da5dc5;hpb=0a1340c185734a57fbf4775927966ad4a1347b02;p=mv-sheeva.git diff --git a/kernel/softlockup.c b/kernel/softlockup.c index 6b76caa2298..50afeb81330 100644 --- a/kernel/softlockup.c +++ b/kernel/softlockup.c @@ -104,7 +104,7 @@ static int watchdog(void * __bind_cpu) /* * Create/destroy watchdog threads as CPUs come and go: */ -static int __devinit +static int __cpuinit cpu_callback(struct notifier_block *nfb, unsigned long action, void *hcpu) { int hotcpu = (unsigned long)hcpu; @@ -142,15 +142,16 @@ cpu_callback(struct notifier_block *nfb, unsigned long action, void *hcpu) return NOTIFY_OK; } -static struct notifier_block __devinitdata cpu_nfb = { +static struct notifier_block __cpuinitdata cpu_nfb = { .notifier_call = cpu_callback }; __init void spawn_softlockup_task(void) { void *cpu = (void *)(long)smp_processor_id(); + int err = cpu_callback(&cpu_nfb, CPU_UP_PREPARE, cpu); - cpu_callback(&cpu_nfb, CPU_UP_PREPARE, cpu); + BUG_ON(err == NOTIFY_BAD); cpu_callback(&cpu_nfb, CPU_ONLINE, cpu); register_cpu_notifier(&cpu_nfb);