mirror of
https://github.com/torvalds/linux.git
synced 2024-11-16 00:52:01 +00:00
5290e88ba2
The UV code attempts to build a set of tables to allow it to do
bidirectional socket<=>node lookups.
But when nr_cpus is set to a smaller number than actually present, the
cpu_to_node() mapping information for unused CPUs is not available to
build_socket_tables(). This results in skipping some nodes or sockets
when creating the tables and leaving some -1's for later code to trip.
over, causing oopses.
The problem is that the socket<=>node lookups are created by doing a
loop over all CPUs, then looking up the CPU's APICID and socket. But
if a CPU is not present, there is no way to start this lookup.
Instead of looping over all CPUs, take CPUs out of the equation
entirely. Loop over all APICIDs which are mapped to a valid NUMA node.
Then just extract the socket-id from the APICID.
This avoid tripping over disabled CPUs.
Fixes:
|
||
---|---|---|
.. | ||
apic_common.c | ||
apic_flat_64.c | ||
apic_noop.c | ||
apic_numachip.c | ||
apic.c | ||
bigsmp_32.c | ||
hw_nmi.c | ||
init.c | ||
io_apic.c | ||
ipi.c | ||
local.h | ||
Makefile | ||
msi.c | ||
probe_32.c | ||
probe_64.c | ||
vector.c | ||
x2apic_cluster.c | ||
x2apic_phys.c | ||
x2apic_uv_x.c |