diff options
author | Mike Baiocchi <mbaiocch@us.ibm.com> | 2019-09-12 09:00:52 -0500 |
---|---|---|
committer | Nicholas E Bofferding <bofferdn@us.ibm.com> | 2019-11-14 08:28:02 -0600 |
commit | 35964668f9dc302401ff03c691e579a4c48eecea (patch) | |
tree | 2d1f1274e4b9b55826421fc23f3f19d43c33747d /src/usr/isteps/istep06/call_host_update_master_tpm.C | |
parent | eace166aa1ef265712798d84f10782f7bc430be7 (diff) | |
download | talos-hostboot-35964668f9dc302401ff03c691e579a4c48eecea.tar.gz talos-hostboot-35964668f9dc302401ff03c691e579a4c48eecea.zip |
Add Physical Presence Check and Window Open Features
This commit does the following:
- Adds an interface to detect if physical presence has been asserted
-- This happens in istep 6
-- If the window is open to detect this, it is then closed here
- Adds an interface to possibly open the window to look for physical presence
-- This happens in istep 10
-- It first checks to see if the window should be opened
-- If the window is opened then the system shuts down to wait for
physical presence to be asserted on the next power on
- Adds the necessary attributes to support and test this functionality
RTC:211220
Change-Id: I05a26ebad581875a4b9f2a51eb1ca3062f36c5fb
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/84656
Reviewed-by: Ilya Smirnov <ismirno@us.ibm.com>
Reviewed-by: Christopher J Engel <cjengel@us.ibm.com>
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com>
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Reviewed-by: Nicholas E Bofferding <bofferdn@us.ibm.com>
Diffstat (limited to 'src/usr/isteps/istep06/call_host_update_master_tpm.C')
-rw-r--r-- | src/usr/isteps/istep06/call_host_update_master_tpm.C | 28 |
1 files changed, 24 insertions, 4 deletions
diff --git a/src/usr/isteps/istep06/call_host_update_master_tpm.C b/src/usr/isteps/istep06/call_host_update_master_tpm.C index 284d43450..fa374f279 100644 --- a/src/usr/isteps/istep06/call_host_update_master_tpm.C +++ b/src/usr/isteps/istep06/call_host_update_master_tpm.C @@ -5,7 +5,7 @@ /* */ /* OpenPOWER HostBoot Project */ /* */ -/* Contributors Listed Below - COPYRIGHT 2015,2018 */ +/* Contributors Listed Below - COPYRIGHT 2015,2019 */ /* [+] International Business Machines Corp. */ /* */ /* */ @@ -31,6 +31,8 @@ #include <trustedbootif.H> #include <initservice/isteps_trace.H> #include <secureboot/service.H> +#include <secureboot/phys_presence_if.H> +#include <config.h> namespace ISTEP_06 { @@ -39,7 +41,7 @@ void* call_host_update_master_tpm( void *io_pArgs ) { ISTEP_ERROR::IStepError l_stepError; - TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, + TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_host_update_master_tpm entry" ); errlHndl_t l_err = nullptr; @@ -67,10 +69,28 @@ void* call_host_update_master_tpm( void *io_pArgs ) ERRORLOG::errlCommit( l_err, SECURE_COMP_ID ); } - TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, - "call_host_update_master_tpm exit" ); + // Check for Physical Presence +#ifdef CONFIG_PHYS_PRES_PWR_BUTTON + l_err = SECUREBOOT::detectPhysPresence(); + if (l_err) + { + // @TODO RTC 210301 - Handle Error Log Correctly, but for now + // just delete it + TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace, + "call_host_update_master_tpm: Error back from " + "SECUREBOOT::detectPhysPresence: rc=0x%X, plid=0x%X. " + "Deleting error for now", + ERRL_GETRC_SAFE(l_err), ERRL_GETPLID_SAFE(l_err)); + delete l_err; + l_err = nullptr; + } +#endif + TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace, + "call_host_update_master_tpm exit" ); return l_stepError.getErrorHandle(); + + } }; |