summaryrefslogtreecommitdiffstats
path: root/src/usr/diag/prdf/plat/mem/prdfMemTdCtlr.C
diff options
context:
space:
mode:
authorZane Shelley <zshelle@us.ibm.com>2016-12-08 16:22:00 -0600
committerZane C. Shelley <zshelle@us.ibm.com>2016-12-09 18:17:41 -0500
commit2c5b46681f73aa4e6b22e6bf4de96c70e4977811 (patch)
treeeb41319c42e1bf0bdb6804056b42f38d93b25df7 /src/usr/diag/prdf/plat/mem/prdfMemTdCtlr.C
parent7791bc24b3d83bcb14572aaba69d8d32f0c917b1 (diff)
downloadtalos-hostboot-2c5b46681f73aa4e6b22e6bf4de96c70e4977811.tar.gz
talos-hostboot-2c5b46681f73aa4e6b22e6bf4de96c70e4977811.zip
PRD: SIMICs workaround for MCBIST commands during MDIA
Change-Id: I808c178f330c02e68e8d290c862522336f1cdd38 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/33639 Reviewed-by: Zane C. Shelley <zshelle@us.ibm.com> Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/33686 Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Diffstat (limited to 'src/usr/diag/prdf/plat/mem/prdfMemTdCtlr.C')
-rw-r--r--src/usr/diag/prdf/plat/mem/prdfMemTdCtlr.C30
1 files changed, 29 insertions, 1 deletions
diff --git a/src/usr/diag/prdf/plat/mem/prdfMemTdCtlr.C b/src/usr/diag/prdf/plat/mem/prdfMemTdCtlr.C
index 156c6d99a..a11b050fd 100644
--- a/src/usr/diag/prdf/plat/mem/prdfMemTdCtlr.C
+++ b/src/usr/diag/prdf/plat/mem/prdfMemTdCtlr.C
@@ -25,10 +25,14 @@
#include <prdfMemTdCtlr.H>
+// Platform includes
#include <prdfMemAddress.H>
#include <prdfMemCaptureData.H>
#include <prdfP9McbistExtraSig.H>
+// External includes
+#include <util/misc.H>
+
using namespace TARGETING;
namespace PRDF
@@ -184,8 +188,32 @@ uint32_t MemTdCtlr<TYPE_MCBIST>::initStoppedRank()
break;
}
+ ExtensibleChip * mcaChip = portList.front();
+ MemRank rank = addr.getRank();
+
+ // ############################ SIMICs only ############################
+ // We have found it to be increasingly difficult to simulate the MCBMCAT
+ // register in SIMICs. We tried copying the address in the MCBEA
+ // registers, but the HWP code will input the last possible address to
+ // the MCBEA registers, but it is likely that this address is not a
+ // configured address. MCBIST commands are tolerant of this, where MBA
+ // maintenance commands are not. Also, there are multiple possible
+ // subtests for MCBIST commands. So it is difficult to determine which
+ // subtest will be the last configured address. To maintain sanity, we
+ // will simply short-circuit the code and ensure we always get the last
+ // configured rank.
+ if ( Util::isSimicsRunning() )
+ {
+ std::vector<MemRank> list;
+ getSlaveRanks<TYPE_MCA>( mcaChip->getTrgt(), list );
+ PRDF_ASSERT( !list.empty() ); // func target with no config ranks
+
+ rank = list.back(); // Get the last configured rank.
+ }
+ // #####################################################################
+
// Update iv_stoppedRank.
- iv_stoppedRank = TdRankListEntry ( portList.front(), addr.getRank() );
+ iv_stoppedRank = TdRankListEntry ( mcaChip, rank );
#ifndef __HOSTBOOT_RUNTIME
// Update iv_broadcastMode.
iv_broadcastMode = ( 1 < portList.size() );
OpenPOWER on IntegriCloud