]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
[POWERPC] Fix breakage caused by 72486f1f8f0a2bc828b9d30cf4690cf2dd6807fc
authorGiuliano Pochini <pochini@shiny.it>
Tue, 27 Mar 2007 05:40:28 +0000 (21:40 -0800)
committerPaul Mackerras <paulus@samba.org>
Thu, 12 Apr 2007 17:55:16 +0000 (03:55 +1000)
72486f1f8f0a2bc828b9d30cf4690cf2dd6807fc inverted the sense for enabling
hotplug CPU controls without reference to any other architecture other than
i386, ia64 and PowerPC.  This left everyone else without hotplug CPU control.

Fix powerpc for this brain damage.

(akpm: patch adapted from rmk's ARM fix.  Changelog stolen from rmk)

Signed-off-by: Giuliano Pochini <pochini@shiny.it>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Russell King <rmk@arm.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
arch/powerpc/kernel/setup_32.c

index f688548f74cd7e0f8a2b2938e7386e2581dfbec0..35f8f443c14f6c9dd383d967889577c9588d4363 100644 (file)
@@ -196,18 +196,22 @@ EXPORT_SYMBOL(nvram_sync);
 
 #endif /* CONFIG_NVRAM */
 
-static struct cpu cpu_devices[NR_CPUS];
+static DEFINE_PER_CPU(struct cpu, cpu_devices);
 
 int __init ppc_init(void)
 {
-       int i;
+       int cpu;
 
        /* clear the progress line */
-       if ( ppc_md.progress ) ppc_md.progress("             ", 0xffff);
+       if (ppc_md.progress)
+               ppc_md.progress("             ", 0xffff);
 
        /* register CPU devices */
-       for_each_possible_cpu(i)
-               register_cpu(&cpu_devices[i], i);
+       for_each_possible_cpu(cpu) {
+               struct cpu *c = &per_cpu(cpu_devices, cpu);
+               c->hotpluggable = 1;
+               register_cpu(c, cpu);
+       }
 
        /* call platform init */
        if (ppc_md.init != NULL) {