summaryrefslogtreecommitdiffstats
path: root/src/usr/targeting/attrrp.C
diff options
context:
space:
mode:
authorNick Bofferding <bofferdn@us.ibm.com>2017-03-24 16:57:21 -0500
committerDaniel M. Crowell <dcrowell@us.ibm.com>2017-04-18 10:18:41 -0400
commit1fd74670b3b0feb31971d3814aa355057cb4f008 (patch)
tree71f1228120d3dbc91c6666bf7dcc340415ce3d84 /src/usr/targeting/attrrp.C
parente226f146c5b4451af2c2074b86f195cc367c4787 (diff)
downloadtalos-hostboot-1fd74670b3b0feb31971d3814aa355057cb4f008.tar.gz
talos-hostboot-1fd74670b3b0feb31971d3814aa355057cb4f008.zip
Securely load targeting binary (HBD) when secureboot compiled
RTC: 167774 Change-Id: Id422001e8c0e489efdd466f58ad8cd79978737ee Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/38432 Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Diffstat (limited to 'src/usr/targeting/attrrp.C')
-rwxr-xr-xsrc/usr/targeting/attrrp.C16
1 files changed, 15 insertions, 1 deletions
diff --git a/src/usr/targeting/attrrp.C b/src/usr/targeting/attrrp.C
index f67ac831f..2536f2769 100755
--- a/src/usr/targeting/attrrp.C
+++ b/src/usr/targeting/attrrp.C
@@ -49,6 +49,7 @@
#include <sys/misc.h>
#include <fapi2/plat_attr_override_sync.H>
#include <targeting/attrPlatOverride.H>
+#include <config.h>
using namespace INITSERVICE;
using namespace ERRORLOG;
@@ -286,12 +287,25 @@ namespace TARGETING
do
{
+ #ifdef CONFIG_SECUREBOOT
+ // Securely load HB_DATA section
+ l_errl = PNOR::loadSecureSection(PNOR::HB_DATA);
+ if (l_errl)
+ {
+ break;
+ }
+ #endif
+
// Locate attribute section in PNOR.
PNOR::SectionInfo_t l_pnorSectionInfo;
TargetingHeader* l_header = nullptr;
l_errl = PNOR::getSectionInfo(PNOR::HB_DATA,
l_pnorSectionInfo);
- if (l_errl) break;
+ if(l_errl)
+ {
+ break;
+ }
+
if(!iv_isMpipl)
{
// Find attribute section header.
OpenPOWER on IntegriCloud