From 66ccc25724cfe1dceb1273f347c67ad56496b9ee Mon Sep 17 00:00:00 2001 From: Zvonko Kaiser Date: Thu, 6 Feb 2025 20:58:10 +0000 Subject: [PATCH] tdx: Update GPU config for the latest TDX stack We need extra kernel_params for TDX Signed-off-by: Zvonko Kaiser --- src/runtime/Makefile | 3 +++ src/runtime/config/configuration-qemu-nvidia-gpu-tdx.toml.in | 2 +- src/runtime/config/configuration-qemu-tdx.toml.in | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/runtime/Makefile b/src/runtime/Makefile index 815ee31a3b..2f1721c7b8 100644 --- a/src/runtime/Makefile +++ b/src/runtime/Makefile @@ -457,6 +457,8 @@ ifneq (,$(QEMUCMD)) # Setting this to false can lead to cgroup leakages in the host # Best practice for production is to set this to true DEFSANDBOXCGROUPONLY_NV = true + # The latest OVMF build should be good for both TDX and SNP + FIRMWAREPATH_NV := $(PREFIXDEPS)/share/ovmf/OVMF.fd endif ifneq (,$(CLHCMD)) @@ -627,6 +629,7 @@ USER_VARS += KERNELTDXPARAMS_NV USER_VARS += KERNELSNPPARAMS_NV USER_VARS += DEFAULTTIMEOUT_NV USER_VARS += DEFSANDBOXCGROUPONLY_NV +USER_VARS += FIRMWAREPATH_NV USER_VARS += DEFROOTFSTYPE USER_VARS += MACHINETYPE USER_VARS += KERNELDIR diff --git a/src/runtime/config/configuration-qemu-nvidia-gpu-tdx.toml.in b/src/runtime/config/configuration-qemu-nvidia-gpu-tdx.toml.in index 8f1586837f..8207959063 100644 --- a/src/runtime/config/configuration-qemu-nvidia-gpu-tdx.toml.in +++ b/src/runtime/config/configuration-qemu-nvidia-gpu-tdx.toml.in @@ -70,7 +70,7 @@ kernel_params = "@KERNELTDXPARAMS_NV@" # Path to the firmware. # If you want that qemu uses the default firmware leave this option empty -firmware = "@FIRMWARETDVFPATH@" +firmware = "@FIRMWAREPATH_NV@" # Path to the firmware volume. # firmware TDVF or OVMF can be split into FIRMWARE_VARS.fd (UEFI variables diff --git a/src/runtime/config/configuration-qemu-tdx.toml.in b/src/runtime/config/configuration-qemu-tdx.toml.in index de0dffca49..37ca97e1a2 100644 --- a/src/runtime/config/configuration-qemu-tdx.toml.in +++ b/src/runtime/config/configuration-qemu-tdx.toml.in @@ -71,7 +71,7 @@ kernel_params = "@KERNELTDXPARAMS@" # Path to the firmware. # If you want that qemu uses the default firmware leave this option empty -firmware = "@FIRMWARETDVFPATH@" +firmware = "@FIRMWAREPATH_NV@" # Path to the firmware volume. # firmware TDVF or OVMF can be split into FIRMWARE_VARS.fd (UEFI variables