diff options
author | Yinghai Lu <yhlu.kernel@gmail.com> | 2008-06-08 18:29:22 -0700 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-06-10 11:32:09 +0200 |
commit | e0da33646826b66ef933d47ea2fb7a693fd849bf (patch) | |
tree | 398d86b96531e574c4710ea1538806b7e0ae0fef /arch/x86/kernel/apic_32.c | |
parent | c3ff01672a23fabb40d4b80ff25a845582fd07c2 (diff) | |
download | linux-e0da33646826b66ef933d47ea2fb7a693fd849bf.tar.bz2 |
x86: introduce max_physical_apicid for bigsmp switching
a multi-socket test-system with 3 or 4 ioapics, when 4 dualcore cpus or
2 quadcore cpus installed, needs to switch to bigsmp or physflat.
CPU apic id is [4,11] instead of [0,7], and we need to check max apic
id instead of cpu numbers.
also add check for 32 bit when acpi is not compiled in or acpi=off.
Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/apic_32.c')
-rw-r--r-- | arch/x86/kernel/apic_32.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/arch/x86/kernel/apic_32.c b/arch/x86/kernel/apic_32.c index c304759f0834..954d67931a50 100644 --- a/arch/x86/kernel/apic_32.c +++ b/arch/x86/kernel/apic_32.c @@ -1518,6 +1518,9 @@ void __cpuinit generic_processor_info(int apicid, int version) */ cpu = 0; + if (apicid > max_physical_apicid) + max_physical_apicid = apicid; + /* * Would be preferable to switch to bigsmp when CONFIG_HOTPLUG_CPU=y * but we need to work other dependencies like SMP_SUSPEND etc @@ -1525,7 +1528,7 @@ void __cpuinit generic_processor_info(int apicid, int version) * if (CPU_HOTPLUG_ENABLED || num_processors > 8) * - Ashok Raj <ashok.raj@intel.com> */ - if (num_processors > 8) { + if (max_physical_apicid >= 8) { switch (boot_cpu_data.x86_vendor) { case X86_VENDOR_INTEL: if (!APIC_XAPIC(version)) { |