Reka Norman has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/64853 )
Change subject: Revert "cpu/x86/smm: Remove heap" ......................................................................
Revert "cpu/x86/smm: Remove heap"
This reverts commit ea2c1d357cccf4ee84473d304c880250fbd97080.
This change breaks S0ix, reboot and poweroff on nissa (ADL-N). Revert it while we try to figure out why.
BUG=b:234398643 TEST=S0ix works on nivviks
Signed-off-by: Reka Norman rekanorman@chromium.org Change-Id: Icd782159b43091fff66fe075b77a3dc20d5e6e32 --- M src/cpu/x86/Kconfig M src/cpu/x86/smm/Makefile.inc M src/lib/Makefile.inc 3 files changed, 10 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/53/64853/1
diff --git a/src/cpu/x86/Kconfig b/src/cpu/x86/Kconfig index 5b92795..4db6c36 100644 --- a/src/cpu/x86/Kconfig +++ b/src/cpu/x86/Kconfig @@ -136,6 +136,13 @@
if HAVE_SMI_HANDLER && !SMM_LEGACY_ASEG
+config SMM_MODULE_HEAP_SIZE + hex + default 0x4000 + help + This option determines the size of the heap within the SMM handler + modules. + config SMM_MODULE_STACK_SIZE hex default 0x800 if ARCH_RAMSTAGE_X86_64 diff --git a/src/cpu/x86/smm/Makefile.inc b/src/cpu/x86/smm/Makefile.inc index 5f69590..cd920da 100644 --- a/src/cpu/x86/smm/Makefile.inc +++ b/src/cpu/x86/smm/Makefile.inc @@ -67,9 +67,9 @@ # C-based SMM handler.
ifeq ($(CONFIG_ARCH_RAMSTAGE_X86_32),y) -$(eval $(call rmodule_link,$(obj)/smm/smm.elf, $(obj)/smm/smm.o, 0,x86_32)) +$(eval $(call rmodule_link,$(obj)/smm/smm.elf, $(obj)/smm/smm.o, $(CONFIG_SMM_MODULE_HEAP_SIZE),x86_32)) else -$(eval $(call rmodule_link,$(obj)/smm/smm.elf, $(obj)/smm/smm.o, 0,x86_64)) +$(eval $(call rmodule_link,$(obj)/smm/smm.elf, $(obj)/smm/smm.o, $(CONFIG_SMM_MODULE_HEAP_SIZE),x86_64)) endif
$(obj)/smm/smm: $(obj)/smm/smm.elf.rmod diff --git a/src/lib/Makefile.inc b/src/lib/Makefile.inc index 68a2960..505dc46 100644 --- a/src/lib/Makefile.inc +++ b/src/lib/Makefile.inc @@ -215,6 +215,7 @@ ramstage-y += boot_device.c
smm-y += boot_device.c +smm-y += malloc.c smm-y += delay.c smm-y += fmap.c smm-y += cbfs.c memcmp.c