Arthur Heymans has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/46375 )
Change subject: drivers/txt/getsec_enteraccs.S: Save and restore MTRR_DEF_TYPE ......................................................................
drivers/txt/getsec_enteraccs.S: Save and restore MTRR_DEF_TYPE
This needs to be saved and restored, otherwise the BSP might have an inconsistent MTRR setup with regards to the AP's which results in weird errors and slowdowns in the operating system.
TESTED: Fixes booting OCP/Deltalake with Linux 5.8.
Change-Id: Iace636ec6fca3b4d7b2856f0f054947c5b3bc8de Signed-off-by: Arthur Heymans arthur@aheymans.xyz --- M src/security/intel/txt/getsec_enteraccs.S 1 file changed, 2 insertions(+), 6 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/75/46375/1
diff --git a/src/security/intel/txt/getsec_enteraccs.S b/src/security/intel/txt/getsec_enteraccs.S index 3135de7..563dc08 100644 --- a/src/security/intel/txt/getsec_enteraccs.S +++ b/src/security/intel/txt/getsec_enteraccs.S @@ -58,6 +58,7 @@ /* Reserve space on stack for GDT */ subl $8, %esp
+ PUSH_MSR MTRR_DEF_TYPE_MSR PUSH_MSR IA32_MISC_ENABLE PUSH_MSR MTRR_FIX_64K_00000 PUSH_MSR MTRR_FIX_16K_80000 @@ -290,12 +291,7 @@ POP_MSR MTRR_FIX_16K_80000 POP_MSR MTRR_FIX_64K_00000 POP_MSR IA32_MISC_ENABLE - - /* Enable fixed MTRRs */ - movl $(MTRR_DEF_TYPE_MSR), %ecx - rdmsr - orl $(MTRR_DEF_TYPE_FIX_EN), %eax - wrmsr + POP_MSR MTRR_DEF_TYPE_MSR
/* Enable cache */ movl %cr0, %eax
Angel Pons has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/46375 )
Change subject: drivers/txt/getsec_enteraccs.S: Save and restore MTRR_DEF_TYPE ......................................................................
Patch Set 1: Code-Review+1
Hello build bot (Jenkins), Angel Pons,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/46375
to look at the new patch set (#2).
Change subject: sec/intel/txt/getsec_enteraccs.S: Save and restore MTRR_DEF_TYPE ......................................................................
sec/intel/txt/getsec_enteraccs.S: Save and restore MTRR_DEF_TYPE
This needs to be saved and restored, otherwise the BSP might have an inconsistent MTRR setup with regards to the AP's which results in weird errors and slowdowns in the operating system.
TESTED: Fixes booting OCP/Deltalake with Linux 5.8.
Change-Id: Iace636ec6fca3b4d7b2856f0f054947c5b3bc8de Signed-off-by: Arthur Heymans arthur@aheymans.xyz --- M src/security/intel/txt/getsec_enteraccs.S 1 file changed, 2 insertions(+), 6 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/75/46375/2
Angel Pons has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/46375 )
Change subject: sec/intel/txt/getsec_enteraccs.S: Save and restore MTRR_DEF_TYPE ......................................................................
Patch Set 2: Code-Review+2
Tested on Haswell, BIOS ACM is still happy about things.
Christian Walter has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/46375 )
Change subject: sec/intel/txt/getsec_enteraccs.S: Save and restore MTRR_DEF_TYPE ......................................................................
Patch Set 2: Code-Review+2
Philipp Deppenwiese has submitted this change. ( https://review.coreboot.org/c/coreboot/+/46375 )
Change subject: sec/intel/txt/getsec_enteraccs.S: Save and restore MTRR_DEF_TYPE ......................................................................
sec/intel/txt/getsec_enteraccs.S: Save and restore MTRR_DEF_TYPE
This needs to be saved and restored, otherwise the BSP might have an inconsistent MTRR setup with regards to the AP's which results in weird errors and slowdowns in the operating system.
TESTED: Fixes booting OCP/Deltalake with Linux 5.8.
Change-Id: Iace636ec6fca3b4d7b2856f0f054947c5b3bc8de Signed-off-by: Arthur Heymans arthur@aheymans.xyz Reviewed-on: https://review.coreboot.org/c/coreboot/+/46375 Reviewed-by: Angel Pons th3fanbus@gmail.com Reviewed-by: Christian Walter christian.walter@9elements.com Tested-by: build bot (Jenkins) no-reply@coreboot.org --- M src/security/intel/txt/getsec_enteraccs.S 1 file changed, 2 insertions(+), 6 deletions(-)
Approvals: build bot (Jenkins): Verified Angel Pons: Looks good to me, approved Christian Walter: Looks good to me, approved
diff --git a/src/security/intel/txt/getsec_enteraccs.S b/src/security/intel/txt/getsec_enteraccs.S index 3135de7..563dc08 100644 --- a/src/security/intel/txt/getsec_enteraccs.S +++ b/src/security/intel/txt/getsec_enteraccs.S @@ -58,6 +58,7 @@ /* Reserve space on stack for GDT */ subl $8, %esp
+ PUSH_MSR MTRR_DEF_TYPE_MSR PUSH_MSR IA32_MISC_ENABLE PUSH_MSR MTRR_FIX_64K_00000 PUSH_MSR MTRR_FIX_16K_80000 @@ -290,12 +291,7 @@ POP_MSR MTRR_FIX_16K_80000 POP_MSR MTRR_FIX_64K_00000 POP_MSR IA32_MISC_ENABLE - - /* Enable fixed MTRRs */ - movl $(MTRR_DEF_TYPE_MSR), %ecx - rdmsr - orl $(MTRR_DEF_TYPE_FIX_EN), %eax - wrmsr + POP_MSR MTRR_DEF_TYPE_MSR
/* Enable cache */ movl %cr0, %eax