diff options
author | Nishanth Aravamudan <nacc@linux.vnet.ibm.com> | 2014-10-17 20:50:40 -0400 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2014-10-28 18:41:22 -0400 |
commit | 2c0a33f9861d38631245f7ef434ecad3413324fb (patch) | |
tree | 3b5c5dbdd37bbd2b3ee8d1df44ce204f422a7aca | |
parent | 49f8d8c04368d2e29cd26752715367ccafec5b1d (diff) |
powerpc/numa: ensure per-cpu NUMA mappings are correct on topology update
We received a report of warning in kernel/sched/core.c where the sched
group was NULL on an LPAR after a topology update. This seems to occur
because after the topology update has moved the CPUs, cpu_to_node is
returning the old value still, which ends up breaking the consistency of
the NUMA topology in the per-cpu maps. Ensure that we update the per-cpu
fields when we re-map CPUs.
Signed-off-by: Nishanth Aravamudan <nacc@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
-rw-r--r-- | arch/powerpc/mm/numa.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/arch/powerpc/mm/numa.c b/arch/powerpc/mm/numa.c index ef45abf7319e..b9d1dfdbe5bb 100644 --- a/arch/powerpc/mm/numa.c +++ b/arch/powerpc/mm/numa.c | |||
@@ -1509,11 +1509,14 @@ static int update_cpu_topology(void *data) | |||
1509 | cpu = smp_processor_id(); | 1509 | cpu = smp_processor_id(); |
1510 | 1510 | ||
1511 | for (update = data; update; update = update->next) { | 1511 | for (update = data; update; update = update->next) { |
1512 | int new_nid = update->new_nid; | ||
1512 | if (cpu != update->cpu) | 1513 | if (cpu != update->cpu) |
1513 | continue; | 1514 | continue; |
1514 | 1515 | ||
1515 | unmap_cpu_from_node(cpu); | 1516 | unmap_cpu_from_node(cpu); |
1516 | map_cpu_to_node(cpu, update->new_nid); | 1517 | map_cpu_to_node(cpu, new_nid); |
1518 | set_cpu_numa_node(cpu, new_nid); | ||
1519 | set_cpu_numa_mem(cpu, local_memory_node(new_nid)); | ||
1517 | vdso_getcpu_init(); | 1520 | vdso_getcpu_init(); |
1518 | } | 1521 | } |
1519 | 1522 | ||