diff options
author | Len Brown <len.brown@intel.com> | 2007-08-24 22:19:05 -0400 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2007-08-24 22:19:05 -0400 |
commit | 5a16eff86dc1194a17c69250492e820d828e3bde (patch) | |
tree | a0f990ce8682d7108f6fbd7f9d3c90a8d318d9b8 /init/main.c | |
parent | 2e0f4c7b383063abc274c4a088043383a3735b93 (diff) | |
parent | 61ec7567db103d537329b0db9a887db570431ff4 (diff) |
Pull bugzilla-1641 into release branch
Diffstat (limited to 'init/main.c')
-rw-r--r-- | init/main.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/init/main.c b/init/main.c index d3bcb3b1162..cc0653ec081 100644 --- a/init/main.c +++ b/init/main.c @@ -146,9 +146,14 @@ static unsigned int __initdata max_cpus = NR_CPUS; * greater than 0, limits the maximum number of CPUs activated in * SMP mode to <NUM>. */ +#ifndef CONFIG_X86_IO_APIC +static inline void disable_ioapic_setup(void) {}; +#endif + static int __init nosmp(char *str) { max_cpus = 0; + disable_ioapic_setup(); return 0; } @@ -157,10 +162,13 @@ early_param("nosmp", nosmp); static int __init maxcpus(char *str) { get_option(&str, &max_cpus); - return 1; + if (max_cpus == 0) + disable_ioapic_setup(); + + return 0; } -__setup("maxcpus=", maxcpus); +early_param("maxcpus=", maxcpus); #else #define max_cpus NR_CPUS #endif |