[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 0/2] x86: Const-ify hvm_enabled and hap_enabled() when possible
- To: <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- From: Alejandro Vallejo <alejandro.garciavallejo@xxxxxxx>
- Date: Fri, 13 Feb 2026 14:37:28 +0100
- 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=KVHDnfeZ9Qwy5x2KVw60dxyfthggzrmiIZebDLtKY80=; b=kC/L1LAtE1V1yUCivo2NM5juEGwdlOSYyXyGRJ6vEKP+3oXFR135WFYKq+F4nxMbbDmKQAEgDd48B2go2yCqD2+idCt7GrPRAI17F3xnsCu7dccZ3FvNGbkKMBVJhttdXiJLAZp203oOTWzhMkIAdSJ5wUm8bH90rK3QC3IS0eh2678cgvJhz6E5bEy/qS7QHdfINSzabu2a0l8dar66Bk+9lT8km1f2qpe8sSjlijSZfDcSr0SLy4YE/gC9yKaQ9KxpnEvKUv+ajcftUjPVNRysqUOSR3bKytMIunTLikjqrGiZmwKysu2v3atbSpIsSop3tfADs2s95FPo2zFptg==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=GfH9F4KEwR9d+zlAcqyl1TV048nACurqWUtOYIwIZhL2sS+gN87zGzkhv/HGPc7EjOP6UrEQ0IOxonFHmSRLUd89UAXpSnmPEI5IGDlhUbvs1uXERi3N7yo7n07CzbbF1r2n+jCcgByDi99BXGso3Fjxy1F6AShEuFZ+E3nzq6PZiw8igGCOWIbThVyszdRNCYeal9LfHz4y4MFv/0eDZ+YmDk4fDmfA00Gky+CotYvtJvGnJYfGuQGBjzcWxjFhZMQDzYtzX2cwAIhd2kTsP+9vEjp72/CABevs6hSrrnFRqJSECCIu4kEJu25eTTuUJImpDyE2kOrDNEmdCg/JVg==
- Cc: Alejandro Vallejo <alejandro.garciavallejo@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>
- Delivery-date: Fri, 13 Feb 2026 13:38:04 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
Hi,
pipeline (green):
https://gitlab.com/xen-project/people/agvallejo/xen/-/pipelines/2324325987
hvm_enabled is already a constant in PV-only builds. Patch 1 makes it so it's
also a constant in HVM-only builds (with a compile-time panic if HVM support
is lacking in HW). Patch 2 makes it so HVM-only shadowless builds mandate HAP
at boot, thus const-ifying hap_enabled() too and removing that pesky shadow/
folder.
Cheers,
Alejandro
Alejandro Vallejo (2):
x86: Make hvm_enabled a constant unless both PV and HVM are both
compiled
x86: Force HAP to be enabled when PV and shadow paging are compiled
out
xen/arch/x86/Kconfig | 2 ++
xen/arch/x86/hvm/Kconfig | 3 +++
xen/arch/x86/hvm/hvm.c | 17 ++++++++++++++++
xen/arch/x86/include/asm/hvm/hvm.h | 32 +++++++++++++++---------------
xen/arch/x86/mm/Makefile | 2 +-
xen/include/xen/sched.h | 3 +++
6 files changed, 42 insertions(+), 17 deletions(-)
base-commit: 1f4f85b64d393be1aa8dc8170201f4fbfe9c7222
--
2.43.0
|