Skip to content

Commit

Permalink
Allow child/parent lookups between DIMM and OCMB_CHIP targets
Browse files Browse the repository at this point in the history
Some hwps are trying to use the FAPI interfaces to lookup this
relationship. We can support it so might as well allow it.

Change-Id: I4677fdcabbce9798bf068263a916eedc2ee4eb44
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/72552
Reviewed-by: Matt Derksen <mderkse1@us.ibm.com>
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
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>
Reviewed-by: Corey V. Swenson <cswenson@us.ibm.com>
Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
  • Loading branch information
crgeddes authored and dcrowell77 committed Mar 1, 2019
1 parent 2df1223 commit 8ee01af
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/include/usr/fapi2/target.H
Original file line number Diff line number Diff line change
Expand Up @@ -462,10 +462,12 @@ inline Target<K_PARENT, M, V> Target<T_SELF, M, V>::getParent(void) const
// DIMM -> MCA
// DIMM -> MBA
// DIMM -> MEM_PORT
// DIMM -> OCMB_CHIP
static_assert(!((T_SELF == fapi2::TARGET_TYPE_DIMM) &&
(K_PARENT != fapi2::TARGET_TYPE_MCA) &&
(K_PARENT != fapi2::TARGET_TYPE_MBA) &&
(K_PARENT != fapi2::TARGET_TYPE_MEM_PORT)),
(K_PARENT != fapi2::TARGET_TYPE_MEM_PORT) &&
(K_PARENT != fapi2::TARGET_TYPE_OCMB_CHIP)),
"improper parent of fapi2::TARGET_TYPE_DIMM");

// valid parents for PROC
Expand Down Expand Up @@ -917,8 +919,10 @@ inline std::vector<Target<K_CHILD, M, V> >

// valid children for OCMB
// OCMB -> MEM_PORT
// OCMB -> DIMM
static_assert(!((T_SELF == fapi2::TARGET_TYPE_OCMB_CHIP) &&
(K_CHILD != fapi2::TARGET_TYPE_MEM_PORT)),
(K_CHILD != fapi2::TARGET_TYPE_MEM_PORT) &&
(K_CHILD != fapi2::TARGET_TYPE_DIMM)),
"improper child of fapi2::TARGET_TYPE_OCMB_CHIP");

// valid children for MEM_PORT
Expand Down

0 comments on commit 8ee01af

Please sign in to comment.