summaryrefslogtreecommitdiffstats
path: root/src/usr
diff options
context:
space:
mode:
authorJayashankar Padath <jayashankar.padath@in.ibm.com>2016-12-12 03:10:50 -0600
committerWilliam G. Hoffa <wghoffa@us.ibm.com>2017-01-12 16:48:28 -0500
commit3894e8b76643e16adb3089d975c106ae0f16aec3 (patch)
treee56ae690ff9555a2760e2a0aef0e37eb4adc0554 /src/usr
parentcaba5e2793fe5c021fead24b2157dc03d5b9133b (diff)
downloadtalos-hostboot-3894e8b76643e16adb3089d975c106ae0f16aec3.tar.gz
talos-hostboot-3894e8b76643e16adb3089d975c106ae0f16aec3.zip
HDAT: IPL Params and Ms Area changes
Change-Id: Ic457de49190cce47cf00b5d5317273af3e35b226 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/33713 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: NAGENDRA K. GURRAM <nagendra.g@in.ibm.com> Reviewed-by: William G. Hoffa <wghoffa@us.ibm.com>
Diffstat (limited to 'src/usr')
-rwxr-xr-xsrc/usr/hdat/hdatiplparms.C55
-rwxr-xr-xsrc/usr/hdat/hdatiplparms.H7
-rwxr-xr-xsrc/usr/hdat/hdatmsarea.C7
-rwxr-xr-xsrc/usr/hdat/hdatmsarea.H2
4 files changed, 70 insertions, 1 deletions
diff --git a/src/usr/hdat/hdatiplparms.C b/src/usr/hdat/hdatiplparms.C
index 01cffb564..33f2c4b3f 100755
--- a/src/usr/hdat/hdatiplparms.C
+++ b/src/usr/hdat/hdatiplparms.C
@@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
-/* Contributors Listed Below - COPYRIGHT 2016 */
+/* Contributors Listed Below - COPYRIGHT 2016,2017 */
/* [+] International Business Machines Corp. */
/* */
/* */
@@ -772,6 +772,59 @@ void HdatIplParms::hdatGetSystemParamters()
{
HDAT_ERR("Error in getting SYSTEM_BRAND_NAME");
}
+
+ //TODO RTC Story 161867
+ //Need to remove the hard coding data
+ this->iv_hdatIPLParams->iv_sysParms.hdatTpmDrawer = 1;
+
+ TARGETING::ATTR_SECURITY_ENABLE_type l_sysSecuritySetting;
+ if(l_pSysTarget->tryGetAttr<TARGETING::ATTR_SECURITY_ENABLE>
+ (l_sysSecuritySetting))
+ {
+ this->iv_hdatIPLParams->iv_sysParms.hdatSysSecuritySetting =
+ l_sysSecuritySetting;
+ }
+ else
+ {
+ HDAT_ERR("Error in getting SECURITY_ENABLE attribute");
+ }
+
+ TARGETING::ATTR_TPM_REQUIRED_type l_tpmConfBits;
+ if(l_pSysTarget->tryGetAttr<TARGETING::ATTR_TPM_REQUIRED>
+ (l_tpmConfBits))
+ {
+ this->iv_hdatIPLParams->iv_sysParms.hdatTpmConfBits = l_tpmConfBits;
+ }
+ else
+ {
+ HDAT_ERR("Error in getting TPM_REQUIRED attribute");
+ }
+ memset(this->iv_hdatIPLParams->iv_sysParms.hdatHwKeyHashValue, 0x00, 64);
+ memset(this->iv_hdatIPLParams->iv_sysParms.hdatSystemFamily, 0x00, 64);
+
+ TARGETING::ATTR_SYSTEM_FAMILY_type l_systemFamily = {0};
+ if(l_pSysTarget->tryGetAttr<TARGETING::ATTR_SYSTEM_FAMILY> (l_systemFamily))
+ {
+ strcpy(reinterpret_cast<char*>
+ (this->iv_hdatIPLParams->iv_sysParms.hdatSystemFamily),
+ l_systemFamily);
+ }
+ else
+ {
+ HDAT_ERR("Error in getting SYSTEM_FAMILY");
+ }
+
+ TARGETING::ATTR_SYSTEM_TYPE_type l_systemType = {0};
+ if(l_pSysTarget->tryGetAttr<TARGETING::ATTR_SYSTEM_TYPE> (l_systemType))
+ {
+ strcpy(reinterpret_cast<char*>
+ (this->iv_hdatIPLParams->iv_sysParms.hdatSystemType),
+ l_systemType);
+ }
+ else
+ {
+ HDAT_ERR("Error in getting SYSTEM_TYPE");
+ }
}
/**
diff --git a/src/usr/hdat/hdatiplparms.H b/src/usr/hdat/hdatiplparms.H
index 85729fb54..c8117aeb1 100755
--- a/src/usr/hdat/hdatiplparms.H
+++ b/src/usr/hdat/hdatiplparms.H
@@ -103,6 +103,13 @@ struct hdatSysParms_t
uint8_t hdatReserved4; // Reserved
uint16_t hdatReserved5; // Reserved
uint8_t hdatSystemVendorName[64]; // System Vendor Name
+ uint16_t hdatSysSecuritySetting; // System Security Settings
+ uint16_t hdatTpmConfBits; // TPM Configuration Bits
+ uint16_t hdatTpmDrawer; // TPMs/Drawer
+ uint16_t hdatReserved6; // Reserved
+ uint8_t hdatHwKeyHashValue[64]; // Hardware Keys Hash Value
+ char hdatSystemFamily[64]; // System Family/Vendor Name
+ char hdatSystemType[64]; // System Type/Vendor Type
} __attribute__ ((packed));
/** @brief Structure definition for Other IPL Attributes within hdatIPLParams_t
diff --git a/src/usr/hdat/hdatmsarea.C b/src/usr/hdat/hdatmsarea.C
index 70eb16a6b..ab3199f07 100755
--- a/src/usr/hdat/hdatmsarea.C
+++ b/src/usr/hdat/hdatmsarea.C
@@ -117,6 +117,13 @@ HdatMsArea::HdatMsArea(errlHndl_t &o_errlHndl,
iv_msId.hdatMsAreaId = i_msAreaId;
+ //TODO : RTC Story 161864
+ //For Nimbus based systems, FSI device path length is always zero so hard
+ //coding the values
+ //But for Cumulus/Centaur based systems, we need to get the actual data
+ iv_msId.hdatFsiDevicePathLen = 0;
+ memset(iv_msId.hdatFsiDevicePath, 0x00, 64);
+
iv_addrRngArrayHdr.hdatOffset = sizeof(hdatHDIFDataArray_t);
iv_addrRngArrayHdr.hdatArrayCnt = 0;
iv_addrRngArrayHdr.hdatAllocSize = sizeof(hdatMsAreaAddrRange_t);
diff --git a/src/usr/hdat/hdatmsarea.H b/src/usr/hdat/hdatmsarea.H
index 6d33a2893..f92430803 100755
--- a/src/usr/hdat/hdatmsarea.H
+++ b/src/usr/hdat/hdatmsarea.H
@@ -99,6 +99,8 @@ struct hdatMsAreaId_t
uint16_t hdatMsAreaParentType; // 0x0002 Memory parent type
uint16_t hdatMsAreaStatus; // 0x0004 Status
uint16_t hdatInterleavedId; // 0x0006 Id for MS areas which are interleaved
+ uint32_t hdatFsiDevicePathLen; // 0x0008 FSI Device Path – Actual Length
+ uint8_t hdatFsiDevicePath[64];// 0x000C FSI Device Path
} __attribute__ ((packed));
OpenPOWER on IntegriCloud