xen: decouple NUMA from ACPI in Kconfig
authorWei Chen <wei.chen@arm.com>
Fri, 10 Jun 2022 05:53:12 +0000 (13:53 +0800)
committerJulien Grall <jgrall@amazon.com>
Fri, 17 Jun 2022 08:36:12 +0000 (09:36 +0100)
In current Xen code only implements x86 ACPI-based NUMA support.
So in Xen Kconfig system, NUMA equals to ACPI_NUMA. x86 selects
NUMA by default, and CONFIG_ACPI_NUMA is hardcode in config.h.

In a follow-up patch, we will introduce support for NUMA using
the device tree. That means we will have two NUMA implementations,
so in this patch we decouple NUMA from ACPI based NUMA in Kconfig.
Make NUMA as a common feature, that device tree based NUMA also
can select it.

Signed-off-by: Wei Chen <wei.chen@arm.com>
Tested-by: Jiamei Xie <jiamei.xie@arm.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
xen/arch/x86/Kconfig
xen/arch/x86/include/asm/config.h
xen/common/Kconfig
xen/drivers/acpi/Kconfig
xen/drivers/acpi/Makefile

index 06d6fbc864784020de8298a27b2cdda2b3af8464..1e31edc99f9d498d59e1fcf1fbc07c165c27d418 100644 (file)
@@ -6,6 +6,7 @@ config X86
        def_bool y
        select ACPI
        select ACPI_LEGACY_TABLES_LOOKUP
+       select ACPI_NUMA
        select ALTERNATIVE_CALL
        select ARCH_SUPPORTS_INT128
        select CORE_PARKING
@@ -26,7 +27,6 @@ config X86
        select HAS_UBSAN
        select HAS_VPCI if HVM
        select NEEDS_LIBELF
-       select NUMA
 
 config ARCH_DEFCONFIG
        string
index de206425243974a4b947a7b058c971072c230323..07bcd158314b94c1f49be9c42dd9a46dfb4f3c97 100644 (file)
@@ -31,7 +31,6 @@
 /* Intel P4 currently has largest cache line (L2 line size is 128 bytes). */
 #define CONFIG_X86_L1_CACHE_SHIFT 7
 
-#define CONFIG_ACPI_NUMA 1
 #define CONFIG_ACPI_SRAT 1
 #define CONFIG_ACPI_CSTATE 1
 
index 5b6b2406c028ed86bd6def780164426b1901ab42..41a67891bcc85bf77f7cffcd9c9370bbd7f48dd0 100644 (file)
@@ -73,6 +73,9 @@ config MEM_ACCESS
 config NEEDS_LIBELF
        bool
 
+config NUMA
+       bool
+
 config STATIC_MEMORY
        bool "Static Allocation Support (UNSUPPORTED)" if UNSUPPORTED
        depends on ARM
index b64d3731fb485af33b1cf5ae260930eb8ca06d29..e3f3d8f4b16b2ccf79d7b08656104e6b6f29c22b 100644 (file)
@@ -5,5 +5,6 @@ config ACPI
 config ACPI_LEGACY_TABLES_LOOKUP
        bool
 
-config NUMA
+config ACPI_NUMA
        bool
+       select NUMA
index 4f8e97228ee25ca938ebc2bc9aae09c236b53926..2fc5230253874e40438cc462dfec76d8490e9a93 100644 (file)
@@ -3,7 +3,7 @@ obj-y += utilities/
 obj-$(CONFIG_X86) += apei/
 
 obj-bin-y += tables.init.o
-obj-$(CONFIG_NUMA) += numa.o
+obj-$(CONFIG_ACPI_NUMA) += numa.o
 obj-y += osl.o
 obj-$(CONFIG_HAS_CPUFREQ) += pmstat.o