[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH v2 15/15] kconfig: Allow x86 to pick CONFIG_DOM0LESS_BOOT


  • To: <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Alejandro Vallejo <agarciav@xxxxxxx>
  • Date: Thu, 5 Jun 2025 21:48:07 +0200
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=lists.xenproject.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0)
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=qBMHO1HIupXAcwfOdVU4/7q8edByJCbA+TOtQ6T2SUo=; b=TBUjHDIEzn2eHHxTNTmaEfOf8nvrbxqCkuuqpHk0vi6hRM2exHDL5aGDRqryg3oyZ7zBLMB/cOaTfKD1sEmoqIkCurMXAJQEOwhoTbGQ3BZePdmyE50rxNiH/f4j35BTSmn+u1TapGdJ4JoEtnxa3ACTgLTycpGmF2FVYxP71BrgZ9vA3YkMJmnP3LJqzQCQeXwl6dV8MKpFb8IwUZaggwvX0VN2AUsXLJexAsk7n79EuTTtdQnwmhpzPnA8joqVYVLvRV/9dPYDEhgo9KNOkseJN9NZiXO6yjuJywaaSEtbeuhE2+s4BpZKQNVcqZJZryB7VIr7Hdccp7QuJ2bv1A==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=dqrn+eRwFYb8IeyOs+q7asxyq4jvhOPsbC+AtByC6rA87zw7Vka68XAD09HuruPhVMK4xJ2+8PMHGgV6lagNVEdKYtVX03INFZWYsOpxe5GrVW1g5Hz9hxRW65Rfq2i79Fe+O0i16YsCTuaQfnHpfpCYqp8TsR6SgPQWE/YSggttQzL9Xw9c5tErDmRG9q4lIhdMRggTCrBeZ2+8NcnU/zof2kRiJ8LkK9KX+QOnfRiId8kLjF/kSTu4yahLzY9GqDSyEj+o0ojQxwxEFULx+MJHQ1YQXNWSBr4Y6DZYzJpX/RhyP468l8xnY7U39oIUeQqPv0gOsk/MsGH9BcQHiQ==
  • Cc: Alejandro Vallejo <agarciav@xxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>, Anthony PERARD <anthony.perard@xxxxxxxxxx>, Michal Orzel <michal.orzel@xxxxxxx>, "Julien Grall" <julien@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, "Bertrand Marquis" <bertrand.marquis@xxxxxxx>, "Daniel P. Smith" <dpsmith@xxxxxxxxxxxxxxxxxxxx>
  • Delivery-date: Thu, 05 Jun 2025 19:51:13 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

Without picking CONFIG_HAS_DEVICE_TREE.

In order to do that. Allow CONFIG_DOM0LESS_BOOT to enable a subset
of the common/device-tree/ directory. x86 doesn't want dom0less-build.c,
as that's tightly integrated still to the ARM way of building domains.

Requires "unsupported" for the time being until all required patches
make it through.

Signed-off-by: Alejandro Vallejo <agarciav@xxxxxxx>
---
v2:
  * (required on rebase) Add an explicit dependency on HAS_DEVICE_TREE
    for STATIC_MEMORY and STATIC_EVTCHN so they're not pulled-in. Could
    use !X86 as well.
---
 xen/arch/x86/Kconfig            |  1 +
 xen/common/Kconfig              | 12 +++++++-----
 xen/common/device-tree/Makefile |  2 +-
 3 files changed, 9 insertions(+), 6 deletions(-)

diff --git a/xen/arch/x86/Kconfig b/xen/arch/x86/Kconfig
index 7afe879710..4344b4289c 100644
--- a/xen/arch/x86/Kconfig
+++ b/xen/arch/x86/Kconfig
@@ -18,6 +18,7 @@ config X86
        select HAS_COMPAT
        select HAS_CPUFREQ
        select HAS_DIT
+       select HAS_DOM0LESS
        select HAS_EHCI
        select HAS_EX_TABLE
        select HAS_FAST_MULTIPLY
diff --git a/xen/common/Kconfig b/xen/common/Kconfig
index 5353874e87..bcf87b4d9d 100644
--- a/xen/common/Kconfig
+++ b/xen/common/Kconfig
@@ -13,15 +13,17 @@ config CORE_PARKING
        depends on NR_CPUS > 1
 
 config DOM0LESS_BOOT
-       bool "Dom0less boot support" if EXPERT
+       bool "Dom0less boot support" if EXPERT && (!X86 || UNSUPPORTED)
        select LIBFDT
-       depends on HAS_DOM0LESS && HAS_DEVICE_TREE && DOMAIN_BUILD_HELPERS
-       default y
+       depends on HAS_DOM0LESS && (X86 || (HAS_DEVICE_TREE && 
DOMAIN_BUILD_HELPERS))
+       default y if !X86
        help
          Dom0less boot support enables Xen to create and start domU guests 
during
          Xen boot without the need of a control domain (Dom0), which could be
          present anyway.
 
+         If unsure on x86, say N.
+
 config DOMAIN_BUILD_HELPERS
        bool
 
@@ -152,7 +154,7 @@ config NUMA
 
 config STATIC_MEMORY
        bool "Static Allocation Support (UNSUPPORTED)" if UNSUPPORTED
-       depends on DOM0LESS_BOOT
+       depends on HAS_DEVICE_TREE && DOM0LESS_BOOT
        help
          Static Allocation refers to system or sub-system(domains) for
          which memory areas are pre-defined by configuration using physical
@@ -171,7 +173,7 @@ config STATIC_SHM
 
 config STATIC_EVTCHN
        bool "Static event channel support on a dom0less system"
-       depends on DOM0LESS_BOOT
+       depends on HAS_DEVICE_TREE && DOM0LESS_BOOT
        default y
        help
          This option enables establishing static event channel communication
diff --git a/xen/common/device-tree/Makefile b/xen/common/device-tree/Makefile
index cc56f42df9..f5410e685b 100644
--- a/xen/common/device-tree/Makefile
+++ b/xen/common/device-tree/Makefile
@@ -3,7 +3,7 @@ obj-$(CONFIG_HAS_DEVICE_TREE) += bootinfo-fdt.init.o
 obj-$(CONFIG_HAS_DEVICE_TREE) += bootinfo.init.o
 obj-$(CONFIG_HAS_DEVICE_TREE) += device-tree.o
 obj-$(CONFIG_DOMAIN_BUILD_HELPERS) += domain-build.init.o
-obj-$(CONFIG_DOM0LESS_BOOT) += dom0less-build.init.o
+obj-$(filter-out $(CONFIG_X86),$(CONFIG_DOM0LESS_BOOT)) += 
dom0less-build.init.o
 obj-$(CONFIG_OVERLAY_DTB) += dt-overlay.o
 obj-$(CONFIG_HAS_DEVICE_TREE) += intc.o
 obj-$(CONFIG_DOMAIN_BUILD_HELPERS) += kernel.o
-- 
2.43.0




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.