From 245717655c4f0c078f150b64cdb8480ad2bcc39a Mon Sep 17 00:00:00 2001 From: Zane Shelley Date: Wed, 22 Feb 2017 15:49:00 -0600 Subject: [PATCH] PRD: analysis for hard CEs during Memory Diagnostics Change-Id: If00a493bba83ecb9620170da1ace10eb60a04083 RTC: 169935 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/36881 Tested-by: Jenkins Server Reviewed-by: Benjamin J. Weisenbeck Reviewed-by: Caleb N. Palmer Reviewed-by: Zane C. Shelley Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/37049 Tested-by: Jenkins OP Build CI Tested-by: FSP CI Jenkins --- .../diag/prdf/plat/mem/prdfMemTdCtlr_ipl.C | 28 +++++++++++++++---- 1 file changed, 23 insertions(+), 5 deletions(-) diff --git a/src/usr/diag/prdf/plat/mem/prdfMemTdCtlr_ipl.C b/src/usr/diag/prdf/plat/mem/prdfMemTdCtlr_ipl.C index 7a8e57b8333..218752149f9 100644 --- a/src/usr/diag/prdf/plat/mem/prdfMemTdCtlr_ipl.C +++ b/src/usr/diag/prdf/plat/mem/prdfMemTdCtlr_ipl.C @@ -34,6 +34,7 @@ #include #include #include +#include #include #include #include // for Util::hashString @@ -192,11 +193,28 @@ uint32_t __checkEcc( ExtensibleChip * i_chip, const MemRank & i_rank, { io_sc.service_data->AddSignatureList( trgt, PRDFSIG_MaintHARD_CTE ); - // TODO RTC 169935 - // - Query the per-symbol counters for the hard CE symbol (there - // should be only one). - // - Add the symbol to the callout list (via MemoryMru). - // - Add a TPS procedure to the queue. + // Query the per-symbol counters for the hard CE symbol. + MemUtils::MaintSymbols symData; MemSymbol junk; + o_rc = MemUtils::collectCeStats( i_chip, i_rank, symData, junk ); + if ( SUCCESS != o_rc ) + { + PRDF_ERR( PRDF_FUNC "MemUtils::collectCeStats(0x%08x,m%ds%d) " + "failed", i_chip->GetId(), i_rank.getMaster(), + i_rank.getSlave() ); + break; + } + + // The command will have finished at the end of the rank so there + // may be more than one symbol. Add all to the callout list. + for ( auto & s : symData ) + { + MemoryMru memmru ( trgt, i_rank, s.symbol ); + io_sc.service_data->SetCallout( memmru ); + } + + // Add a TPS procedure to the queue. + TdEntry * e = new TpsEvent{ i_chip, i_rank }; + io_queue.push( e ); } else // Nothing found. {