summaryrefslogtreecommitdiffstats
path: root/src/usr
diff options
context:
space:
mode:
authorsachin gupta <sgupta2m@in.ibm.com>2014-05-07 03:06:29 -0500
committerA. Patrick Williams III <iawillia@us.ibm.com>2014-06-23 13:26:10 -0500
commit9ef84477f89411212bf33adf8e08551fe51b3ae6 (patch)
tree1caa15cf1952e48ddf1b1d33ffcef536195011a2 /src/usr
parent26d89f954b77f39add10a54bac563bb762c870c9 (diff)
downloadtalos-hostboot-9ef84477f89411212bf33adf8e08551fe51b3ae6.tar.gz
talos-hostboot-9ef84477f89411212bf33adf8e08551fe51b3ae6.zip
PRD: Handle Mcs channel fail before MBIFIR[0]
Change-Id: I3f8dc7eaca5f5acf32a5d2aab2ee7c40d4fd873b CQ: SW259889 Backport: release-fips811 Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/10995 Tested-by: Jenkins Server Reviewed-by: Bilicon Patil <bilpatil@in.ibm.com> Reviewed-by: Prem Shanker Jha <premjha2@in.ibm.com> Reviewed-by: Christopher T. Phan <cphan@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com> Reviewed-by: Zane Shelley <zshelle@us.ibm.com> Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/11541
Diffstat (limited to 'src/usr')
-rwxr-xr-xsrc/usr/diag/prdf/common/plat/pegasus/Membuf_acts_NEST.rule9
-rwxr-xr-xsrc/usr/diag/prdf/common/plat/pegasus/prdfCenMembuf.C73
2 files changed, 81 insertions, 1 deletions
diff --git a/src/usr/diag/prdf/common/plat/pegasus/Membuf_acts_NEST.rule b/src/usr/diag/prdf/common/plat/pegasus/Membuf_acts_NEST.rule
index 4fa3dd346..ad37e72a5 100755
--- a/src/usr/diag/prdf/common/plat/pegasus/Membuf_acts_NEST.rule
+++ b/src/usr/diag/prdf/common/plat/pegasus/Membuf_acts_NEST.rule
@@ -424,7 +424,7 @@ group gMbiFir filter singlebit
/** MBIFIR[0]
* MBIFIRQ_REPLAY_TIMEOUT
*/
- (MbiFir, bit(0)) ? clearSecMbsBitsCalloutDmiBusTh1UE;
+ (MbiFir, bit(0)) ? replayTimeOutError;
/** MBIFIR[1]
* MBIFIRQ_CHANNEL_FAIL
@@ -1246,6 +1246,13 @@ actionclass calloutDmiBus
calloutDmiBusSymFru;
};
+
+/** Handles MCS Chnl XSTOP if present otherwise handles MBIFIR Replay Timeout */
+actionclass replayTimeOutError
+{
+ try( funccall("handleMcsChnlCs"), clearSecMbsBitsCalloutDmiBusTh1UE );
+};
+
/** Clear MBS SecondaryBits and calloutDmiBusTh1UE */
actionclass clearSecMbsBitsCalloutDmiBusTh1UE
{
diff --git a/src/usr/diag/prdf/common/plat/pegasus/prdfCenMembuf.C b/src/usr/diag/prdf/common/plat/pegasus/prdfCenMembuf.C
index f897f0a99..87cab9b58 100755
--- a/src/usr/diag/prdf/common/plat/pegasus/prdfCenMembuf.C
+++ b/src/usr/diag/prdf/common/plat/pegasus/prdfCenMembuf.C
@@ -1153,6 +1153,79 @@ int32_t checkChnlReplayTimeOut( ExtensibleChip * i_chip,
//------------------------------------------------------------------------------
/**
+ * @brief Handles MCS Channel fail bits, if they exist.
+ *
+ * @param i_membChip The Centaur chip.
+ * @param i_sc ServiceDataColector.
+ *
+ * @return SUCCESS if MCS channel fail is present and properly
+ * handled, FAIL otherwise.
+ */
+int32_t handleMcsChnlCs( ExtensibleChip * i_membChip,
+ STEP_CODE_DATA_STRUCT & i_sc )
+{
+ #define PRDF_FUNC "[handleMcsChnlCs] "
+
+ // We will return FAIL from this function if MCS channel fail bits
+ // are not set. If MCS channel fail bits are set, we will try to analyze
+ // Mcs. If MCS is not analyzed properly, we will return FAIL.
+ // This will trigger rule code to execute alternate resolution.
+
+ int32_t l_rc = SUCCESS;
+ do
+ {
+ CenMembufDataBundle * mbdb = getMembufDataBundle( i_membChip );
+ ExtensibleChip * mcsChip = mbdb->getMcsChip();
+ if( NULL == mcsChip )
+ {
+ l_rc = FAIL;
+ break;
+ }
+
+ SCAN_COMM_REGISTER_CLASS * mciFir = mcsChip->getRegister("MCIFIR");
+ SCAN_COMM_REGISTER_CLASS * mciFirMask =
+ mcsChip->getRegister("MCIFIR_MASK");
+
+ l_rc = mciFir->Read();
+ l_rc |= mciFirMask->Read();
+
+ if ( SUCCESS != l_rc )
+ {
+ PRDF_ERR( PRDF_FUNC"MCIFIR/MCIFIR_MASK read failed for 0x%08x",
+ mcsChip->GetId());
+ break;
+ }
+
+ // If any of MCS channel fail bit is set, we will analyze
+ // MCS. It is safe to do hard coded check as channel fail
+ // bits are hard wired and and they can not change without HW
+ // change.
+ // bits 0,1, 6, 8, 9, 22, 23, 40 are channel fail bits.
+ uint64_t chnlCsBitsMask = 0xC2C0030000800000ull;
+ uint64_t mciFirBits = mciFir->GetBitFieldJustified(0, 64);
+ uint64_t mciFirMaskBits = mciFirMask->GetBitFieldJustified(0, 64);
+
+ if( ( mciFirBits & ( ~mciFirMaskBits ) ) &
+ chnlCsBitsMask )
+ {
+ l_rc = mcsChip->Analyze( i_sc,
+ i_sc.service_data->GetCauseAttentionType() );
+
+ if( SUCCESS == l_rc ) break;
+ }
+
+ l_rc = FAIL;
+
+ }while( 0 );
+
+ return l_rc;
+ #undef PRDF_FUNC
+
+} PRDF_PLUGIN_DEFINE( Membuf, handleMcsChnlCs );
+
+//------------------------------------------------------------------------------
+
+/**
* @brief When not in MNFG mode, clear the service call flag so that
* thresholding will still be done, but no visible error log committed.
* @param i_chip Centaur chip
OpenPOWER on IntegriCloud