aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/acpi/acpi_processor.c
diff options
context:
space:
mode:
authorGu Zheng <[email protected]>2016-08-25 08:35:18 +0000
committerThomas Gleixner <[email protected]>2016-09-21 19:18:39 +0000
commitdc6db24d2476cd09c0ecf2b8d80313539f737a89 (patch)
treea42cb20e94757560eeabaf8ebe800254e166e8b2 /drivers/acpi/acpi_processor.c
parentx86/acpi: Enable MADT APIs to return disabled apicids (diff)
downloadkernel-dc6db24d2476cd09c0ecf2b8d80313539f737a89.tar.gz
kernel-dc6db24d2476cd09c0ecf2b8d80313539f737a89.zip
x86/acpi: Set persistent cpuid <-> nodeid mapping when booting
The whole patch-set aims at making cpuid <-> nodeid mapping persistent. So that, when node online/offline happens, cache based on cpuid <-> nodeid mapping such as wq_numa_possible_cpumask will not cause any problem. It contains 4 steps: 1. Enable apic registeration flow to handle both enabled and disabled cpus. 2. Introduce a new array storing all possible cpuid <-> apicid mapping. 3. Enable _MAT and MADT relative apis to return non-present or disabled cpus' apicid. 4. Establish all possible cpuid <-> nodeid mapping. This patch finishes step 4. This patch set the persistent cpuid <-> nodeid mapping for all enabled/disabled processors at boot time via an additional acpi namespace walk for processors. [ tglx: Remove the unneeded exports ] Signed-off-by: Gu Zheng <[email protected]> Signed-off-by: Tang Chen <[email protected]> Signed-off-by: Zhu Guihua <[email protected]> Signed-off-by: Dou Liyang <[email protected]> Acked-by: Ingo Molnar <[email protected]> Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Thomas Gleixner <[email protected]>
Diffstat (limited to 'drivers/acpi/acpi_processor.c')
-rw-r--r--drivers/acpi/acpi_processor.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/acpi/acpi_processor.c b/drivers/acpi/acpi_processor.c
index 02b84aa69fa4..f9f23fdd96a1 100644
--- a/drivers/acpi/acpi_processor.c
+++ b/drivers/acpi/acpi_processor.c
@@ -182,6 +182,11 @@ int __weak arch_register_cpu(int cpu)
void __weak arch_unregister_cpu(int cpu) {}
+int __weak acpi_map_cpu2node(acpi_handle handle, int cpu, int physid)
+{
+ return -ENODEV;
+}
+
static int acpi_processor_hotadd_init(struct acpi_processor *pr)
{
unsigned long long sta;