diff options
Diffstat (limited to 'arch/i386/kernel/alternative.c')
-rw-r--r-- | arch/i386/kernel/alternative.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/arch/i386/kernel/alternative.c b/arch/i386/kernel/alternative.c index d8cda14fff8b..0695be538de5 100644 --- a/arch/i386/kernel/alternative.c +++ b/arch/i386/kernel/alternative.c | |||
@@ -5,9 +5,8 @@ | |||
5 | #include <asm/alternative.h> | 5 | #include <asm/alternative.h> |
6 | #include <asm/sections.h> | 6 | #include <asm/sections.h> |
7 | 7 | ||
8 | static int noreplace_smp = 0; | 8 | #ifdef CONFIG_HOTPLUG_CPU |
9 | static int smp_alt_once = 0; | 9 | static int smp_alt_once; |
10 | static int debug_alternative = 0; | ||
11 | 10 | ||
12 | static int __init bootonly(char *str) | 11 | static int __init bootonly(char *str) |
13 | { | 12 | { |
@@ -15,6 +14,11 @@ static int __init bootonly(char *str) | |||
15 | return 1; | 14 | return 1; |
16 | } | 15 | } |
17 | __setup("smp-alt-boot", bootonly); | 16 | __setup("smp-alt-boot", bootonly); |
17 | #else | ||
18 | #define smp_alt_once 1 | ||
19 | #endif | ||
20 | |||
21 | static int debug_alternative; | ||
18 | 22 | ||
19 | static int __init debug_alt(char *str) | 23 | static int __init debug_alt(char *str) |
20 | { | 24 | { |
@@ -23,6 +27,8 @@ static int __init debug_alt(char *str) | |||
23 | } | 27 | } |
24 | __setup("debug-alternative", debug_alt); | 28 | __setup("debug-alternative", debug_alt); |
25 | 29 | ||
30 | static int noreplace_smp; | ||
31 | |||
26 | static int __init setup_noreplace_smp(char *str) | 32 | static int __init setup_noreplace_smp(char *str) |
27 | { | 33 | { |
28 | noreplace_smp = 1; | 34 | noreplace_smp = 1; |
@@ -376,8 +382,6 @@ void __init alternative_instructions(void) | |||
376 | #ifdef CONFIG_HOTPLUG_CPU | 382 | #ifdef CONFIG_HOTPLUG_CPU |
377 | if (num_possible_cpus() < 2) | 383 | if (num_possible_cpus() < 2) |
378 | smp_alt_once = 1; | 384 | smp_alt_once = 1; |
379 | #else | ||
380 | smp_alt_once = 1; | ||
381 | #endif | 385 | #endif |
382 | 386 | ||
383 | #ifdef CONFIG_SMP | 387 | #ifdef CONFIG_SMP |