diff options
author | Heiko Carstens <heiko.carstens@de.ibm.com> | 2016-12-02 04:38:37 -0500 |
---|---|---|
committer | Martin Schwidefsky <schwidefsky@de.ibm.com> | 2016-12-07 01:23:16 -0500 |
commit | 30fc4ca2a8ab508d160a917b89b7e1c27f893354 (patch) | |
tree | 90b80934e4e7189eef1ef0b3f4c17eb5f7af9588 /arch/s390/numa | |
parent | af51160ebd3cc1c8bf0d37a48f13ac0dbe8a6e5f (diff) |
s390/topology: use cpu_topology array instead of per cpu variable
CPU topology information like cpu to node mapping must be setup in
setup_arch already. Topology information is currently made available
with a per cpu variable; this however will not work when the
initialization will be moved to setup_arch, since the generic percpu
setup will be done much later.
Therefore convert back to a cpu_topology array.
Reviewed-by: Michael Holzheu <holzheu@linux.vnet.ibm.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'arch/s390/numa')
-rw-r--r-- | arch/s390/numa/mode_emu.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/s390/numa/mode_emu.c b/arch/s390/numa/mode_emu.c index b83109328fec..2ed27e8eb4d4 100644 --- a/arch/s390/numa/mode_emu.c +++ b/arch/s390/numa/mode_emu.c | |||
@@ -355,7 +355,7 @@ static struct toptree *toptree_from_topology(void) | |||
355 | phys = toptree_new(TOPTREE_ID_PHYS, 1); | 355 | phys = toptree_new(TOPTREE_ID_PHYS, 1); |
356 | 356 | ||
357 | for_each_online_cpu(cpu) { | 357 | for_each_online_cpu(cpu) { |
358 | top = &per_cpu(cpu_topology, cpu); | 358 | top = &cpu_topology[cpu]; |
359 | node = toptree_get_child(phys, 0); | 359 | node = toptree_get_child(phys, 0); |
360 | drawer = toptree_get_child(node, top->drawer_id); | 360 | drawer = toptree_get_child(node, top->drawer_id); |
361 | book = toptree_get_child(drawer, top->book_id); | 361 | book = toptree_get_child(drawer, top->book_id); |
@@ -378,7 +378,7 @@ static void topology_add_core(struct toptree *core) | |||
378 | int cpu; | 378 | int cpu; |
379 | 379 | ||
380 | for_each_cpu(cpu, &core->mask) { | 380 | for_each_cpu(cpu, &core->mask) { |
381 | top = &per_cpu(cpu_topology, cpu); | 381 | top = &cpu_topology[cpu]; |
382 | cpumask_copy(&top->thread_mask, &core->mask); | 382 | cpumask_copy(&top->thread_mask, &core->mask); |
383 | cpumask_copy(&top->core_mask, &core_mc(core)->mask); | 383 | cpumask_copy(&top->core_mask, &core_mc(core)->mask); |
384 | cpumask_copy(&top->book_mask, &core_book(core)->mask); | 384 | cpumask_copy(&top->book_mask, &core_book(core)->mask); |