Browse Source

x86: move num_processors to smpboot.c

Signed-off-by: Alexey Starikovskiy <astarikovskiy@suse.de>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Alexey Starikovskiy 17 years ago
parent
commit
2bb9e9d7c1
2 changed files with 7 additions and 1 deletions
  1. 4 1
      arch/x86/kernel/mpparse_32.c
  2. 3 0
      arch/x86/kernel/smpboot.c

+ 4 - 1
arch/x86/kernel/mpparse_32.c

@@ -65,8 +65,11 @@ unsigned int def_to_bigsmp = 0;
 
 /* Processor that is doing the boot up */
 unsigned int boot_cpu_physical_apicid = -1U;
-/* Internal processor count */
+
+/* Make it easy to share the UP and SMP code: */
+#ifndef CONFIG_X86_SMP
 unsigned int num_processors;
+#endif
 
 unsigned disabled_cpus __cpuinitdata;
 

+ 3 - 0
arch/x86/kernel/smpboot.c

@@ -86,6 +86,9 @@ void *x86_bios_cpu_apicid_early_ptr;
 DEFINE_PER_CPU(u16, x86_bios_cpu_apicid) = BAD_APICID;
 EXPORT_PER_CPU_SYMBOL(x86_bios_cpu_apicid);
 
+/* Internal processor count */
+unsigned int num_processors;
+
 /* Bitmask of physically existing CPUs */
 physid_mask_t phys_cpu_present_map;