diff options
Diffstat (limited to 'arch/ia64/mm/discontig.c')
-rw-r--r-- | arch/ia64/mm/discontig.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/arch/ia64/mm/discontig.c b/arch/ia64/mm/discontig.c index d83125e1ed27..78026aabaa7f 100644 --- a/arch/ia64/mm/discontig.c +++ b/arch/ia64/mm/discontig.c | |||
@@ -143,7 +143,11 @@ static void *per_cpu_node_setup(void *cpu_data, int node) | |||
143 | int cpu; | 143 | int cpu; |
144 | 144 | ||
145 | for_each_possible_early_cpu(cpu) { | 145 | for_each_possible_early_cpu(cpu) { |
146 | if (node == node_cpuid[cpu].nid) { | 146 | if (cpu == 0) { |
147 | void *cpu0_data = __phys_per_cpu_start - PERCPU_PAGE_SIZE; | ||
148 | __per_cpu_offset[cpu] = (char*)cpu0_data - | ||
149 | __per_cpu_start; | ||
150 | } else if (node == node_cpuid[cpu].nid) { | ||
147 | memcpy(__va(cpu_data), __phys_per_cpu_start, | 151 | memcpy(__va(cpu_data), __phys_per_cpu_start, |
148 | __per_cpu_end - __per_cpu_start); | 152 | __per_cpu_end - __per_cpu_start); |
149 | __per_cpu_offset[cpu] = (char*)__va(cpu_data) - | 153 | __per_cpu_offset[cpu] = (char*)__va(cpu_data) - |