From 0b796ae3442f7f70eba5fb9f8320c51b01bf3a5d Mon Sep 17 00:00:00 2001 From: Gerd Hoffmann Date: Wed, 13 Nov 2024 13:40:21 +0100 Subject: add guest hint default kconfig Add compile time config option for the guest hint default value. Signed-off-by: Gerd Hoffmann --- src/Kconfig | 7 +++++++ src/fw/paravirt.c | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/Kconfig b/src/Kconfig index 3a8ffa15..7c8104f0 100644 --- a/src/Kconfig +++ b/src/Kconfig @@ -478,6 +478,13 @@ menu "BIOS interfaces" help Provide TPM support along with TCG BIOS extensions + config DEFAULT_GUEST_HINT + int "tweak default config for 32-bit or 64-bit guests" + default 32 + help + Optimize memory layout (specifically the placement + of pci bars) for 32-bit or 64-bit guests. + endmenu menu "BIOS Tables" diff --git a/src/fw/paravirt.c b/src/fw/paravirt.c index fbd00f1c..001be7ca 100644 --- a/src/fw/paravirt.c +++ b/src/fw/paravirt.c @@ -37,7 +37,7 @@ u8 CPUPhysBits; // 64bit processor u8 CPULongMode; // memory layout hint (32bit or 64bit guests). -u8 GuestHint = 32; +u8 GuestHint = CONFIG_DEFAULT_GUEST_HINT; // Type of emulator platform. int PlatformRunningOn VARFSEG; // cfg enabled -- cgit