[coreboot-gerrit] Change in coreboot[master]: intel/cannonlake: Perform lockdown in bootstate after MRC write

Marshall Dawson (Code Review) gerrit at coreboot.org
Tue Dec 19 00:28:08 CET 2017


Marshall Dawson has uploaded this change for review. ( https://review.coreboot.org/22938


Change subject: intel/cannonlake: Perform lockdown in bootstate after MRC write
......................................................................

intel/cannonlake: Perform lockdown in bootstate after MRC write

The bootstate where MRC data is written to flash is now variable.  Make
the lockdown procedure's timing variable too, and follow the write by
one state.

Change-Id: I7e8776e216e2be9ba54a97dbd79b840806e12469
Signed-off-by: Marshall Dawson <marshalldawson3rd at gmail.com>
---
M src/soc/intel/cannonlake/lockdown.c
1 file changed, 18 insertions(+), 2 deletions(-)



  git pull ssh://review.coreboot.org:29418/coreboot refs/changes/38/22938/1

diff --git a/src/soc/intel/cannonlake/lockdown.c b/src/soc/intel/cannonlake/lockdown.c
index dba5901..d9f6da6 100644
--- a/src/soc/intel/cannonlake/lockdown.c
+++ b/src/soc/intel/cannonlake/lockdown.c
@@ -109,5 +109,21 @@
 	pmc_lockdown_cfg(config);
 }
 
-BOOT_STATE_INIT_ENTRY(BS_DEV_RESOURCES, BS_ON_EXIT, platform_lockdown_config,
-				NULL);
+#define LOCKDOWN_BOOTSTATE (CONFIG_MRC_WRITE_BOOTSTATE + 1)
+
+#if LOCKDOWN_BOOTSTATE == 3
+BOOT_STATE_INIT_ENTRY(BS_DEV_RESOURCES, BS_ON_EXIT,
+				platform_lockdown_config, NULL);
+#elif LOCKDOWN_BOOTSTATE == 4
+BOOT_STATE_INIT_ENTRY(BS_DEV_ENABLE, BS_ON_EXIT,
+				platform_lockdown_config, NULL);
+#elif LOCKDOWN_BOOTSTATE == 5
+BOOT_STATE_INIT_ENTRY(BS_DEV_INIT, BS_ON_EXIT,
+				platform_lockdown_config, NULL);
+#elif LOCKDOWN_BOOTSTATE == 6
+BOOT_STATE_INIT_ENTRY(BS_POST_DEVICE, BS_ON_EXIT,
+				platform_lockdown_config, NULL);
+#elif LOCKDOWN_BOOTSTATE == 7
+BOOT_STATE_INIT_ENTRY(BS_OS_RESUME_CHECK, BS_ON_EXIT,
+				platform_lockdown_config, NULL);
+#endif

-- 
To view, visit https://review.coreboot.org/22938
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings

Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I7e8776e216e2be9ba54a97dbd79b840806e12469
Gerrit-Change-Number: 22938
Gerrit-PatchSet: 1
Gerrit-Owner: Marshall Dawson <marshalldawson3rd at gmail.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.coreboot.org/pipermail/coreboot-gerrit/attachments/20171218/fce4558f/attachment.html>


More information about the coreboot-gerrit mailing list