summaryrefslogtreecommitdiffstats
path: root/src/usr/hwpf
diff options
context:
space:
mode:
authorElliott Dahle <dedahle@us.ibm.com>2014-05-23 15:48:37 -0500
committerA. Patrick Williams III <iawillia@us.ibm.com>2014-05-29 11:08:46 -0500
commitc417ae8cd562fb538cc3011a38ff1d9f2268748c (patch)
tree2cb61248f63256353c71b78b3d067b8f7da88540 /src/usr/hwpf
parentf212a564bd2f47527f3ee8ae83abb96974c1e3c2 (diff)
downloadtalos-hostboot-c417ae8cd562fb538cc3011a38ff1d9f2268748c.tar.gz
talos-hostboot-c417ae8cd562fb538cc3011a38ff1d9f2268748c.zip
Revert mss_power_cleanup wrapper code to original
Change-Id: If5e546d1db0fd8e007e98bd24ba04889fc677870 RTC:96762 Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/11273 Tested-by: Jenkins Server Reviewed-by: Brian H. Horton <brianh@linux.ibm.com> Reviewed-by: William H. Schwartz <whs@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
Diffstat (limited to 'src/usr/hwpf')
-rw-r--r--src/usr/hwpf/hwp/dram_initialization/dram_initialization.C69
1 files changed, 28 insertions, 41 deletions
diff --git a/src/usr/hwpf/hwp/dram_initialization/dram_initialization.C b/src/usr/hwpf/hwp/dram_initialization/dram_initialization.C
index 490618443..557de278e 100644
--- a/src/usr/hwpf/hwp/dram_initialization/dram_initialization.C
+++ b/src/usr/hwpf/hwp/dram_initialization/dram_initialization.C
@@ -435,6 +435,7 @@ void* call_proc_pcie_config( void *io_pArgs )
//
void* call_mss_power_cleanup( void *io_pArgs )
{
+ errlHndl_t l_err = NULL;
IStepError l_stepError;
TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
@@ -443,16 +444,8 @@ void* call_mss_power_cleanup( void *io_pArgs )
// Get a list of all present Centaurs
TargetHandleList l_presCentaurs;
getChipResources(l_presCentaurs, TYPE_MEMBUF, UTIL_FILTER_PRESENT);
- // Associated MBA targets
- TARGETING::TargetHandleList l_mbaList;
-
- // Define predicate for associated MBAs
- PredicateCTM predMba(CLASS_UNIT, TYPE_MBA);
- PredicatePostfixExpr presMba;
- PredicateHwas predPres;
- predPres.present(true);
- presMba.push(&predMba).push(&predPres).And();
+ // For each present Centaur
for (TargetHandleList::const_iterator
l_cenIter = l_presCentaurs.begin();
l_cenIter != l_presCentaurs.end();
@@ -464,18 +457,13 @@ void* call_mss_power_cleanup( void *io_pArgs )
TARGETING::ATTR_HUID_type l_currCentaurHuid =
TARGETING::get_huid(l_pCentaur);
- // Dump current run on target
- TRACFCOMP(ISTEPS_TRACE::g_trac_isteps_trace,
- "Running mss_power_cleanup HWP on "
- "target HUID %.8X", l_currCentaurHuid);
-
- // find all present MBAs associated with this Centaur
+ // Find all present MBAs associated with this Centaur
TARGETING::TargetHandleList l_presMbas;
- targetService().getAssociated(l_presMbas,
- l_pCentaur,
- TargetService::CHILD,
- TargetService::IMMEDIATE,
- &presMba);
+ getChildAffinityTargetsByState(l_presMbas,
+ l_pCentaur,
+ CLASS_UNIT,
+ TYPE_MBA,
+ UTIL_FILTER_PRESENT);
// If not at least two MBAs found
if (l_presMbas.size() < 2)
@@ -487,13 +475,17 @@ void* call_mss_power_cleanup( void *io_pArgs )
continue;
}
- // Dump current run on target
+ // Cache current MBA HUIDs for tracing
+ TARGETING::ATTR_HUID_type l_currMBA0Huid =
+ TARGETING::get_huid(l_presMbas[0]);
+ TARGETING::ATTR_HUID_type l_currMBA1Huid =
+ TARGETING::get_huid(l_presMbas[1]);
+
TRACFCOMP(ISTEPS_TRACE::g_trac_isteps_trace,
"Running mss_power_cleanup HWP on "
"Centaur HUID %.8X, MBA0 HUID %.8X, "
"MBA1 HUID %.8X, ", l_currCentaurHuid,
- TARGETING::get_huid(l_presMbas[0]),
- TARGETING::get_huid(l_presMbas[1]));
+ l_currMBA0Huid, l_currMBA1Huid);
// Create FAPI Targets.
const fapi::Target l_fapiCentaurTarget(TARGET_TYPE_MEMBUF_CHIP,
@@ -502,37 +494,32 @@ void* call_mss_power_cleanup( void *io_pArgs )
(const_cast<TARGETING::Target*>(l_presMbas[0])));
const fapi::Target l_fapiMba1Target(TARGET_TYPE_MBA_CHIPLET,
(const_cast<TARGETING::Target*>(l_presMbas[1])));
- // call the HWP with each fapi::Target
- errlHndl_t l_err = NULL;
+
+ // Call the HWP with each fapi::Target
FAPI_INVOKE_HWP(l_err, mss_power_cleanup, l_fapiCentaurTarget,
l_fapiMba0Target, l_fapiMba1Target);
if (l_err)
{
- // This is an indication that mss_power_cleanup was unable to
- // perform all the cleanup procedures on this centaur.
- // This procedure is designed to stop the clocks / power down
- // non-functional centaurs/mbas, and throws an error if it cannot.
- // It is possible for this to have happened before this step
- // however, in the case of a garded centaur. Therefore
- // we should note but ignore errors from this procedure.
TRACFCOMP(ISTEPS_TRACE::g_trac_isteps_trace,
"mss_power_cleanup HWP failed to perform"
- " cleanup on centaur: 0x%.8X, moving on to next"
- " centaur",
- l_currCentaurHuid);
- // delete error
- delete l_err;
- l_err = NULL;
+ " cleanup on centaur: 0x%.8X HWP_ERROR: 0x%.8X",
+ l_currCentaurHuid,l_err->reasonCode());
+ // Capture the target data in the error log
+ ErrlUserDetailsTarget(l_pCentaur).addToLog(l_err);
+ // Create IStep error log and cross reference error that occurred
+ l_stepError.addErrorDetails(l_err);
+ // Commit error
+ errlCommit(l_err, HWPF_COMP_ID);
}
else
{
// Success
TRACFCOMP(ISTEPS_TRACE::g_trac_isteps_trace,
"Successfully ran mss_power_cleanup HWP on "
- "CENTAUR target HUID %.8X "
- "and associated MBAs",
- l_currCentaurHuid);
+ "Centaur HUID %.8X, MBA0 HUID %.8X, "
+ "MBA1 HUID %.8X, ", l_currCentaurHuid,
+ l_currMBA0Huid, l_currMBA1Huid);
}
}
OpenPOWER on IntegriCloud