powerpc: Call no-longer static setup_nr_cpu_ids instead of replicating it
authorMilton Miller <miltonm@bga.com>
Tue, 10 May 2011 19:28:55 +0000 (19:28 +0000)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Thu, 19 May 2011 04:30:45 +0000 (14:30 +1000)
c1854e00727f50f7ac99e98d26ece04c087ef785 (powerpc: Set nr_cpu_ids early
and use it to free PACAs) copied the formerly static setup_nr_cpu_ids
from init/main.c but 34db18a054c600b6f81787165669dc572fe4de25 (smp:
move smp setup functions to kernel/smp.c) moved it to kernel/smp.c
with a declaration in include/linux/smp.h, so we can call it instead of
replicating it.

Signed-off-by: Milton Miller <miltonm@bga.com>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
arch/powerpc/kernel/setup-common.c

index fce759ba31f3789fac2e27e1a0dc39581ff5e222..ef33a084fcf4ddd24d7535ddfa2ba7dcf110068e 100644 (file)
@@ -510,7 +510,7 @@ void __init smp_setup_cpu_maps(void)
        cpu_init_thread_core_maps(nthreads);
 
        /* Now that possible cpus are set, set nr_cpu_ids for later use */
-       nr_cpu_ids = find_last_bit(cpumask_bits(cpu_possible_mask),NR_CPUS) + 1;
+       setup_nr_cpu_ids();
 
        free_unused_pacas();
 }