Skip to content

Commit

Permalink
PRD: Change MCC to OCMB chip connection lookup
Browse files Browse the repository at this point in the history
Change-Id: I174e9306b4138635a89456f4da1fc6c1f92151c4
CQ: SW486452
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/92820
Reviewed-by: Benjamen G Tyner <ben.tyner@ibm.com>
Reviewed-by: Brian J Stegmiller <bjs@us.ibm.com>
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Reviewed-by: Zane C Shelley <zshelle@us.ibm.com>
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/93122
Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com>
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
  • Loading branch information
cnpalmer authored and zane131 committed Mar 12, 2020
1 parent fffe69a commit c10eba8
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions src/usr/diag/prdf/common/plat/prdfTargetServices.C
Expand Up @@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
/* Contributors Listed Below - COPYRIGHT 2016,2019 */
/* Contributors Listed Below - COPYRIGHT 2016,2020 */
/* [+] International Business Machines Corp. */
/* */
/* */
Expand Down Expand Up @@ -976,14 +976,15 @@ TargetHandle_t getConnectedChild( TargetHandle_t i_target, TYPE i_connType,
}
else if ( TYPE_MCC == trgtType && TYPE_OCMB_CHIP == i_connType )
{
// i_connPos is position relative to MCC (0-1)
itr = std::find_if( list.begin(), list.end(),
[&](const TargetHandle_t & t)
{
uint32_t ocmbPos = getTargetPosition(t);
return (trgtPos == (ocmbPos / MAX_OCMB_PER_MCC)) &&
(i_connPos == (ocmbPos % MAX_OCMB_PER_MCC));
} );
// getTargetPosition for OCMBs will return the position relative to
// the node. This won't work for how we typically handle getting
// the child target, so we instead just get the child OMI and then
// get the OCMB from the OMI. This will work because the OMI and
// OCMB have a 1-to-1 relationship (see above where we return the
// only one in the list for OMI to OCMB connections).
TargetHandle_t omi = getConnectedChild( i_target, TYPE_OMI,
i_connPos );
o_child = getConnectedChild( omi, TYPE_OCMB_CHIP, 0 );
}
else if ( TYPE_MC == trgtType && TYPE_OMIC == i_connType )
{
Expand Down

0 comments on commit c10eba8

Please sign in to comment.