Merge tag 'x86_core_for_v6.2' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
[linux-2.6-block.git] / arch / x86 / kernel / setup_percpu.c
index b26123c90b4fd3dca51f43aeaae46cbfde526295..c242dc47e9cb92a6918592b3a58b0e2a2ba8e26b 100644 (file)
@@ -23,9 +23,6 @@
 #include <asm/cpumask.h>
 #include <asm/cpu.h>
 
-DEFINE_PER_CPU_READ_MOSTLY(int, cpu_number);
-EXPORT_PER_CPU_SYMBOL(cpu_number);
-
 #ifdef CONFIG_X86_64
 #define BOOT_PERCPU_OFFSET ((unsigned long)__per_cpu_load)
 #else
@@ -172,7 +169,7 @@ void __init setup_per_cpu_areas(void)
        for_each_possible_cpu(cpu) {
                per_cpu_offset(cpu) = delta + pcpu_unit_offsets[cpu];
                per_cpu(this_cpu_off, cpu) = per_cpu_offset(cpu);
-               per_cpu(cpu_number, cpu) = cpu;
+               per_cpu(pcpu_hot.cpu_number, cpu) = cpu;
                setup_percpu_segment(cpu);
                /*
                 * Copy data used in early init routines from the
@@ -211,7 +208,7 @@ void __init setup_per_cpu_areas(void)
                 * area.  Reload any changed state for the boot CPU.
                 */
                if (!cpu)
-                       switch_to_new_gdt(cpu);
+                       switch_gdt_and_percpu_base(cpu);
        }
 
        /* indicate the early static arrays will soon be gone */