Skip to content

Commit

Permalink
PRD: abort TPS if chip mark placed during procedure
Browse files Browse the repository at this point in the history
Change-Id: I064e550467e753ddc5cb32191903e903ddadc3ea
CQ: SW433791
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/61003
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Reviewed-by: Brian J. Stegmiller <bjs@us.ibm.com>
Reviewed-by: Benjamin J. Weisenbeck <bweisenb@us.ibm.com>
Reviewed-by: Caleb N. Palmer <cnpalmer@us.ibm.com>
Reviewed-by: Zane C. Shelley <zshelle@us.ibm.com>
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/61037
Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com>
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com>
  • Loading branch information
zane131 committed Jun 22, 2018
1 parent bb794f9 commit 5a927c8
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 6 deletions.
6 changes: 4 additions & 2 deletions src/usr/diag/prdf/plat/mem/prdfMemTps.H
Original file line number Diff line number Diff line change
Expand Up @@ -190,10 +190,12 @@ class TpsEvent : public TdEntry

/**
* @brief Analyzes the maintenance CE statistics.
* @param io_sc The step code data struct.
* @param io_sc The step code data struct.
* @param o_done True if the procedure is complete or has aborted.
* False otherwise.
* @return Non-SUCCESS if an internal function fails, SUCCESS otherwise.
*/
uint32_t analyzeCeStats( STEP_CODE_DATA_STRUCT & io_sc );
uint32_t analyzeCeStats( STEP_CODE_DATA_STRUCT & io_sc, bool & o_done );

/**
* @brief Additional processing if no errors are handled during the
Expand Down
28 changes: 24 additions & 4 deletions src/usr/diag/prdf/plat/mem/prdfMemTps_rt.C
Original file line number Diff line number Diff line change
Expand Up @@ -1048,7 +1048,8 @@ uint32_t TpsEvent<TYPE_MCA>::getSymbolCeCounts( CeCount & io_badDqCount,
//------------------------------------------------------------------------------

template <>
uint32_t TpsEvent<TYPE_MCA>::analyzeCeStats( STEP_CODE_DATA_STRUCT & io_sc )
uint32_t TpsEvent<TYPE_MCA>::analyzeCeStats( STEP_CODE_DATA_STRUCT & io_sc,
bool & o_done )
{
#define PRDF_FUNC "[TpsEvent<TYPE_MCA>::analyzeCeStats] "

Expand Down Expand Up @@ -1134,12 +1135,13 @@ uint32_t TpsEvent<TYPE_MCA>::analyzePhase( STEP_CODE_DATA_STRUCT & io_sc,
if ( o_done ) break;

// Analyze CEs
o_rc = analyzeCeStats( io_sc );
o_rc = analyzeCeStats( io_sc, o_done );
if ( SUCCESS != o_rc )
{
PRDF_ERR( PRDF_FUNC "analyzeCeStats() failed." );
break;
}
if ( o_done ) break;

// At this point, we are done with the procedure.
o_done = true;
Expand Down Expand Up @@ -1331,7 +1333,8 @@ uint32_t TpsEvent<TYPE_MBA>::analyzeEccErrors( const uint32_t & i_eccAttns,
//------------------------------------------------------------------------------

template<>
uint32_t TpsEvent<TYPE_MBA>::analyzeCeStats( STEP_CODE_DATA_STRUCT & io_sc )
uint32_t TpsEvent<TYPE_MBA>::analyzeCeStats( STEP_CODE_DATA_STRUCT & io_sc,
bool & o_done )
{
#define PRDF_FUNC "[TpsEvent::analyzeCeStats] "

Expand Down Expand Up @@ -1483,8 +1486,15 @@ uint32_t TpsEvent<TYPE_MBA>::analyzeCeStats( STEP_CODE_DATA_STRUCT & io_sc )
// If a chip mark was placed add a VCM procedure to the queue.
if ( cmPlaced )
{
io_sc.service_data->AddSignatureList( iv_chip->getTrgt(),
PRDFSIG_TpsChipMark );

TdEntry * e = new VcmEvent<TYPE_MBA> { iv_chip, iv_rank, chipMark };
MemDbUtils::pushToQueue<TYPE_MBA>( iv_chip, e );

// Abort this procedure because the chip mark may have fixed the
// symbol that triggered TPS.
o_done = true; break;
}

// Check if the symbol mark is available. Note that symbol marks are not
Expand All @@ -1496,6 +1506,9 @@ uint32_t TpsEvent<TYPE_MBA>::analyzeCeStats( STEP_CODE_DATA_STRUCT & io_sc )
// mark.
if ( !cmPlaced && !isDramWidthX4(trgt) && !symMark.isValid() )
{
io_sc.service_data->AddSignatureList( iv_chip->getTrgt(),
PRDFSIG_TpsSymbolMark );

// Use the symbol with the highest count.
symMark = MemMark ( trgt, iv_rank, symData.back().symbol );
o_rc = MarkStore::writeSymbolMark<TYPE_MBA>( iv_chip, iv_rank,
Expand Down Expand Up @@ -1646,6 +1659,9 @@ uint32_t TpsEvent<TYPE_MBA>::handleFalseAlarm( STEP_CODE_DATA_STRUCT & io_sc )
// not available in x4 mode.
if ( !isDramWidthX4(iv_chip->getTrgt()) && !symMark.isValid() )
{
io_sc.service_data->AddSignatureList( iv_chip->getTrgt(),
PRDFSIG_TpsSymbolMark );

MemMark sm( iv_chip->getTrgt(), iv_rank, highestSymbol );
o_rc = MarkStore::writeSymbolMark<TYPE_MBA>( iv_chip, iv_rank, sm );
if ( SUCCESS != o_rc )
Expand Down Expand Up @@ -1676,6 +1692,9 @@ uint32_t TpsEvent<TYPE_MBA>::handleFalseAlarm( STEP_CODE_DATA_STRUCT & io_sc )
// Check if the chip mark is available
else if ( !chipMark.isValid() )
{
io_sc.service_data->AddSignatureList( iv_chip->getTrgt(),
PRDFSIG_TpsChipMark );

MemMark cm( iv_chip->getTrgt(), iv_rank, highestSymbol );
o_rc = MarkStore::writeChipMark<TYPE_MBA>( iv_chip, iv_rank, cm );
if ( SUCCESS != o_rc )
Expand Down Expand Up @@ -1760,13 +1779,14 @@ uint32_t TpsEvent<TYPE_MBA>::analyzePhase( STEP_CODE_DATA_STRUCT & io_sc,
((TD_PHASE_2 == iv_phase) && ((eccAttns & MAINT_INT_NCE_ETE) ||
(eccAttns & MAINT_SOFT_NCE_ETE) )) )
{
o_rc = analyzeCeStats( io_sc );
o_rc = analyzeCeStats( io_sc, o_done );
if ( SUCCESS != o_rc )
{
PRDF_ERR( PRDF_FUNC "analyzeCeStats() failed on 0x%08x,0x%02x",
iv_chip->getHuid(), getKey() );
break;
}
if ( o_done ) break; // abort the procedure.
}

// If the command reached the last address, the procedure is complete.
Expand Down

0 comments on commit 5a927c8

Please sign in to comment.