summaryrefslogtreecommitdiffstats
path: root/src/usr/diag/prdf/common/plat/p9
diff options
context:
space:
mode:
Diffstat (limited to 'src/usr/diag/prdf/common/plat/p9')
-rw-r--r--src/usr/diag/prdf/common/plat/p9/p9_common_actions.rule9
-rw-r--r--src/usr/diag/prdf/common/plat/p9/p9_common_obus_actions.rule146
-rw-r--r--src/usr/diag/prdf/common/plat/p9/p9_common_obus_regs.rule9
-rw-r--r--src/usr/diag/prdf/common/plat/p9/p9_common_proc_actions.rule3
-rw-r--r--src/usr/diag/prdf/common/plat/p9/prdfCommonPlugins.C82
-rw-r--r--src/usr/diag/prdf/common/plat/p9/prdfLaneRepair.C122
-rw-r--r--src/usr/diag/prdf/common/plat/p9/prdfLaneRepair.H8
-rwxr-xr-xsrc/usr/diag/prdf/common/plat/p9/prdfP9Configurator.C27
-rw-r--r--src/usr/diag/prdf/common/plat/p9/prdfP9Obus.C193
-rw-r--r--src/usr/diag/prdf/common/plat/p9/prdfP9OcmbChipDomain.C78
-rw-r--r--src/usr/diag/prdf/common/plat/p9/prdfP9OcmbChipDomain.H12
-rw-r--r--src/usr/diag/prdf/common/plat/p9/prdf_plat_p9.mk3
12 files changed, 618 insertions, 74 deletions
diff --git a/src/usr/diag/prdf/common/plat/p9/p9_common_actions.rule b/src/usr/diag/prdf/common/plat/p9/p9_common_actions.rule
index 669d3e5b5..2e7e32869 100644
--- a/src/usr/diag/prdf/common/plat/p9/p9_common_actions.rule
+++ b/src/usr/diag/prdf/common/plat/p9/p9_common_actions.rule
@@ -5,7 +5,7 @@
#
# OpenPOWER HostBoot Project
#
-# Contributors Listed Below - COPYRIGHT 2016,2018
+# Contributors Listed Below - COPYRIGHT 2016,2019
# [+] International Business Machines Corp.
#
#
@@ -208,6 +208,12 @@ actionclass parent_proc_th_1
threshold1;
};
+actionclass parent_proc_th_32perDay
+{
+ callout(connected(TYPE_PROC), MRU_MED);
+ threshold32pday;
+};
+
actionclass level2_M_proc_L_th_1
{
callout2ndLvlMed;
@@ -273,4 +279,3 @@ actionclass chip_to_chip
calloutSelfMed;
threshold1;
};
-
diff --git a/src/usr/diag/prdf/common/plat/p9/p9_common_obus_actions.rule b/src/usr/diag/prdf/common/plat/p9/p9_common_obus_actions.rule
index 6590bb122..700e87649 100644
--- a/src/usr/diag/prdf/common/plat/p9/p9_common_obus_actions.rule
+++ b/src/usr/diag/prdf/common/plat/p9/p9_common_obus_actions.rule
@@ -5,7 +5,7 @@
#
# OpenPOWER HostBoot Project
#
-# Contributors Listed Below - COPYRIGHT 2018
+# Contributors Listed Below - COPYRIGHT 2018,2019
# [+] International Business Machines Corp.
#
#
@@ -88,6 +88,150 @@ actionclass obusSmpFailure_L1
threshold1;
};
+actionclass smp_masked
+{
+ # If SMP mode, does defaultMaskedError action and returns SUCCESS.
+ # Otherwise, returns PRD_SCAN_COMM_REGISTER_ZERO.
+ funccall( "smp_masked" ); # If SMP mode
+};
+
+actionclass non_smp_masked
+{
+ # If NOT in SMP mode, does defaultMaskedError action and returns SUCCESS.
+ # Otherwise, returns PRD_SCAN_COMM_REGISTER_ZERO.
+ funccall( "non_smp_masked" );
+};
+
+actionclass non_smp_callout_bus_th_1
+{
+ # NOTE: We cannot put the threshold action in this actionclass because it
+ # will affect the SMP action in the try() statement. Therefore, the
+ # plugin must handle the thresholding if in non-SMP mode.
+
+ # If NOT in SMP mode:
+ # - calls out this OBUS
+ # - indicates the probably may be somewhere between this OBUS and whatever
+ # is on the other side (which we know nothing about)
+ # - sets threshold
+ # - sets service call
+ # - returns SUCCESS
+ # Otherwise
+ # - returns PRD_SCAN_COMM_REGISTER_ZERO
+ funccall( "non_smp_callout_bus_th_1" );
+};
+
+actionclass non_smp_callout_lvl2_th_1
+{
+ # NOTE: We cannot put the threshold action in this actionclass because it
+ # will affect the SMP action in the try() statement. Therefore, the
+ # plugin must handle the thresholding if in non-SMP mode.
+
+ # If NOT in SMP mode:
+ # - calls out level 2 support
+ # - sets threshold
+ # - sets service call
+ # - returns SUCCESS
+ # Otherwise
+ # - returns PRD_SCAN_COMM_REGISTER_ZERO
+ funccall( "non_smp_callout_lvl2_th_1" );
+};
+
+actionclass non_smp_callout_self_th_32perDay
+{
+ threshold32pday; # This is ok because it is greater than threshold1.
+
+ # If NOT in SMP mode:
+ # - calls out this OBUS
+ # - returns SUCCESS
+ # Otherwise
+ # - returns PRD_SCAN_COMM_REGISTER_ZERO
+ funccall( "non_smp_callout_self" );
+};
+
+actionclass threshold_and_mask_self_non_smp_only
+{
+ # SMP: masked
+ # Non-SMP: threshold_and_mask_self
+ try ( smp_masked, threshold_and_mask_self );
+};
+
+actionclass threshold_and_mask_self_smp_only
+{
+ # SMP: threshold_and_mask_self
+ # Non-SMP: masked
+ try ( non_smp_masked, threshold_and_mask_self );
+};
+
+actionclass obusSmpCallout_L0_smp_only
+{
+ # SMP: obusSmpCallout_L0
+ # Non-SMP: masked
+ try ( non_smp_masked, obusSmpCallout_L0 );
+};
+
+actionclass obusSmpCallout_L1_smp_only
+{
+ # SMP: obusSmpCallout_L1
+ # Non-SMP: masked
+ try ( non_smp_masked, obusSmpCallout_L1 );
+};
+
+actionclass spare_lane_degraded_mode_L0
+{
+ # SMP: obusSmpCallout_th32_L0 (lane spare)
+ # Non-SMP: non_smp_callout_bus_th_1 (degraded mode)
+ try ( non_smp_callout_bus_th_1, obusSmpCallout_th32_L0 );
+};
+
+actionclass spare_lane_degraded_mode_L1
+{
+ # SMP: obusSmpCallout_th32_L1 (lane spare)
+ # Non-SMP: non_smp_callout_bus_th_1 (degraded mode)
+ try ( non_smp_callout_bus_th_1, obusSmpCallout_th32_L1 );
+};
+
+actionclass training_failure_L0
+{
+ # SMP: obusSmpFailure_L0
+ # Non-SMP: non_smp_callout_lvl2_th_1
+ try ( non_smp_callout_lvl2_th_1, obusSmpFailure_L0 );
+};
+
+actionclass training_failure_L1
+{
+ # SMP: obusSmpFailure_L1
+ # Non-SMP: non_smp_callout_lvl2_th_1
+ try ( non_smp_callout_lvl2_th_1, obusSmpFailure_L1 );
+};
+
+actionclass unrecoverable_error_L0
+{
+ # SMP: obusSmpFailure_L0
+ # Non-SMP: non_smp_callout_bus_th_1
+ try ( non_smp_callout_bus_th_1, obusSmpFailure_L0 );
+};
+
+actionclass unrecoverable_error_L1
+{
+ # SMP: obusSmpFailure_L1
+ # Non-SMP: non_smp_callout_bus_th_1
+ try ( non_smp_callout_bus_th_1, obusSmpFailure_L1 );
+};
+
+actionclass internal_error_L0
+{
+ # SMP: obusSmpFailure_L0
+ # Non-SMP: non_smp_callout_self_th_32perDay
+ try ( non_smp_callout_self_th_32perDay, obusSmpFailure_L0 );
+};
+
+actionclass internal_error_L1
+{
+ # SMP: obusSmpFailure_L1
+ # Non-SMP: non_smp_callout_self_th_32perDay
+ try ( non_smp_callout_self_th_32perDay, obusSmpFailure_L1 );
+};
+
###############################################################################
# Analyze groups
###############################################################################
diff --git a/src/usr/diag/prdf/common/plat/p9/p9_common_obus_regs.rule b/src/usr/diag/prdf/common/plat/p9/p9_common_obus_regs.rule
index 461fbc664..bc25fba5d 100644
--- a/src/usr/diag/prdf/common/plat/p9/p9_common_obus_regs.rule
+++ b/src/usr/diag/prdf/common/plat/p9/p9_common_obus_regs.rule
@@ -5,7 +5,7 @@
#
# OpenPOWER HostBoot Project
#
-# Contributors Listed Below - COPYRIGHT 2016,2018
+# Contributors Listed Below - COPYRIGHT 2016,2019
# [+] International Business Machines Corp.
#
#
@@ -85,6 +85,13 @@
capture group default;
};
+ register MISC_ERROR_STATUS
+ {
+ name "P9 OBUS target Misc Error Status register";
+ scomaddr 0x09010829;
+ capture group default;
+ };
+
############################################################################
# P9 OBUS targets for cable FFDC
# One additional reg (IOOLFIR) is in default group
diff --git a/src/usr/diag/prdf/common/plat/p9/p9_common_proc_actions.rule b/src/usr/diag/prdf/common/plat/p9/p9_common_proc_actions.rule
index aacf978bd..e5700c34b 100644
--- a/src/usr/diag/prdf/common/plat/p9/p9_common_proc_actions.rule
+++ b/src/usr/diag/prdf/common/plat/p9/p9_common_proc_actions.rule
@@ -5,7 +5,7 @@
#
# OpenPOWER HostBoot Project
#
-# Contributors Listed Below - COPYRIGHT 2017,2018
+# Contributors Listed Below - COPYRIGHT 2017,2019
# [+] International Business Machines Corp.
#
#
@@ -670,7 +670,6 @@ actionclass analyzePBIOOFIR { analyze(gPBIOOFIR ); };
actionclass analyzePBAFIR { analyze(gPBAFIR ); };
actionclass analyzePSIHBFIR { analyze(gPSIHBFIR ); };
actionclass analyzePBAMFIR { analyze(gPBAMFIR ); };
-actionclass analyzeENHCAFIR { analyze(gENHCAFIR ); };
actionclass analyzeXB_LFIR { analyze(gXB_LFIR ); };
actionclass analyzeXBPPEFIR { analyze(gXBPPEFIR ); };
diff --git a/src/usr/diag/prdf/common/plat/p9/prdfCommonPlugins.C b/src/usr/diag/prdf/common/plat/p9/prdfCommonPlugins.C
index ece3fc1a8..730f99f09 100644
--- a/src/usr/diag/prdf/common/plat/p9/prdfCommonPlugins.C
+++ b/src/usr/diag/prdf/common/plat/p9/prdfCommonPlugins.C
@@ -127,6 +127,88 @@ PRDF_PLUGIN_DEFINE_NS(nimbus_proc, CommonPlugins, ClearServiceCallFlag_mnfgInfo
PRDF_PLUGIN_DEFINE_NS(cumulus_proc, CommonPlugins, ClearServiceCallFlag_mnfgInfo);
PRDF_PLUGIN_DEFINE_NS(axone_proc, CommonPlugins, ClearServiceCallFlag_mnfgInfo);
+/**
+ * @brief Will change the gard state of any NVDIMMs in the callout list to
+ * NO_GARD.
+ * @param i_chip The chip.
+ * @param io_sc The step code data struct.
+ * @returns SUCCESS
+ */
+int32_t ClearNvdimmGardState( ExtensibleChip * i_chip,
+ STEP_CODE_DATA_STRUCT & io_sc )
+{
+ #ifdef __HOSTBOOT_MODULE
+
+ // Call the sdc to clear the NVDIMM mru list.
+ io_sc.service_data->clearNvdimmMruListGard();
+
+ #endif
+
+ return SUCCESS;
+}
+PRDF_PLUGIN_DEFINE_NS(nimbus_mca, CommonPlugins, ClearNvdimmGardState);
+
+/**
+ * @brief Will check if any of the DIMMs connected to this chip are NVDIMMs
+ * and send a message to PHYP/Hostboot that save/restore may work. If
+ * we are at IPL, we will callout self no gard instead of garding.
+ * @param i_chip The chip of the DIMM parent.
+ * @param io_sc The step code data struct.
+ * @returns SUCCESS if NVDIMMs found at IPL, PRD_SCAN_COMM_REGISTER_ZERO if not.
+ */
+int32_t CheckForNvdimms( ExtensibleChip * i_chip,
+ STEP_CODE_DATA_STRUCT & io_sc )
+{
+ int32_t rc = PRD_SCAN_COMM_REGISTER_ZERO;
+
+ #ifdef CONFIG_NVDIMM
+ #ifdef __HOSTBOOT_MODULE
+
+ TargetHandleList dimmList = getConnected( i_chip->getTrgt(), TYPE_DIMM );
+
+ // Always loop through all the dimms so we send the
+ // nvdimmNotifyProtChange message for all the NVDIMMs on the target.
+ for ( auto & dimm : dimmList )
+ {
+ // If the callout target is an NVDIMM send a message to
+ // PHYP/Hostboot that a save/restore may work, and if we are at
+ // IPL, do not gard the target.
+ if ( isNVDIMM(dimm) )
+ {
+ // Send the message to PHYP/Hostboot
+ uint32_t l_rc = PlatServices::nvdimmNotifyProtChange( dimm,
+ NVDIMM::NVDIMM_RISKY_HW_ERROR );
+ if ( SUCCESS != l_rc )
+ {
+ PRDF_TRAC( "CheckForNvdimms: nvdimmNotifyProtChange(0x%08x)"
+ " failed.", PlatServices::getHuid(dimm) );
+ continue;
+ }
+
+ #ifndef __HOSTBOOT_RUNTIME
+ // IPL
+ // We will callout self, no gard. No need for another self callout
+ // from the rule code, so return SUCCESS.
+ rc = SUCCESS;
+ #endif
+ }
+ }
+
+ if ( SUCCESS == rc )
+ {
+ // Callout self, no gard
+ io_sc.service_data->SetCallout( i_chip->getTrgt(), MRU_MED, NO_GARD );
+ }
+
+ #endif // __HOSTBOOT_MODULE
+ #endif // CONFIG_NVDIMM
+
+ return rc;
+}
+PRDF_PLUGIN_DEFINE_NS(nimbus_mcs, CommonPlugins, CheckForNvdimms);
+PRDF_PLUGIN_DEFINE_NS(nimbus_mca, CommonPlugins, CheckForNvdimms);
+PRDF_PLUGIN_DEFINE_NS(nimbus_mcbist, CommonPlugins, CheckForNvdimms);
+
} // namespace CommonPlugins ends
}// namespace PRDF ends
diff --git a/src/usr/diag/prdf/common/plat/p9/prdfLaneRepair.C b/src/usr/diag/prdf/common/plat/p9/prdfLaneRepair.C
index 6cb4e6535..6ad889fd5 100644
--- a/src/usr/diag/prdf/common/plat/p9/prdfLaneRepair.C
+++ b/src/usr/diag/prdf/common/plat/p9/prdfLaneRepair.C
@@ -75,6 +75,16 @@ TargetHandle_t getTxBusEndPt( TargetHandle_t i_rxTrgt)
// grab connected DMI parent
o_txTrgt = getConnectedParent( i_rxTrgt, TYPE_DMI );
}
+ else if ( TYPE_OMI == busType )
+ {
+ // Get connected child OCMB (one OCMB per OMI)
+ o_txTrgt = getConnectedChild( i_rxTrgt, TYPE_OCMB_CHIP, 0 );
+ }
+ else if ( TYPE_OCMB_CHIP == busType )
+ {
+ // Get connected parent OMI
+ o_txTrgt = getConnectedParent( i_rxTrgt, TYPE_OMI );
+ }
PRDF_ASSERT(nullptr != o_txTrgt);
return o_txTrgt;
@@ -310,38 +320,6 @@ int32_t __handleLaneRepairEvent( ExtensibleChip * i_chip,
#undef PRDF_FUNC
}
-template<>
-int32_t __handleLaneRepairEvent<TYPE_OBUS, TYPE_OBUS>( ExtensibleChip * i_chip,
- STEP_CODE_DATA_STRUCT & i_sc,
- bool i_spareDeployed )
-{
- TargetHandle_t rxBusTgt = i_chip->getTrgt();
-
- // Make predictive on first occurrence in MFG
- if ( isLaneRepairDisabled<TYPE_OBUS>() )
- {
- i_sc.service_data->setServiceCall();
- }
-
- // RTC 174485
- // Need HWPs for this. Just callout bus interface for now.
- if ( obusInSmpMode(rxBusTgt) )
- {
- calloutBusInterface( i_chip, i_sc, MRU_LOW );
- i_sc.service_data->setServiceCall();
- }
- else
- {
- PRDF_ERR( "__handleLaneRepairEvent: Lane repair only supported "
- "in SMP mode obus: 0x%08x", getHuid(rxBusTgt) );
- i_sc.service_data->SetCallout( LEVEL2_SUPPORT, MRU_MED, NO_GARD );
- i_sc.service_data->SetCallout( SP_CODE, MRU_MED, NO_GARD );
- i_sc.service_data->setServiceCall();
- }
- return SUCCESS;
-}
-
-
int32_t handleLaneRepairEvent( ExtensibleChip * i_chip,
STEP_CODE_DATA_STRUCT & i_sc,
bool i_spareDeployed )
@@ -350,10 +328,6 @@ int32_t handleLaneRepairEvent( ExtensibleChip * i_chip,
TYPE trgtType = getTargetType(i_chip->getTrgt());
switch (trgtType)
{
- case TYPE_OBUS:
- rc = __handleLaneRepairEvent<TYPE_OBUS,TYPE_OBUS>( i_chip, i_sc,
- i_spareDeployed );
- break;
case TYPE_XBUS:
rc = __handleLaneRepairEvent<TYPE_XBUS,TYPE_XBUS>( i_chip, i_sc,
i_spareDeployed );
@@ -729,6 +703,8 @@ void obus_clearMaskFail( errlHndl_t &io_errl, TargetHandle_t &i_rxTrgt,
PRDF_ASSERT( NULL != i_txTrgt );
PRDF_ASSERT( NULL != io_errl );
+#ifdef __HOSTBOOT_MODULE // register writes not allowed on FSP
+
uint32_t l_rc = SUCCESS;
ExtensibleChip *l_rxChip =
(ExtensibleChip *)systemPtr->GetChip( i_rxTrgt );
@@ -790,6 +766,8 @@ void obus_clearMaskFail( errlHndl_t &io_errl, TargetHandle_t &i_rxTrgt,
} while (0);
+#endif // __HOSTBOOT_MODULE
+
} // end obus_clearMaskFail
@@ -924,7 +902,7 @@ PRDF_PLUGIN_DEFINE_NS( cumulus_proc, LaneRepair, captureSmpObus3 );
PRDF_PLUGIN_DEFINE_NS( nimbus_proc, LaneRepair, captureSmpObus3 );
PRDF_PLUGIN_DEFINE_NS( axone_proc, LaneRepair, captureSmpObus3 );
-int32_t calloutBusInterface( ExtensibleChip * i_chip,
+int32_t calloutBusInterface( TargetHandle_t i_rxTrgt,
STEP_CODE_DATA_STRUCT & i_sc,
PRDpriority i_priority )
{
@@ -934,10 +912,9 @@ int32_t calloutBusInterface( ExtensibleChip * i_chip,
do {
// Get both endpoints
- TargetHandle_t rxTrgt = i_chip->getTrgt();
- TYPE rxType = getTargetType(rxTrgt);
+ TYPE rxType = getTargetType(i_rxTrgt);
- if ( rxType == TYPE_OBUS && !obusInSmpMode( rxTrgt ) )
+ if ( rxType == TYPE_OBUS && !obusInSmpMode( i_rxTrgt ) )
{
// There is no support in hostboot for calling out the other end of
// an NV or openCAPI bus. By design, any FIR bits associated with
@@ -945,7 +922,7 @@ int32_t calloutBusInterface( ExtensibleChip * i_chip,
// action. So if we hit this case, just make a default callout.
PRDF_ERR( PRDF_FUNC "Lane repair only supported in SMP mode "
- "obus: 0x%08x", getHuid(rxTrgt) );
+ "obus: 0x%08x", getHuid(i_rxTrgt) );
i_sc.service_data->SetCallout( LEVEL2_SUPPORT, MRU_MED, NO_GARD );
i_sc.service_data->SetCallout( SP_CODE, MRU_MED, NO_GARD );
@@ -953,11 +930,11 @@ int32_t calloutBusInterface( ExtensibleChip * i_chip,
break;
}
- TargetHandle_t txTrgt = getTxBusEndPt(rxTrgt);
+ TargetHandle_t txTrgt = getTxBusEndPt(i_rxTrgt);
TYPE txType = getTargetType(txTrgt);
// Add the endpoint target callouts
- i_sc.service_data->SetCallout( rxTrgt, MRU_MEDA );
+ i_sc.service_data->SetCallout( i_rxTrgt, MRU_MEDA );
i_sc.service_data->SetCallout( txTrgt, MRU_MEDA);
// Get the HWAS bus type.
@@ -975,6 +952,11 @@ int32_t calloutBusInterface( ExtensibleChip * i_chip,
{
hwasType = HWAS::DMI_BUS_TYPE;
}
+ else if ( (TYPE_OMI == rxType && TYPE_OCMB_CHIP == txType) ||
+ (TYPE_OCMB_CHIP == rxType && TYPE_OMI == txType) )
+ {
+ hwasType = HWAS::OMI_BUS_TYPE;
+ }
else
{
PRDF_ASSERT( false );
@@ -990,7 +972,7 @@ int32_t calloutBusInterface( ExtensibleChip * i_chip,
}
// Callout this bus interface.
- PRDF_ADD_BUS_CALLOUT( errl, rxTrgt, txTrgt, hwasType, i_priority );
+ PRDF_ADD_BUS_CALLOUT( errl, i_rxTrgt, txTrgt, hwasType, i_priority );
} while(0);
@@ -1020,9 +1002,6 @@ int32_t spareDeployed( ExtensibleChip * i_chip,
PRDF_PLUGIN_DEFINE_NS( nimbus_xbus, LaneRepair, spareDeployed );
PRDF_PLUGIN_DEFINE_NS( cumulus_xbus, LaneRepair, spareDeployed );
PRDF_PLUGIN_DEFINE_NS( axone_xbus, LaneRepair, spareDeployed );
-PRDF_PLUGIN_DEFINE_NS( nimbus_obus, LaneRepair, spareDeployed );
-PRDF_PLUGIN_DEFINE_NS( cumulus_obus, LaneRepair, spareDeployed );
-PRDF_PLUGIN_DEFINE_NS( axone_obus, LaneRepair, spareDeployed );
PRDF_PLUGIN_DEFINE_NS( centaur_membuf, LaneRepair, spareDeployed );
/**
@@ -1042,9 +1021,6 @@ int32_t maxSparesExceeded( ExtensibleChip * i_chip,
PRDF_PLUGIN_DEFINE_NS( nimbus_xbus, LaneRepair, maxSparesExceeded );
PRDF_PLUGIN_DEFINE_NS( cumulus_xbus, LaneRepair, maxSparesExceeded );
PRDF_PLUGIN_DEFINE_NS( axone_xbus, LaneRepair, maxSparesExceeded );
-PRDF_PLUGIN_DEFINE_NS( nimbus_obus, LaneRepair, maxSparesExceeded );
-PRDF_PLUGIN_DEFINE_NS( cumulus_obus, LaneRepair, maxSparesExceeded );
-PRDF_PLUGIN_DEFINE_NS( axone_obus, LaneRepair, maxSparesExceeded );
PRDF_PLUGIN_DEFINE_NS( centaur_membuf, LaneRepair, maxSparesExceeded );
/**
@@ -1064,9 +1040,6 @@ int32_t tooManyBusErrors( ExtensibleChip * i_chip,
PRDF_PLUGIN_DEFINE_NS( nimbus_xbus, LaneRepair, tooManyBusErrors );
PRDF_PLUGIN_DEFINE_NS( cumulus_xbus, LaneRepair, tooManyBusErrors );
PRDF_PLUGIN_DEFINE_NS( axone_xbus, LaneRepair, tooManyBusErrors );
-PRDF_PLUGIN_DEFINE_NS( nimbus_obus, LaneRepair, tooManyBusErrors );
-PRDF_PLUGIN_DEFINE_NS( cumulus_obus, LaneRepair, tooManyBusErrors );
-PRDF_PLUGIN_DEFINE_NS( axone_obus, LaneRepair, tooManyBusErrors );
PRDF_PLUGIN_DEFINE_NS( centaur_membuf, LaneRepair, tooManyBusErrors );
/**
@@ -1078,18 +1051,53 @@ PRDF_PLUGIN_DEFINE_NS( centaur_membuf, LaneRepair, tooManyBusErrors );
int32_t calloutBusInterfacePlugin( ExtensibleChip * i_chip,
STEP_CODE_DATA_STRUCT & io_sc )
{
- calloutBusInterface(i_chip, io_sc, MRU_LOW);
+ calloutBusInterface(i_chip->getTrgt(), io_sc, MRU_LOW);
return SUCCESS;
}
PRDF_PLUGIN_DEFINE_NS( nimbus_xbus, LaneRepair, calloutBusInterfacePlugin );
PRDF_PLUGIN_DEFINE_NS( cumulus_xbus, LaneRepair, calloutBusInterfacePlugin );
PRDF_PLUGIN_DEFINE_NS( axone_xbus, LaneRepair, calloutBusInterfacePlugin );
-PRDF_PLUGIN_DEFINE_NS( nimbus_obus, LaneRepair, calloutBusInterfacePlugin );
-PRDF_PLUGIN_DEFINE_NS( cumulus_obus, LaneRepair, calloutBusInterfacePlugin );
-PRDF_PLUGIN_DEFINE_NS( axone_obus, LaneRepair, calloutBusInterfacePlugin );
+PRDF_PLUGIN_DEFINE_NS( explorer_ocmb, LaneRepair, calloutBusInterfacePlugin );
PRDF_PLUGIN_DEFINE_NS( cumulus_dmi, LaneRepair, calloutBusInterfacePlugin );
PRDF_PLUGIN_DEFINE_NS( centaur_membuf, LaneRepair, calloutBusInterfacePlugin );
+/**
+ * @brief Add callouts for a BUS interface inputting an OMIC or MCC target
+ * @param i_chip OMIC/MCC chip
+ * @param io_sc Step code data struct.
+ * @param i_pos The position of the OMI relative to the OMIC/MCC.
+ * @return SUCCESS always
+ */
+
+int32_t omiParentCalloutBusInterfacePlugin( ExtensibleChip * i_chip,
+ STEP_CODE_DATA_STRUCT & io_sc,
+ uint8_t i_pos )
+{
+ TargetHandle_t omi = getConnectedChild(i_chip->getTrgt(), TYPE_OMI, i_pos);
+ TargetHandle_t ocmb = getConnectedChild( omi, TYPE_OCMB_CHIP, 0 );
+
+ // Callout both ends of the bus as well (OMI and OCMB)
+ io_sc.service_data->SetCallout( omi, MRU_MEDA );
+ io_sc.service_data->SetCallout( ocmb, MRU_MEDA );
+
+ calloutBusInterface(omi, io_sc, MRU_LOW);
+ return SUCCESS;
+}
+
+#define OMI_PARENT_CALL_BUS_PLUGIN( POS ) \
+int32_t omiParentCalloutBusInterfacePlugin_##POS( ExtensibleChip * i_chip, \
+ STEP_CODE_DATA_STRUCT & io_sc ) \
+{ \
+ return omiParentCalloutBusInterfacePlugin( i_chip, io_sc, POS ); \
+} \
+PRDF_PLUGIN_DEFINE_NS( axone_omic, LaneRepair, \
+ omiParentCalloutBusInterfacePlugin_##POS );\
+PRDF_PLUGIN_DEFINE_NS( axone_mcc, LaneRepair, \
+ omiParentCalloutBusInterfacePlugin_##POS );
+
+OMI_PARENT_CALL_BUS_PLUGIN( 0 );
+OMI_PARENT_CALL_BUS_PLUGIN( 1 );
+OMI_PARENT_CALL_BUS_PLUGIN( 2 );
//------------------------------------------------------------------------------
diff --git a/src/usr/diag/prdf/common/plat/p9/prdfLaneRepair.H b/src/usr/diag/prdf/common/plat/p9/prdfLaneRepair.H
index afc834e29..3f5a3f33c 100644
--- a/src/usr/diag/prdf/common/plat/p9/prdfLaneRepair.H
+++ b/src/usr/diag/prdf/common/plat/p9/prdfLaneRepair.H
@@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
-/* Contributors Listed Below - COPYRIGHT 2017 */
+/* Contributors Listed Below - COPYRIGHT 2017,2019 */
/* [+] International Business Machines Corp. */
/* */
/* */
@@ -56,12 +56,12 @@ int32_t handleLaneRepairEvent (ExtensibleChip * i_chip,
/**
* @brief Will add target bus interface endpoints and all parts in between the
* endpoints to the global error log in RasServices.
- * @param i_chip RX-side chip of bus interface
- * @param i_sc The step code data struct.
+ * @param i_rxTrgt RX-side target of bus interface
+ * @param i_sc The step code data struct.
* @param i_priority Callout priority (default MRU_LOW).
* @return Non-SUCCESS if an internal function fails. SUCCESS otherwise.
*/
-int32_t calloutBusInterface( ExtensibleChip * i_chip,
+int32_t calloutBusInterface( TARGETING::TargetHandle_t i_rxTrgt,
STEP_CODE_DATA_STRUCT & i_sc,
PRDpriority i_priority = MRU_LOW );
diff --git a/src/usr/diag/prdf/common/plat/p9/prdfP9Configurator.C b/src/usr/diag/prdf/common/plat/p9/prdfP9Configurator.C
index e37cffcd3..7c3033dc2 100755
--- a/src/usr/diag/prdf/common/plat/p9/prdfP9Configurator.C
+++ b/src/usr/diag/prdf/common/plat/p9/prdfP9Configurator.C
@@ -243,7 +243,7 @@ errlHndl_t PlatConfigurator::addDomainChips( TARGETING::TYPE i_type,
{
errlHndl_t errl = nullptr;
- std::map<TARGETING::MODEL, std::map<TARGETING::TYPE, const char *>> fnMap =
+ std::map<uint32_t, std::map<TARGETING::TYPE, const char *>> fnMap =
{
{ MODEL_NIMBUS, { { TYPE_PROC, nimbus_proc },
{ TYPE_EQ, nimbus_eq },
@@ -285,7 +285,14 @@ errlHndl_t PlatConfigurator::addDomainChips( TARGETING::TYPE i_type,
{ TYPE_MI, axone_mi },
{ TYPE_MCC, axone_mcc },
{ TYPE_OMIC, axone_omic }, } },
- { MODEL_EXPLORER, { { TYPE_OCMB_CHIP, explorer_ocmb }, } },
+ #ifdef __HOSTBOOT_MODULE
+ { POWER_CHIPID::EXPLORER_16, { { TYPE_OCMB_CHIP, explorer_ocmb }, } },
+ #endif
+ // OCMB is not supported on FSP, however we need support here for the
+ // MODEL_OCMB model for our simulator to work.
+ #ifdef ESW_SIM_COMPILE
+ { MODEL_OCMB, { { TYPE_OCMB_CHIP, explorer_ocmb }, } },
+ #endif
};
// Get references to factory objects.
@@ -299,7 +306,19 @@ errlHndl_t PlatConfigurator::addDomainChips( TARGETING::TYPE i_type,
// Iterate all the targets for this type and add to given domain.
for ( const auto & trgt : getFunctionalTargetList(i_type) )
{
- TARGETING::MODEL model = getChipModel( trgt );
+ uint32_t model = getChipModel( trgt );
+
+ #ifdef __HOSTBOOT_MODULE
+ // Special case for OCMBs (hostboot only issue for P9).
+ if ( MODEL_OCMB == model )
+ {
+ // Use the chip ID instead of model.
+ model = getChipId( trgt );
+
+ // Skip Gemini OCMBs. They can exist, but PRD won't support them.
+ if ( POWER_CHIPID::GEMINI_16 == model ) continue;
+ }
+ #endif
// Ensure this model is supported.
if ( fnMap.end() == fnMap.find(model) )
@@ -350,8 +369,6 @@ errlHndl_t PlatConfigurator::addDomainChips( TARGETING::TYPE i_type,
scanFac, resFac );
break;
- // TODO RTC 199020 - add the pll domains for axone
-
default: ;
}
}
diff --git a/src/usr/diag/prdf/common/plat/p9/prdfP9Obus.C b/src/usr/diag/prdf/common/plat/p9/prdfP9Obus.C
new file mode 100644
index 000000000..6117c6edc
--- /dev/null
+++ b/src/usr/diag/prdf/common/plat/p9/prdfP9Obus.C
@@ -0,0 +1,193 @@
+/* IBM_PROLOG_BEGIN_TAG */
+/* This is an automatically generated prolog. */
+/* */
+/* $Source: src/usr/diag/prdf/common/plat/p9/prdfP9Obus.C $ */
+/* */
+/* OpenPOWER HostBoot Project */
+/* */
+/* Contributors Listed Below - COPYRIGHT 2019 */
+/* [+] International Business Machines Corp. */
+/* */
+/* */
+/* Licensed under the Apache License, Version 2.0 (the "License"); */
+/* you may not use this file except in compliance with the License. */
+/* You may obtain a copy of the License at */
+/* */
+/* http://www.apache.org/licenses/LICENSE-2.0 */
+/* */
+/* Unless required by applicable law or agreed to in writing, software */
+/* distributed under the License is distributed on an "AS IS" BASIS, */
+/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or */
+/* implied. See the License for the specific language governing */
+/* permissions and limitations under the License. */
+/* */
+/* IBM_PROLOG_END_TAG */
+
+
+// Framework includes
+#include <iipServiceDataCollector.h>
+#include <prdfExtensibleChip.H>
+#include <prdfPluginMap.H>
+
+// Platform includes
+#include <prdfPlatServices.H>
+
+using namespace TARGETING;
+
+namespace PRDF
+{
+
+using namespace PlatServices;
+
+namespace obus
+{
+
+//##############################################################################
+//
+// IOOLFIR
+//
+//##############################################################################
+
+/**
+ * @brief If OBUS is in SMP mode, does defaultMaskedError actions and returns
+ * SUCCESS. Otherwise, returns PRD_SCAN_COMM_REGISTER_ZERO.
+ */
+int32_t smp_masked( ExtensibleChip * i_chip, STEP_CODE_DATA_STRUCT & io_sc )
+{
+ if ( obusInSmpMode(i_chip->getTrgt()) )
+ {
+ // SMP mode: This attention should be masked.
+ io_sc.service_data->SetCallout( LEVEL2_SUPPORT, MRU_MED, NO_GARD );
+ io_sc.service_data->setFlag( ServiceDataCollector::AT_THRESHOLD );
+ io_sc.service_data->setFlag( ServiceDataCollector::SERVICE_CALL );
+ return SUCCESS;
+ }
+ else
+ {
+ // Non-SMP mode: Try some other action.
+ return PRD_SCAN_COMM_REGISTER_ZERO;
+ }
+}
+PRDF_PLUGIN_DEFINE_NS( nimbus_obus, obus, smp_masked );
+PRDF_PLUGIN_DEFINE_NS( cumulus_obus, obus, smp_masked );
+PRDF_PLUGIN_DEFINE_NS( axone_obus, obus, smp_masked );
+
+//------------------------------------------------------------------------------
+
+/**
+ * @brief If OBUS is NOT in SMP mode, does defaultMaskedError actions and
+ * returns SUCCESS. Otherwise, returns PRD_SCAN_COMM_REGISTER_ZERO.
+ */
+int32_t non_smp_masked( ExtensibleChip * i_chip, STEP_CODE_DATA_STRUCT & io_sc )
+{
+ if ( obusInSmpMode(i_chip->getTrgt()) )
+ {
+ // SMP mode: Try some other action.
+ return PRD_SCAN_COMM_REGISTER_ZERO;
+ }
+ else
+ {
+ // Non-SMP mode: This attention should be masked.
+ io_sc.service_data->SetCallout( LEVEL2_SUPPORT, MRU_MED, NO_GARD );
+ io_sc.service_data->setFlag( ServiceDataCollector::AT_THRESHOLD );
+ io_sc.service_data->setFlag( ServiceDataCollector::SERVICE_CALL );
+ return SUCCESS;
+ }
+}
+PRDF_PLUGIN_DEFINE_NS( nimbus_obus, obus, non_smp_masked );
+PRDF_PLUGIN_DEFINE_NS( cumulus_obus, obus, non_smp_masked );
+PRDF_PLUGIN_DEFINE_NS( axone_obus, obus, non_smp_masked );
+
+//------------------------------------------------------------------------------
+
+/**
+ * @brief If OBUS is NOT in SMP mode, calls out this bus on first occurrence and
+ * returns SUCCESS. Otherwise, returns PRD_SCAN_COMM_REGISTER_ZERO.
+ */
+int32_t non_smp_callout_bus_th_1( ExtensibleChip * i_chip,
+ STEP_CODE_DATA_STRUCT & io_sc )
+{
+ if ( obusInSmpMode(i_chip->getTrgt()) )
+ {
+ // SMP mode: Try some other action.
+ return PRD_SCAN_COMM_REGISTER_ZERO;
+ }
+ else
+ {
+ // Non-SMP mode: Callout this bus. Note that Hostboot does not know what
+ // is on the other side of this bus and does not have any control over
+ // garding/deconfiguring. Therefore, we cannot gard since we will never
+ // know if the other side of the bus has been replaced. Also, there is
+ // a small probability that the fault could be between the two
+ // endpoints. Usually, we would do a procedure callout or call some HWP
+ // that would take care of the "everything in between" scenario.
+ // However, there is no existing mechanism. For now callout level 2
+ // support at low priority.
+ io_sc.service_data->SetCallout( i_chip->getTrgt(), MRU_MED, NO_GARD );
+ io_sc.service_data->SetCallout( LEVEL2_SUPPORT, MRU_LOW, NO_GARD );
+ io_sc.service_data->setFlag( ServiceDataCollector::AT_THRESHOLD );
+ io_sc.service_data->setFlag( ServiceDataCollector::SERVICE_CALL );
+ return SUCCESS;
+ }
+}
+PRDF_PLUGIN_DEFINE_NS( nimbus_obus, obus, non_smp_callout_bus_th_1 );
+PRDF_PLUGIN_DEFINE_NS( cumulus_obus, obus, non_smp_callout_bus_th_1 );
+PRDF_PLUGIN_DEFINE_NS( axone_obus, obus, non_smp_callout_bus_th_1 );
+
+//------------------------------------------------------------------------------
+
+/**
+ * @brief If OBUS is NOT in SMP mode, calls out level 2 support on first
+ * occurrence and returns SUCCESS. Otherwise, returns
+ * PRD_SCAN_COMM_REGISTER_ZERO.
+ */
+int32_t non_smp_callout_lvl2_th_1( ExtensibleChip * i_chip,
+ STEP_CODE_DATA_STRUCT & io_sc )
+{
+ if ( obusInSmpMode(i_chip->getTrgt()) )
+ {
+ // SMP mode: Try some other action.
+ return PRD_SCAN_COMM_REGISTER_ZERO;
+ }
+ else
+ {
+ // Non-SMP mode: Callout this bus on first occurrence.
+ io_sc.service_data->SetCallout( LEVEL2_SUPPORT, MRU_MED, NO_GARD );
+ io_sc.service_data->setFlag( ServiceDataCollector::AT_THRESHOLD );
+ io_sc.service_data->setFlag( ServiceDataCollector::SERVICE_CALL );
+ return SUCCESS;
+ }
+}
+PRDF_PLUGIN_DEFINE_NS( nimbus_obus, obus, non_smp_callout_lvl2_th_1 );
+PRDF_PLUGIN_DEFINE_NS( cumulus_obus, obus, non_smp_callout_lvl2_th_1 );
+PRDF_PLUGIN_DEFINE_NS( axone_obus, obus, non_smp_callout_lvl2_th_1 );
+
+//------------------------------------------------------------------------------
+
+/**
+ * @brief If OBUS is NOT in SMP mode, calls out this OBUS target and returns
+ * SUCCESS. Otherwise, returns PRD_SCAN_COMM_REGISTER_ZERO.
+ */
+int32_t non_smp_callout_self( ExtensibleChip * i_chip,
+ STEP_CODE_DATA_STRUCT & io_sc )
+{
+ if ( obusInSmpMode(i_chip->getTrgt()) )
+ {
+ // SMP mode: Try some other action.
+ return PRD_SCAN_COMM_REGISTER_ZERO;
+ }
+ else
+ {
+ // Non-SMP mode: Callout this OBUS target.
+ io_sc.service_data->SetCallout( i_chip->getTrgt() );
+ return SUCCESS;
+ }
+}
+PRDF_PLUGIN_DEFINE_NS( nimbus_obus, obus, non_smp_callout_self );
+PRDF_PLUGIN_DEFINE_NS( cumulus_obus, obus, non_smp_callout_self );
+PRDF_PLUGIN_DEFINE_NS( axone_obus, obus, non_smp_callout_self );
+
+} // end namespace obus
+
+} // end namespace PRDF
+
diff --git a/src/usr/diag/prdf/common/plat/p9/prdfP9OcmbChipDomain.C b/src/usr/diag/prdf/common/plat/p9/prdfP9OcmbChipDomain.C
new file mode 100644
index 000000000..2f6c25646
--- /dev/null
+++ b/src/usr/diag/prdf/common/plat/p9/prdfP9OcmbChipDomain.C
@@ -0,0 +1,78 @@
+/* IBM_PROLOG_BEGIN_TAG */
+/* This is an automatically generated prolog. */
+/* */
+/* $Source: src/usr/diag/prdf/common/plat/p9/prdfP9OcmbChipDomain.C $ */
+/* */
+/* OpenPOWER HostBoot Project */
+/* */
+/* Contributors Listed Below - COPYRIGHT 2019 */
+/* [+] International Business Machines Corp. */
+/* */
+/* */
+/* Licensed under the Apache License, Version 2.0 (the "License"); */
+/* you may not use this file except in compliance with the License. */
+/* You may obtain a copy of the License at */
+/* */
+/* http://www.apache.org/licenses/LICENSE-2.0 */
+/* */
+/* Unless required by applicable law or agreed to in writing, software */
+/* distributed under the License is distributed on an "AS IS" BASIS, */
+/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or */
+/* implied. See the License for the specific language governing */
+/* permissions and limitations under the License. */
+/* */
+/* IBM_PROLOG_END_TAG */
+
+/**
+ * @file prdfP9OcmbChipDomain.C
+ * @brief chip Plug-in code for OCMB domain
+ */
+
+#include <prdfP9OcmbChipDomain.H>
+
+// Framework includes
+#include <prdfExtensibleChip.H>
+#include <prdfPlatServices.H>
+#include <prdfTrace.H>
+#include <prdfOcmbDataBundle.H>
+
+using namespace TARGETING;
+
+namespace PRDF
+{
+
+using namespace PlatServices;
+
+#ifdef __HOSTBOOT_RUNTIME
+void OcmbChipDomain::handleRrFo()
+{
+ #define PRDF_FUNC "[OcmbChipDomain::handleRrFo] "
+
+ do
+ {
+ uint32_t domainSize = GetSize();
+ // Iterate all OCMBs in the domain.
+ for ( uint32_t i = 0; i < domainSize; ++i )
+ {
+ RuleChip * ocmbChip = LookUp(i);
+
+ // Start background scrub if required.
+ OcmbDataBundle * ocmbdb = getOcmbDataBundle( ocmbChip );
+ int32_t l_rc = ocmbdb->getTdCtlr()->handleRrFo();
+ if ( SUCCESS != l_rc )
+ {
+ // Let us not fail here. If problem is contained within an OCMB
+ // we will discover it again during normal TD procedures.
+ PRDF_ERR( PRDF_FUNC "handleRrFo() failed: OCMB=0x%08x",
+ ocmbChip->GetId() );
+ continue; // Keep going.
+ }
+ }
+
+ } while (0);
+
+ #undef PRDF_FUNC
+}
+#endif
+
+} // end namespace PRDF
diff --git a/src/usr/diag/prdf/common/plat/p9/prdfP9OcmbChipDomain.H b/src/usr/diag/prdf/common/plat/p9/prdfP9OcmbChipDomain.H
index 5546d9453..9f5776cac 100644
--- a/src/usr/diag/prdf/common/plat/p9/prdfP9OcmbChipDomain.H
+++ b/src/usr/diag/prdf/common/plat/p9/prdfP9OcmbChipDomain.H
@@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
-/* Contributors Listed Below - COPYRIGHT 2018 */
+/* Contributors Listed Below - COPYRIGHT 2018,2019 */
/* [+] International Business Machines Corp. */
/* */
/* */
@@ -54,6 +54,16 @@ class OcmbChipDomain : public RuleChipDomain
virtual bool Query( ATTENTION_TYPE i_attnType )
{ return false; }
+ #ifdef __HOSTBOOT_RUNTIME
+
+ /**
+ * @brief Starts memory background scrubbing or VCM procedure for OCMB
+ * during R/R and F/O if required.
+ */
+ void handleRrFo();
+
+ #endif
+
};
} // end namespace PRDF
diff --git a/src/usr/diag/prdf/common/plat/p9/prdf_plat_p9.mk b/src/usr/diag/prdf/common/plat/p9/prdf_plat_p9.mk
index cb69cad14..64092650f 100644
--- a/src/usr/diag/prdf/common/plat/p9/prdf_plat_p9.mk
+++ b/src/usr/diag/prdf/common/plat/p9/prdf_plat_p9.mk
@@ -5,7 +5,7 @@
#
# OpenPOWER HostBoot Project
#
-# Contributors Listed Below - COPYRIGHT 2016,2018
+# Contributors Listed Below - COPYRIGHT 2016,2019
# [+] International Business Machines Corp.
#
#
@@ -56,4 +56,5 @@ prd_rule_plugin += prdfP9Eq.o
prd_rule_plugin += prdfP9TodPlugins.o
prd_rule_plugin += prdfP9Dmi_common.o
prd_rule_plugin += prdfP9Mc_common.o
+prd_rule_plugin += prdfP9Obus.o
OpenPOWER on IntegriCloud