diff options
Diffstat (limited to 'src/import/hwpf/fapi2/include/fapi2_target.H')
| -rw-r--r-- | src/import/hwpf/fapi2/include/fapi2_target.H | 69 |
1 files changed, 41 insertions, 28 deletions
diff --git a/src/import/hwpf/fapi2/include/fapi2_target.H b/src/import/hwpf/fapi2/include/fapi2_target.H index ce0e950cc..b479fca77 100644 --- a/src/import/hwpf/fapi2/include/fapi2_target.H +++ b/src/import/hwpf/fapi2/include/fapi2_target.H @@ -1,31 +1,7 @@ -/* IBM_PROLOG_BEGIN_TAG */ -/* This is an automatically generated prolog. */ -/* */ -/* $Source: $ */ -/* */ -/* OpenPOWER HostBoot Project */ -/* */ -/* Contributors Listed Below - COPYRIGHT 2012,2014 */ -/* [+] International Business Machines Corp. */ -/* */ -/* */ -/* Licensed under the Apache License, Version 2.0 (the "License"); */ -/* you may not use this file except in compliance with the License. */ -/* You may obtain a copy of the License at */ -/* */ -/* http://www.apache.org/licenses/LICENSE-2.0 */ -/* */ -/* Unless required by applicable law or agreed to in writing, software */ -/* distributed under the License is distributed on an "AS IS" BASIS, */ -/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or */ -/* implied. See the License for the specific language governing */ -/* permissions and limitations under the License. */ -/* */ -/* IBM_PROLOG_END_TAG */ -/** - * @file fapi2_target.H - * @brief common definitions for fapi2 targets - */ +/// +/// @file fapi2_target.H +/// @brief Common definitions for fapi2 targets +/// #ifndef __FAPI2_COMMON_TARGET__ #define __FAPI2_COMMON_TARGET__ @@ -173,6 +149,43 @@ namespace fapi2 inline Target<T> getParent(void) const; /// + /// @brief Is this target a chip? + /// @return Return true if this target is a chip, false otherwise + /// + inline constexpr bool isChip(void) const + { + return ( (K == TARGET_TYPE_PROC_CHIP) || + (K == TARGET_TYPE_MEMBUF_CHIP) ); + } + + /// + /// @brief Is this target a chiplet? + /// @return Return true if this target is a chiplet, false otherwise + /// + inline constexpr bool isChiplet(void) const + { + return ( (K == TARGET_TYPE_EX) || + (K == TARGET_TYPE_MBA) || + (K == TARGET_TYPE_MCS) || + (K == TARGET_TYPE_XBUS) || + (K == TARGET_TYPE_ABUS) || + (K == TARGET_TYPE_L4) || + (K == TARGET_TYPE_CORE) || + (K == TARGET_TYPE_EQ) || + (K == TARGET_TYPE_MCA) || + (K == TARGET_TYPE_MCBIST) || + (K == TARGET_TYPE_MI) || + (K == TARGET_TYPE_DMI) || + (K == TARGET_TYPE_OBUS) || + (K == TARGET_TYPE_NV) || + (K == TARGET_TYPE_SBE) || + (K == TARGET_TYPE_PPE) || + (K == TARGET_TYPE_PERV) || + (K == TARGET_TYPE_PEC) || + (K == TARGET_TYPE_PHB) ); + } + + /// /// @brief Get this target's children /// @tparam T The type of the parent /// @param[in] i_state The desired TargetState of the children |

