Attention is currently required from: Jérémy Compostella, Patrick Rudolph, Shuo Liu.
Hello Jérémy Compostella, Shuo Liu, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/87177?usp=email
to look at the new patch set (#2).
The following approvals got outdated and were removed: Code-Review+1 by Shuo Liu, Verified-1 by build bot (Jenkins)
Change subject: cpu/x86/smm: Make SMM stub x86_32 only ......................................................................
cpu/x86/smm: Make SMM stub x86_32 only
In order to give SMM access to more than 4GiB on x86_64 update the SMM stub, SMM relocation handler and SMM permanent handler on x86_64. On x86_32 nothing changed.
There are several major changes done at once: 1) Make the SMM stub x86_32 only, even on x86_64 The handler is not responsible to set up x86_64 mode, since only the handler knows where the page tables reside. The handler called no longer use the same page tables! 2) Delete page table generation in the SMM loader The relocation handler will use existing ramstage's page tables. The permanent handler will use it's own page tables. 3) Place page tables in the SMM permanent handler Use the same RO page tables as used on all other stages. Gives SMM access to more than 4GiB of the memory space. 4) Add assembly entry function to the SMM permanent handler On x86_64 the SMM rmodule will switch from x86_32 to x86_64 and load the page table residing in the SMM rmodule.
TEST: Could access ROM3 BAR at 0xfd00000000 in SMM.
Change-Id: Ia493dc813f50df273d13053f1c9a0ae5335638d6 Signed-off-by: Patrick Rudolph patrick.rudolph@9elements.com --- M src/arch/x86/c_start.S M src/cpu/x86/64bit/Makefile.mk M src/cpu/x86/mp_init.c M src/cpu/x86/smm/Makefile.mk A src/cpu/x86/smm/smm_module_entry.S M src/cpu/x86/smm/smm_module_handler.c M src/cpu/x86/smm/smm_module_loader.c A src/cpu/x86/smm/smm_relocation_wrapper.S M src/cpu/x86/smm/smm_stub.S M src/include/cpu/x86/smm.h 10 files changed, 133 insertions(+), 85 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/77/87177/2