summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristian Geddes <crgeddes@us.ibm.com>2018-11-15 11:53:46 -0600
committerDaniel M. Crowell <dcrowell@us.ibm.com>2018-11-27 13:10:41 -0600
commitb08d6146f834e3a3f44f52da26e86bbd56c68e18 (patch)
tree2eeac35e617950917b3806afbb1571b86bffb777
parent2ce1bf13b5bf0d156732b2c5f91721e15cb92f01 (diff)
downloadblackbird-hostboot-b08d6146f834e3a3f44f52da26e86bbd56c68e18.tar.gz
blackbird-hostboot-b08d6146f834e3a3f44f52da26e86bbd56c68e18.zip
Create error log and fail if Proc's EC is found to be 0x0
While looking up the SBE version we will look at the processor's EC level to determine how to lookup the version. If we find that the EC level is 0 then something went wrong. In HW the register describing the procs EC will always be fused to some non-zero so we shouldnt see this in HW , in simics if this happens it is likely because simics has not implemented this register yet. Change-Id: I24bc0caaf3d2c9a574943ca07069bd6fb99cf1a6 Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/68804 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: Matt Derksen <mderkse1@us.ibm.com> Reviewed-by: William G. Hoffa <wghoffa@us.ibm.com> Reviewed-by: Ilya Smirnov <ismirno@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
-rw-r--r--src/include/usr/sbe/sbereasoncodes.H3
-rw-r--r--src/usr/sbe/sbe_update.C29
2 files changed, 30 insertions, 2 deletions
diff --git a/src/include/usr/sbe/sbereasoncodes.H b/src/include/usr/sbe/sbereasoncodes.H
index 4dee3c6ea..4609373a5 100644
--- a/src/include/usr/sbe/sbereasoncodes.H
+++ b/src/include/usr/sbe/sbereasoncodes.H
@@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
-/* Contributors Listed Below - COPYRIGHT 2013,2017 */
+/* Contributors Listed Below - COPYRIGHT 2013,2018 */
/* [+] International Business Machines Corp. */
/* */
/* */
@@ -106,6 +106,7 @@ enum sbeReasonCode
SBE_MISMATCHED_HW_KEY_HASH = SBE_COMP_ID | 0x1A,
SBE_UPDATE_DURING_MPIPL = SBE_COMP_ID | 0x1B,
SBE_BOOT_SIDE_DIRTY_BAD_PATH = SBE_COMP_ID | 0x1C,
+ SBE_UNSUPPORTED_EC = SBE_COMP_ID | 0x1D,
};
}; // end SBE
diff --git a/src/usr/sbe/sbe_update.C b/src/usr/sbe/sbe_update.C
index 7fdd7ae14..872015085 100644
--- a/src/usr/sbe/sbe_update.C
+++ b/src/usr/sbe/sbe_update.C
@@ -747,6 +747,33 @@ namespace SBE
//Walk the TOC and find our current EC
ec = i_target->getAttr<TARGETING::ATTR_EC>();
+
+ // If ec == 0 then this indicates simics is not correctly
+ // writing EC to the FSI register we get the EC level from
+ if(ec == 0)
+ {
+ TRACFCOMP( g_trac_sbe, ERR_MRK"findSBEInPnor: invalid EC found, EC cannot be 0, check simics model" );
+
+ /*@
+ * @errortype
+ * @moduleid SBE_FIND_IN_PNOR
+ * @reasoncode SBE_UNSUPPORTED_EC
+ * @userdata1 Target Huid
+ * @userdata2 unused
+ * @devdesc EC level says 0, which is invalid
+ * @custdesc Chip level is invalid
+ */
+ err = new ErrlEntry(ERRL_SEV_UNRECOVERABLE,
+ SBE_FIND_IN_PNOR,
+ SBE_UNSUPPORTED_EC,
+ TARGETING::get_huid(i_target),
+ 0,
+ ERRORLOG::ErrlEntry::ADD_SW_CALLOUT);
+ err->collectTrace(SBE_COMP_NAME);
+
+ break;
+ }
+
for(uint32_t i=0; i<MAX_SBE_ENTRIES; i++)
{
if(static_cast<uint32_t>(ec) == sbeToc->entries[i].ec)
@@ -767,7 +794,7 @@ namespace SBE
}
}
}
-
+ // IF we failed to find hdr_Ptr then no matching EC found
if(NULL == hdr_Ptr)
{
//if we get here, it's an error
OpenPOWER on IntegriCloud