diff options
author | Matt Raybuck <mraybuc@us.ibm.com> | 2019-01-15 15:34:25 -0600 |
---|---|---|
committer | Daniel M. Crowell <dcrowell@us.ibm.com> | 2019-01-23 11:56:30 -0600 |
commit | 443a53ba177180a883d4090d174f709e29590721 (patch) | |
tree | b6eee32e29090c4f8dc40ec2c394747297b3fad6 /src/usr/hwas/common/deconfigGard.C | |
parent | 720ee62acd978101afa34b99c46a00dda73ef8c1 (diff) | |
download | talos-hostboot-443a53ba177180a883d4090d174f709e29590721.tar.gz talos-hostboot-443a53ba177180a883d4090d174f709e29590721.zip |
deconfigByAssoc updates for Axone and OMCB
Updates the deconfigByAssoc functions to use the special OMIC_PARENT and
OMI_CHILD relations when dealing with target hierarchy since OMIs have
two parents.
Change-Id: Ibc512777982e24de21ab7878d816a72fab1b19f7
RTC:196804
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/70510
Reviewed-by: Nicholas E. Bofferding <bofferdn@us.ibm.com>
Reviewed-by: Ilya Smirnov <ismirno@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: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com>
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Diffstat (limited to 'src/usr/hwas/common/deconfigGard.C')
-rw-r--r-- | src/usr/hwas/common/deconfigGard.C | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/src/usr/hwas/common/deconfigGard.C b/src/usr/hwas/common/deconfigGard.C index 4dc158dbc..2a2ea1d54 100644 --- a/src/usr/hwas/common/deconfigGard.C +++ b/src/usr/hwas/common/deconfigGard.C @@ -39,6 +39,7 @@ #include <targeting/common/commontargeting.H> #include <targeting/common/utilFilter.H> +#include <targeting/common/targetservice.H> #ifdef __HOSTBOOT_MODULE #include <config.h> @@ -1611,6 +1612,7 @@ void DeconfigGard::_deconfigAffinityParent( TARGETING::Target & i_child, PredicateIsFunctional isFunctional; l_parent = getImmediateParentByAffinity(&i_child); + if ((l_parent != NULL) && isFunctional(l_parent)) { // Now check if parent has any functional affinity children @@ -1690,6 +1692,17 @@ void DeconfigGard::_deconfigureByAssoc( // find all CHILD targets and deconfigure them targetService().getAssociated(pChildList, &i_target, TargetService::CHILD, TargetService::ALL, &funcOrFco); + + // Since OMICs and OMIs share special relations OMI_CHILD and OMIC_PARENT, + // they will only show up if those relations are used and not the regular + // CHILD and PARENT relations. + if (i_target.getAttr<ATTR_TYPE>() == TYPE_OMIC) + { + // Append OMI targets to the child list. + getChildOmiTargetsByState(pChildList, &i_target, CLASS_NA, + TYPE_OMI, UTIL_FILTER_FUNCTIONAL); + } + for (TargetHandleList::iterator pChild_it = pChildList.begin(); pChild_it != pChildList.end(); ++pChild_it) @@ -2026,6 +2039,26 @@ void DeconfigGard::_deconfigParentAssoc(TARGETING::Target & i_target, break; } // TYPE_SMPGROUP + case TYPE_OMI: + { + TargetHandleList pOmicParentList; + getParentOmicTargetsByState(pOmicParentList, + &i_target, CLASS_NA, TYPE_OMIC, + UTIL_FILTER_ALL); + + TargetHandle_t parentOmic = pOmicParentList[0]; + + HWAS_ASSERT((pOmicParentList.size() == 1), + "HWAS _deconfigParentAssoc: pOmicParentList != 1"); + + if (!anyChildFunctional(*parentOmic, TargetService::OMI_CHILD)) + { + _deconfigureTarget(*parentOmic, i_errlEid, NULL, + i_deconfigRule); + } + + break; + } default: { // TYPE_MEMBUF, TYPE_MCA, TYPE_MCS, TYPE_MI, TYPE_DMI, |