diff options
author | Tony Luck <tony.luck@intel.com> | 2005-10-20 13:41:44 -0400 |
---|---|---|
committer | Tony Luck <tony.luck@intel.com> | 2005-10-20 13:41:44 -0400 |
commit | 9cec58dc138d6fcad9f447a19c8ff69f6540e667 (patch) | |
tree | 4fe1cca94fdba8b705c87615bee06d3346f687ce /arch/x86_64/mm/numa.c | |
parent | 17e5ad6c0ce5a970e2830d0de8bdd60a2f077d38 (diff) | |
parent | ac9b9c667c2e1194e22ebe0a441ae1c37aaa9b90 (diff) |
Update from upstream with manual merge of Yasunori Goto's
changes to swiotlb.c made in commit 281dd25cdc0d6903929b79183816d151ea626341
since this file has been moved from arch/ia64/lib/swiotlb.c to
lib/swiotlb.c
Signed-off-by: Tony Luck <tony.luck@intel.com>
Diffstat (limited to 'arch/x86_64/mm/numa.c')
-rw-r--r-- | arch/x86_64/mm/numa.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/arch/x86_64/mm/numa.c b/arch/x86_64/mm/numa.c index 80a49d9bd8a7..214803821001 100644 --- a/arch/x86_64/mm/numa.c +++ b/arch/x86_64/mm/numa.c | |||
@@ -167,18 +167,16 @@ void __init numa_init_array(void) | |||
167 | mapping. To avoid this fill in the mapping for all possible | 167 | mapping. To avoid this fill in the mapping for all possible |
168 | CPUs, as the number of CPUs is not known yet. | 168 | CPUs, as the number of CPUs is not known yet. |
169 | We round robin the existing nodes. */ | 169 | We round robin the existing nodes. */ |
170 | rr = 0; | 170 | rr = first_node(node_online_map); |
171 | for (i = 0; i < NR_CPUS; i++) { | 171 | for (i = 0; i < NR_CPUS; i++) { |
172 | if (cpu_to_node[i] != NUMA_NO_NODE) | 172 | if (cpu_to_node[i] != NUMA_NO_NODE) |
173 | continue; | 173 | continue; |
174 | cpu_to_node[i] = rr; | ||
174 | rr = next_node(rr, node_online_map); | 175 | rr = next_node(rr, node_online_map); |
175 | if (rr == MAX_NUMNODES) | 176 | if (rr == MAX_NUMNODES) |
176 | rr = first_node(node_online_map); | 177 | rr = first_node(node_online_map); |
177 | cpu_to_node[i] = rr; | ||
178 | rr++; | ||
179 | } | 178 | } |
180 | 179 | ||
181 | set_bit(0, &node_to_cpumask[cpu_to_node(0)]); | ||
182 | } | 180 | } |
183 | 181 | ||
184 | #ifdef CONFIG_NUMA_EMU | 182 | #ifdef CONFIG_NUMA_EMU |
@@ -266,9 +264,7 @@ void __init numa_initmem_init(unsigned long start_pfn, unsigned long end_pfn) | |||
266 | 264 | ||
267 | __cpuinit void numa_add_cpu(int cpu) | 265 | __cpuinit void numa_add_cpu(int cpu) |
268 | { | 266 | { |
269 | /* BP is initialized elsewhere */ | 267 | set_bit(cpu, &node_to_cpumask[cpu_to_node(cpu)]); |
270 | if (cpu) | ||
271 | set_bit(cpu, &node_to_cpumask[cpu_to_node(cpu)]); | ||
272 | } | 268 | } |
273 | 269 | ||
274 | unsigned long __init numa_free_all_bootmem(void) | 270 | unsigned long __init numa_free_all_bootmem(void) |