diff options
author | Marty Gloff <mgloff@us.ibm.com> | 2016-12-30 15:25:42 -0600 |
---|---|---|
committer | William G. Hoffa <wghoffa@us.ibm.com> | 2017-02-13 14:16:34 -0500 |
commit | 54896a9c0e2dd4991899e3f9ee07766786814b48 (patch) | |
tree | 5b803a04a14184d8c011d5a62278e39b4012aa02 /src/usr/hwas/common | |
parent | 3192051cd7b428aa85469525ce1595ab669332fe (diff) | |
download | talos-hostboot-54896a9c0e2dd4991899e3f9ee07766786814b48.tar.gz talos-hostboot-54896a9c0e2dd4991899e3f9ee07766786814b48.zip |
Disable bad MCAs based on CRP0:Lx keyword data
The CRP0 record has 8 records (L1-L8) that correspond to the 8 ports
(MCA targets) for the chip. One of the fields inside the keyword indicates
if the port is disabled. This field marks the MCA as non-functional, but
the MCA remains present.
Change-Id: I2c7c89c9567ec9f048a426b2204b18e10ccda601
RTC:166354
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/34256
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>
Reviewed-by: Christian R. Geddes <crgeddes@us.ibm.com>
Reviewed-by: William G. Hoffa <wghoffa@us.ibm.com>
Diffstat (limited to 'src/usr/hwas/common')
-rw-r--r-- | src/usr/hwas/common/hwas.C | 88 |
1 files changed, 39 insertions, 49 deletions
diff --git a/src/usr/hwas/common/hwas.C b/src/usr/hwas/common/hwas.C index 38cc9d4a5..0aaa0246b 100644 --- a/src/usr/hwas/common/hwas.C +++ b/src/usr/hwas/common/hwas.C @@ -2495,67 +2495,57 @@ void calculateEffectiveEC() errlHndl_t markDisabledMcas() { errlHndl_t l_errl = nullptr; - uint8_t lxData[HWAS::VPD_CRP0_LX_DATA_LENGTH]; + uint8_t lxData[HWAS::VPD_CRP0_LX_HDR_DATA_LENGTH]; HWAS_INF("markDisabledMcas entry"); do { - //Get all functional chips - TARGETING::TargetHandleList l_procList; - getAllChips(l_procList, TYPE_PROC); + //Get the functional MCAs + TargetHandleList l_mcaList; + getAllChiplets(l_mcaList, TYPE_MCA, true); - //Loop through all functional procs - for(auto l_proc : l_procList) + for (auto l_mca : l_mcaList) { - //Get the functional MCAs for this proc - TargetHandleList l_mcaList; - getChildChiplets(l_mcaList, l_proc, TYPE_MCA, true); - - for (auto l_mca : l_mcaList) - { - // fill the Lx data buffer with zeros - memset(lxData, 0x00, VPD_CRP0_LX_DATA_LENGTH); + // fill the Lx data buffer with zeros + memset(lxData, 0x00, VPD_CRP0_LX_HDR_DATA_LENGTH); #ifdef __HOSTBOOT_MODULE - //@TODO RTC:167294 Need to remove conditional after - // additional implementation - //Read Lx keyword for associated proc and MCA - l_errl = platReadLx(l_proc, - l_mca, - lxData); + //@TODO RTC:167294 Need to remove conditional after + // additional implementation + //Read Lx keyword for associated proc and MCA + l_errl = platReadLx(l_mca, + lxData); #endif - if (l_errl) - { - // commit the error but keep going - errlCommit(l_errl, HWAS_COMP_ID); - } + if (l_errl) + { + // commit the error but keep going + errlCommit(l_errl, HWAS_COMP_ID); + } - if (lxData[VPD_CRP0_LX_FREQ_INDEP_INDEX - + VPD_CRP0_LX_PORT_DISABLED] != 0) - { - // Since port is disabled, MCA is not functional, but - // it's present. - enableHwasState(l_mca, - true, // present - false, // not functional - DeconfigGard::DECONFIGURED_BY_DISABLED_PORT - ); - HWAS_DBG("MCA %.8X - marked present, not functional", - l_mca->getAttr<ATTR_HUID>()); - - TargetInfo l_TargetInfo; - l_TargetInfo.affinityPath = - l_mca->getAttr<ATTR_AFFINITY_PATH>(); - l_TargetInfo.pThisTarget = l_mca; - l_TargetInfo.type = l_mca->getAttr<ATTR_TYPE>(); - l_TargetInfo.reason = - DeconfigGard::DECONFIGURED_BY_DISABLED_PORT; - - // Deconfigure child targets for this MCA - deconfigPresentByAssoc(l_TargetInfo); - } + if (lxData[VPD_CRP0_LX_FREQ_INDEP_INDEX + + VPD_CRP0_LX_PORT_DISABLED] != 0) + { + // Since port is disabled, MCA is not functional, but + // it's present. + enableHwasState(l_mca, + true, // present + false, // not functional + DeconfigGard::DECONFIGURED_BY_DISABLED_PORT); + HWAS_DBG("MCA %.8X - marked present, not functional", + l_mca->getAttr<ATTR_HUID>()); + + TargetInfo l_TargetInfo; + l_TargetInfo.affinityPath = + l_mca->getAttr<ATTR_AFFINITY_PATH>(); + l_TargetInfo.pThisTarget = l_mca; + l_TargetInfo.type = l_mca->getAttr<ATTR_TYPE>(); + l_TargetInfo.reason = + DeconfigGard::DECONFIGURED_BY_DISABLED_PORT; + + // Deconfigure child targets for this MCA + deconfigPresentByAssoc(l_TargetInfo); } } |