]> www.infradead.org Git - users/jedix/linux-maple.git/commit
sparc64: Fixes NUMA node cpulist sysfs file in single NUMA node case.
authorThomas Tai <thomas.tai@oracle.com>
Fri, 2 Sep 2016 19:18:19 +0000 (12:18 -0700)
committerAllen Pais <allen.pais@oracle.com>
Tue, 8 Nov 2016 10:17:59 +0000 (15:47 +0530)
commitfdf8e9c846df76995f80e79cdc48a8ee7ad45a57
tree97ecb3a0e1a1c2b7e907f4b78e369ee61b5cc54d
parent548561a84ba51897b0a2e96f016b59302de66952
sparc64: Fixes NUMA node cpulist sysfs file in single NUMA node case.

Forward port 23175351 to UEK4

The sysfs file /sys/devices/system/node/node0/cpulist is incorrect in the
single node case on sun4v machines as the machine description record in this
case does not contain any NUMA information. A default list from 0 to NR_CPUS
was used prior. This file is read by utilities such as 'numactl --hardware'
and lscpu to show CPU-to-node assignment.

In order to fix this issue, the numa_cpumask_lookup_table is cleared at
bootup. Whenever an extra cpu is bringup via __cpu_up, the corresponding
cpu mask is set in the numa_cpumask_lookup_table.

Orabug: 24500614
Orabug: 22546851

Signed-off-by: Chris Hyser <chris.hyser@oracle.com>
Signed-off-by: Thomas Tai <thomas.tai@oracle.com>
arch/sparc/kernel/cpumap.h
arch/sparc/kernel/smp_64.c
arch/sparc/mm/init_64.c