summaryrefslogtreecommitdiff
path: root/src/soc/intel/xeon_sp/finalize.c
diff options
context:
space:
mode:
authorMarc Jones <marcjones@sysproconsulting.com>2021-03-18 17:01:06 -0600
committerPatrick Georgi <pgeorgi@google.com>2021-04-16 06:56:05 +0000
commit352ca5b0313c514b438c4aa518be905a6eff001f (patch)
treedd7848933ae0a36ec5233bf6bc233d747703a090 /src/soc/intel/xeon_sp/finalize.c
parent051bf5d3324f529cf8f4616918b78de634fdf944 (diff)
soc/intel/xeon_sp: Call SMM finalize
Call the SMM finalize SMI. Adds SMM_FEATURE_CONTROL setting to enable MCHK on code fetch outside SMRR and the register lock as recommended by the BWG. Change-Id: Ie3b58d35c7a62509e39e393514012d1055232d32 Signed-off-by: Marc Jones <marcjones@sysproconsulting.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/51651 Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org> Reviewed-by: Rocky Phagura Reviewed-by: Jay Talbott <JayTalbott@sysproconsulting.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/soc/intel/xeon_sp/finalize.c')
-rw-r--r--src/soc/intel/xeon_sp/finalize.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/soc/intel/xeon_sp/finalize.c b/src/soc/intel/xeon_sp/finalize.c
new file mode 100644
index 0000000000..bfcf212558
--- /dev/null
+++ b/src/soc/intel/xeon_sp/finalize.c
@@ -0,0 +1,17 @@
+/* SPDX-License-Identifier: GPL-2.0-only */
+
+#include <bootstate.h>
+#include <console/console.h>
+#include <console/debug.h>
+#include <cpu/x86/smm.h>
+
+static void soc_finalize(void *unused)
+{
+ printk(BIOS_DEBUG, "Finalizing chipset.\n");
+
+ apm_control(APM_CNT_FINALIZE);
+
+ post_code(POST_OS_BOOT);
+}
+
+BOOT_STATE_INIT_ENTRY(BS_PAYLOAD_LOAD, BS_ON_ENTRY, soc_finalize, NULL);