]> err.no Git - linux-2.6/commitdiff
[PATCH] x86_64: Don't reserve hotplug CPUs by default
authorAndi Kleen <ak@suse.de>
Wed, 11 Jan 2006 21:42:35 +0000 (22:42 +0100)
committerLinus Torvalds <torvalds@g5.osdl.org>
Thu, 12 Jan 2006 03:01:11 +0000 (19:01 -0800)
Most users don't need it so no need to waste memory.
This means an user has to specify the appropiate number of
hotplug CPUs on the command line with additional_cpus=...
or fix their BIOS to follow the convention in
Documentation/x86-64/cpu-hotplug-spec

Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Documentation/x86_64/boot-options.txt
arch/x86_64/kernel/smpboot.c

index e566affeed7f49e7b3a66f4d516a9c380805d63a..72ab9b99b22c822f160f7e95fdd5d2d4613c3ee9 100644 (file)
@@ -125,7 +125,7 @@ SMP
   cpumask=MASK   only use cpus with bits set in mask
 
   additional_cpus=NUM Allow NUM more CPUs for hotplug
-                (defaults are specified by the BIOS or half the available CPUs)
+                (defaults are specified by the BIOS, see Documentation/x86_64/cpu-hotplug-spec)
 
 NUMA
 
index ecbd7b83acc1ff7b9024d6de6fd1762ed58320f0..043b1d262a3051bd0fcdea03f15d6c80838234bc 100644 (file)
@@ -927,8 +927,8 @@ int additional_cpus __initdata = -1;
  *
  * Three ways to find out the number of additional hotplug CPUs:
  * - If the BIOS specified disabled CPUs in ACPI/mptables use that.
- * - otherwise use half of the available CPUs or 2, whatever is more.
  * - The user can overwrite it with additional_cpus=NUM
+ * - Otherwise don't reserve additional CPUs.
  * We do this because additional CPUs waste a lot of memory.
  * -AK
  */
@@ -938,13 +938,10 @@ __init void prefill_possible_map(void)
        int possible;
 
        if (additional_cpus == -1) {
-               if (disabled_cpus > 0) {
+               if (disabled_cpus > 0)
                        additional_cpus = disabled_cpus;
-               } else {
-                       additional_cpus = num_processors / 2;
-                       if (additional_cpus == 0)
-                               additional_cpus = 2;
-               }
+               else
+                       additional_cpus = 0;
        }
        possible = num_processors + additional_cpus;
        if (possible > NR_CPUS)