summaryrefslogtreecommitdiffstats
path: root/src/usr/diag
diff options
context:
space:
mode:
authorZane Shelley <zshelle@us.ibm.com>2016-05-04 14:28:17 -0500
committerDaniel M. Crowell <dcrowell@us.ibm.com>2016-05-25 15:02:00 -0400
commitbf7b293e9f2e115ffc9a606c5901ae611f25d29a (patch)
tree83c18dcd27379a1dbe546db655bfbbf168fb94ba /src/usr/diag
parent4212226b4f7c8fc8a628d1064625f787459241da (diff)
downloadblackbird-hostboot-bf7b293e9f2e115ffc9a606c5901ae611f25d29a.tar.gz
blackbird-hostboot-bf7b293e9f2e115ffc9a606c5901ae611f25d29a.zip
PRD: removed obsolete getNodePosition and printTargetInfo
Change-Id: I4c506c8171afd98149f7ec59364335cc23d631a6 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/24285 Tested-by: Jenkins Server Reviewed-by: Caleb N. Palmer <cnpalmer@us.ibm.com> Reviewed-by: Benjamin J. Weisenbeck <bweisenb@us.ibm.com> Reviewed-by: William G. Hoffa <wghoffa@us.ibm.com> Reviewed-by: Zane C. Shelley <zshelle@us.ibm.com> Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/24997 Tested-by: FSP CI Jenkins Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Diffstat (limited to 'src/usr/diag')
-rwxr-xr-xsrc/usr/diag/prdf/common/plat/p9/prdfP9Configurator.C19
-rwxr-xr-xsrc/usr/diag/prdf/common/plat/prdfTargetServices.C60
-rwxr-xr-xsrc/usr/diag/prdf/common/plat/prdfTargetServices.H14
3 files changed, 18 insertions, 75 deletions
diff --git a/src/usr/diag/prdf/common/plat/p9/prdfP9Configurator.C b/src/usr/diag/prdf/common/plat/p9/prdfP9Configurator.C
index 6fefc4742..9e28f7a00 100755
--- a/src/usr/diag/prdf/common/plat/p9/prdfP9Configurator.C
+++ b/src/usr/diag/prdf/common/plat/p9/prdfP9Configurator.C
@@ -315,23 +315,28 @@ void PlatConfigurator::addChipToPllDomain( DOMAIN_ID i_domainId,
ScanFacility & i_scanFac,
ResolutionFactory & i_resFac )
{
- // PROC PLL - only one per node as all fabs on node have same clock source.
- uint32_t node = getNodePosition( i_trgt );
-
- if ( io_pllDmnMap.end() == io_pllDmnMap.find(node) )
+ // TODO: RTC 136052 - The position used here should be based on clock
+ // domains. In the past there happened to be one clock source for each
+ // node. In which case, we just used the node position. Unfortunately,
+ // that is not very maintainable code. Instead, we should be querying
+ // clock domain attributes so that this code does not need to be
+ // modified if the clock domains change.
+ uint32_t pos = 0;
+
+ if ( io_pllDmnMap.end() == io_pllDmnMap.find(pos) )
{
Resolution & clock = i_resFac.GetClockResolution( i_trgt, i_type );
#ifdef __HOSTBOOT_MODULE
- io_pllDmnMap[node] = new PllDomain( i_domainId, clock,
+ io_pllDmnMap[pos] = new PllDomain( i_domainId, clock,
ThresholdResolution::cv_mnfgDefault );
#else
- io_pllDmnMap[node] = new PllDomain( i_domainId, clock, CONTENT_HW,
+ io_pllDmnMap[pos] = new PllDomain( i_domainId, clock, CONTENT_HW,
ThresholdResolution::cv_mnfgDefault );
#endif
}
- io_pllDmnMap[node]->AddChip( i_chip );
+ io_pllDmnMap[pos]->AddChip( i_chip );
}
//------------------------------------------------------------------------------
diff --git a/src/usr/diag/prdf/common/plat/prdfTargetServices.C b/src/usr/diag/prdf/common/plat/prdfTargetServices.C
index 6c4d61353..57e2d5e19 100755
--- a/src/usr/diag/prdf/common/plat/prdfTargetServices.C
+++ b/src/usr/diag/prdf/common/plat/prdfTargetServices.C
@@ -332,24 +332,6 @@ TARGETING::CLASS getTargetClass( TARGETING::TargetHandle_t i_target )
//------------------------------------------------------------------------------
-void printTargetInfo( TARGETING::TargetHandle_t i_target )
-{
- EntityPath l_path ( EntityPath::PATH_PHYSICAL );
- int32_t l_rc = getEntityPath( i_target, l_path );
- if ( SUCCESS == l_rc )
- {
- PRDF_DTRAC( "PRDCONFIG: HUID=0x%08x path=", getHuid(i_target) );
- l_path.dump();
- }
- else
- {
- PRDF_ERR( "[printTargetInfo] Failed: i_target=0x%08x",
- getHuid(i_target) );
- }
-}
-
-//------------------------------------------------------------------------------
-
uint8_t getChipLevel( TARGETING::TargetHandle_t i_target )
{
uint8_t o_chipLvl = 0;
@@ -1024,8 +1006,13 @@ uint32_t getTargetPosition( TARGETING::TargetHandle_t i_target )
}
case CLASS_ENC:
- o_pos = getNodePosition( i_target );
+ {
+ if ( !i_target->tryGetAttr<ATTR_ORDINAL_ID>(o_pos) )
+ {
+ PRDF_ERR( PRDF_FUNC "Failed to get ATTR_ORDINAL_ID" );
+ }
break;
+ }
default:
PRDF_ERR( PRDF_FUNC "Unsupported class: %d", l_class );
@@ -1043,41 +1030,6 @@ uint32_t getTargetPosition( TARGETING::TargetHandle_t i_target )
//------------------------------------------------------------------------------
-uint32_t getNodePosition( TARGETING::TargetHandle_t i_target )
-{
- uint32_t o_pos = INVALID_POSITION_BOUND;
-
- do
- {
- // Get the node handle.
- TargetHandle_t node = getConnectedParent( i_target, TYPE_NODE );
- if ( NULL == node )
- {
- PRDF_ERR( "[getNodePosition] Failed to get node target" );
- break;
- }
-
- // FIXME: RTC 120711 will add NODE POSITION keyword
- // that we can use instead of ePath instance.
- EntityPath l_path ( EntityPath::PATH_PHYSICAL );
- int32_t l_rc = getEntityPath( node, l_path );
- if ( SUCCESS != l_rc ) break;
-
- o_pos = l_path[l_path.size()-1].instance;
-
- } while (0);
-
- if ( INVALID_POSITION_BOUND == o_pos )
- {
- PRDF_ERR( "[getNodePosition] Failed: target=0x%08x",
- getHuid(i_target) );
- }
-
- return o_pos;
-}
-
-//------------------------------------------------------------------------------
-
TARGETING::MODEL getProcModel( TARGETING::TargetHandle_t i_proc )
{
#define PRDF_FUNC "[PlatServices::getProcModel] "
diff --git a/src/usr/diag/prdf/common/plat/prdfTargetServices.H b/src/usr/diag/prdf/common/plat/prdfTargetServices.H
index 1431eb9c0..d208c39ca 100755
--- a/src/usr/diag/prdf/common/plat/prdfTargetServices.H
+++ b/src/usr/diag/prdf/common/plat/prdfTargetServices.H
@@ -136,12 +136,6 @@ TARGETING::TYPE getTargetType( TARGETING::TargetHandle_t i_target );
TARGETING::CLASS getTargetClass( TARGETING::TargetHandle_t i_target );
/**
- * @brief Prints the HUID and dumps the entity path of the given target.
- * @param i_target Any target.
- */
-void printTargetInfo( TARGETING::TargetHandle_t i_target );
-
-/**
* @brief Get the chip level (DD level) of this target.
* @param i_target Any chip or unit target.
* @return The chip level or 0 function failed.
@@ -266,14 +260,6 @@ TARGETING::TargetHandle_t getMasterProc();
uint32_t getTargetPosition( TARGETING::TargetHandle_t i_target );
/**
- * @brief Returns the position of a node in which the given target is
- * contained.
- * @param i_target Any target.
- * @return The position of the connected node.
- */
-uint32_t getNodePosition( TARGETING::TargetHandle_t i_target );
-
-/**
* @brief Returns Model associated with Proc.
* Model expected is either MURANO or VENICE or NAPLES.
* @param i_proc a proc target
OpenPOWER on IntegriCloud