From a19ff6dea3ef01ee49a0f34cac019edc25041ce6 Mon Sep 17 00:00:00 2001 From: Eugene Myers Date: Thu, 15 Sep 2022 15:33:58 -0400 Subject: cpu/x86/smm/smm_module_loader.c: Fix STM setup CB:63475 inadvertently disabled the STM by moving its load point off of the MSEG boundry, which is a hardware requirement. In addition, the BIOS resource list cannot be located within the MSEG. This patch fixes the issue by moving the STM load point to the MSEG boundry and placing the bios resource list just below the MSEG where the STM setup functions can find it. Fixes: commit 5747f6c (cpu/x86/smm_module_loader.c Rewrite setup) Signed-off-by: Eugene Myers Change-Id: I7359939063bb1a172fcb701551c099edebfbedd5 Reviewed-on: https://review.coreboot.org/c/coreboot/+/67665 Reviewed-by: Arthur Heymans Reviewed-by: Eugene Myers Tested-by: build bot (Jenkins) --- src/cpu/x86/smm/smm_module_loader.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/cpu/x86') diff --git a/src/cpu/x86/smm/smm_module_loader.c b/src/cpu/x86/smm/smm_module_loader.c index 768d2ca1bb..05554245fc 100644 --- a/src/cpu/x86/smm/smm_module_loader.c +++ b/src/cpu/x86/smm/smm_module_loader.c @@ -428,7 +428,7 @@ int smm_load_module(const uintptr_t smram_base, const size_t smram_size, const uintptr_t smram_top = region_end(&smram); const size_t stm_size = - CONFIG(STM) ? CONFIG_MSEG_SIZE - CONFIG_BIOS_RESOURCE_LIST_SIZE : 0; + CONFIG(STM) ? CONFIG_MSEG_SIZE + CONFIG_BIOS_RESOURCE_LIST_SIZE : 0; if (CONFIG(STM)) { struct region stm = {}; -- cgit v1.2.3