summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIlya Smirnov <ismirno@us.ibm.com>2018-05-29 12:54:33 -0500
committerDaniel M. Crowell <dcrowell@us.ibm.com>2018-06-04 17:20:33 -0400
commitb77dbedc8f3c6597e409618e9a495bd616fe1c4f (patch)
tree15be19d6ff7e131a52d34254d8ac66a48a629692
parent07cf2ea6e01303fdf6b8a04a08e0089326e0311a (diff)
downloadtalos-hostboot-b77dbedc8f3c6597e409618e9a495bd616fe1c4f.tar.gz
talos-hostboot-b77dbedc8f3c6597e409618e9a495bd616fe1c4f.zip
Add Locking of Abus Sec Mailboxes
Add logic to support Abus security mailbox locking to p9_update_security_ctrl. This updated procedure will be called in istep 18 to secure the Abus mailboxes. Change-Id: Ie89df465299856d39dc5fa2bba6f9a9c38da469a RTC: 191005 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/59489 Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Tested-by: Hostboot CI <hostboot-ci+hostboot@us.ibm.com> Reviewed-by: Nicholas E. Bofferding <bofferdn@us.ibm.com> Reviewed-by: Michael Baiocchi <mbaiocch@us.ibm.com> Reviewed-by: Jennifer A. Stofer <stofer@us.ibm.com> Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/59495 Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
-rw-r--r--src/import/chips/p9/procedures/hwp/perv/p9_update_security_ctrl.C11
-rw-r--r--src/import/chips/p9/procedures/hwp/perv/p9_update_security_ctrl.H7
2 files changed, 14 insertions, 4 deletions
diff --git a/src/import/chips/p9/procedures/hwp/perv/p9_update_security_ctrl.C b/src/import/chips/p9/procedures/hwp/perv/p9_update_security_ctrl.C
index ab8235584..800869370 100644
--- a/src/import/chips/p9/procedures/hwp/perv/p9_update_security_ctrl.C
+++ b/src/import/chips/p9/procedures/hwp/perv/p9_update_security_ctrl.C
@@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
-/* Contributors Listed Below - COPYRIGHT 2016,2017 */
+/* Contributors Listed Below - COPYRIGHT 2016,2018 */
/* [+] International Business Machines Corp. */
/* */
/* */
@@ -49,7 +49,8 @@
fapi2::ReturnCode p9_update_security_ctrl(const fapi2::Target<fapi2::TARGET_TYPE_PROC_CHIP>& i_target_chip,
- bool i_force_security)
+ bool i_force_security,
+ bool i_lock_sec_mailboxes)
{
FAPI_INF("p9_update_security_ctrl : Entering ...");
@@ -82,6 +83,12 @@ fapi2::ReturnCode p9_update_security_ctrl(const fapi2::Target<fapi2::TARGET_TYPE
l_data64.setBit<PU_SECURITY_SWITCH_REGISTER_I2CM_TPM_DECONFIG_PROTECT>();
}
+ //Set bit 8 to set Abus mailbox lock
+ if(i_lock_sec_mailboxes)
+ {
+ l_data64.setBit<PU_SECURITY_SWITCH_REGISTER_ABUS_LOCK>();
+ }
+
FAPI_TRY(fapi2::putScom(i_target_chip, PU_SECURITY_SWITCH_REGISTER_SCOM, l_data64));
}
else
diff --git a/src/import/chips/p9/procedures/hwp/perv/p9_update_security_ctrl.H b/src/import/chips/p9/procedures/hwp/perv/p9_update_security_ctrl.H
index ddf167960..68d4a0584 100644
--- a/src/import/chips/p9/procedures/hwp/perv/p9_update_security_ctrl.H
+++ b/src/import/chips/p9/procedures/hwp/perv/p9_update_security_ctrl.H
@@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
-/* Contributors Listed Below - COPYRIGHT 2016,2017 */
+/* Contributors Listed Below - COPYRIGHT 2016,2018 */
/* [+] International Business Machines Corp. */
/* */
/* */
@@ -51,11 +51,14 @@ typedef fapi2::ReturnCode (*p9_update_security_ctrl_FP_t)(const fapi2::Target<fa
///
/// @param[in] i_target_chip Reference to TARGET_TYPE_PROC_CHIP target
/// @param[in] i_force_security Forces setting of SUL and TDP (if attribute is set)
+/// @param[in] i_lock_sec_mailboxes Forces locking of Abus security mailboxes
+/// (only if security is asserted on the machine).
/// @return FAPI2_RC_SUCCESS if success, else error code.
extern "C"
{
fapi2::ReturnCode p9_update_security_ctrl(const fapi2::Target<fapi2::TARGET_TYPE_PROC_CHIP>& i_target_chip,
- bool i_force_security = false);
+ bool i_force_security = false,
+ bool i_lock_sec_mailboxes = false);
}
#endif
OpenPOWER on IntegriCloud