Skip to content

Commit

Permalink
Change target types to 64-bit and add P10 target types
Browse files Browse the repository at this point in the history
This is done in P9 because Cronus requires common
FAPI2 target types for both P9 and P10.

Change-Id: I5641fd2f8fefcb5a36b12a3d214ee57dbc4f887e
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/70142
Tested-by: FSP CI Jenkins <[email protected]>
Tested-by: Jenkins Server <[email protected]>
Tested-by: HWSV CI <[email protected]>
Tested-by: PPE CI <[email protected]>
Tested-by: Hostboot CI <[email protected]>
Reviewed-by: Joseph J. McGill <[email protected]>
Reviewed-by: Matt K. Light <[email protected]>
Reviewed-by: Jennifer A. Stofer <[email protected]>
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/70177
Reviewed-by: Daniel M. Crowell <[email protected]>
  • Loading branch information
ibmthi authored and dcrowell77 committed Feb 5, 2019
1 parent ddae90c commit 9f1d0e3
Show file tree
Hide file tree
Showing 3 changed files with 75 additions and 65 deletions.
132 changes: 71 additions & 61 deletions src/import/hwpf/fapi2/include/target_types.H
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
/* Contributors Listed Below - COPYRIGHT 2015,2018 */
/* Contributors Listed Below - COPYRIGHT 2015,2019 */
/* [+] International Business Machines Corp. */
/* */
/* */
Expand Down Expand Up @@ -47,71 +47,81 @@ namespace fapi2
///

/// Target Kind
enum TargetType
enum TargetType : uint64_t
{
TARGET_TYPE_NONE = 0x00000000, ///< No type
TARGET_TYPE_SYSTEM = 0x00000001, ///< System type
TARGET_TYPE_DIMM = 0x00000002, ///< DIMM type
TARGET_TYPE_PROC_CHIP = 0x00000004, ///< Processor type
TARGET_TYPE_MEMBUF_CHIP = 0x00000008, ///< Membuf type
TARGET_TYPE_EX = 0x00000010, ///< EX - 2x Core, L2, L3 - can be deconfigured
TARGET_TYPE_MBA = 0x00000020, ///< MBA type
TARGET_TYPE_MCS = 0x00000040, ///< MCS type
TARGET_TYPE_XBUS = 0x00000080, ///< XBUS type
TARGET_TYPE_ABUS = 0x00000100, ///< ABUS type
TARGET_TYPE_L4 = 0x00000200, ///< L4 type
TARGET_TYPE_CORE = 0x00000400, ///< Core - 4x threads(?) - can be deconfigured
TARGET_TYPE_EQ = 0x00000800, ///< EQ - 4x core, 2x L2, 2x L3 - can be deconfigured
TARGET_TYPE_MCA = 0x00001000, ///< MCA type
TARGET_TYPE_MCBIST = 0x00002000, ///< MCBIST type
TARGET_TYPE_MI = 0x00004000, ///< MI Memory Interface (Cumulus)
TARGET_TYPE_CAPP = 0x00008000, ///< CAPP target
TARGET_TYPE_DMI = 0x00010000, ///< DMI type
TARGET_TYPE_OBUS = 0x00020000, ///< OBUS type
TARGET_TYPE_OBUS_BRICK = 0x00040000, ///< OBUS BRICK type
TARGET_TYPE_SBE = 0x00080000, ///< SBE type
TARGET_TYPE_PPE = 0x00100000, ///< PPE type
TARGET_TYPE_PERV = 0x00200000, ///< Pervasive type
TARGET_TYPE_PEC = 0x00400000, ///< PEC type
TARGET_TYPE_PHB = 0x00800000, ///< PHB type
TARGET_TYPE_MC = 0x01000000, ///< MC type
TARGET_TYPE_OMI = 0x02000000, ///< OMI type
TARGET_TYPE_OMIC = 0x04000000, ///< OMIC type
TARGET_TYPE_MCC = 0x08000000, ///< MCC type
TARGET_TYPE_OCMB_CHIP = 0x10000000, ///< OCMB type
TARGET_TYPE_MEM_PORT = 0x20000000, ///< MEM_PORT type

TARGET_TYPE_ALL = 0xFFFFFFFF, ///< Any/All types
TARGET_TYPE_NONE = 0x0000000000000000, ///< No type
TARGET_TYPE_SYSTEM = 0x0000000000000001, ///< System type
TARGET_TYPE_DIMM = 0x0000000000000002, ///< DIMM type
TARGET_TYPE_PROC_CHIP = 0x0000000000000004, ///< Processor type
TARGET_TYPE_MEMBUF_CHIP = 0x0000000000000008, ///< Membuf type
TARGET_TYPE_EX = 0x0000000000000010, ///< EX - 2x Core, L2, L3 - can be deconfigured
TARGET_TYPE_MBA = 0x0000000000000020, ///< MBA type
TARGET_TYPE_MCS = 0x0000000000000040, ///< MCS type
TARGET_TYPE_XBUS = 0x0000000000000080, ///< XBUS type
TARGET_TYPE_ABUS = 0x0000000000000100, ///< ABUS type
TARGET_TYPE_L4 = 0x0000000000000200, ///< L4 type
TARGET_TYPE_CORE = 0x0000000000000400, ///< Core
TARGET_TYPE_EQ = 0x0000000000000800, ///< EQ - 4x core, 2x L2, 2x L3 - can be deconfigured
TARGET_TYPE_MCA = 0x0000000000001000, ///< MCA type
TARGET_TYPE_MCBIST = 0x0000000000002000, ///< MCBIST type
TARGET_TYPE_MI = 0x0000000000004000, ///< MI Memory Interface (Cumulus)
TARGET_TYPE_CAPP = 0x0000000000008000, ///< CAPP target
TARGET_TYPE_DMI = 0x0000000000010000, ///< DMI type
TARGET_TYPE_OBUS = 0x0000000000020000, ///< OBUS type
TARGET_TYPE_OBUS_BRICK = 0x0000000000040000, ///< OBUS BRICK type
TARGET_TYPE_SBE = 0x0000000000080000, ///< SBE type
TARGET_TYPE_PPE = 0x0000000000100000, ///< PPE type
TARGET_TYPE_PERV = 0x0000000000200000, ///< Pervasive type
TARGET_TYPE_PEC = 0x0000000000400000, ///< PEC type
TARGET_TYPE_PHB = 0x0000000000800000, ///< PHB type
TARGET_TYPE_MC = 0x0000000001000000, ///< MC type
TARGET_TYPE_OMI = 0x0000000002000000, ///< OMI type
TARGET_TYPE_OMIC = 0x0000000004000000, ///< OMIC type
TARGET_TYPE_MCC = 0x0000000008000000, ///< MCC type
TARGET_TYPE_OCMB_CHIP = 0x0000000010000000, ///< OCMB type
TARGET_TYPE_MEM_PORT = 0x0000000020000000, ///< MEM_PORT type
TARGET_TYPE_NMMU = 0x0000000040000000, ///< NEST MMU type
TARGET_TYPE_RESERVED = 0x0000000080000000, ///< Reserved for Cronus (Z)
TARGET_TYPE_PAU = 0x0000000100000000, ///< PAU type
TARGET_TYPE_IOHS = 0x0000000200000000, ///< IOHS type
TARGET_TYPE_FC = 0x0000000400000000, ///< Fused Core type
TARGET_TYPE_MULTICAST = 0x8000000000000000, ///< MULTICAST type
TARGET_TYPE_ALL = 0x7FFFFFFFFFFFFFFF, ///< Any/All types
TARGET_TYPE_ALL_MC = 0xFFFFFFFFFFFFFFFF, ///< Any/All types + Multicast

// Compound target types
TARGET_TYPE_CHIPS = TARGET_TYPE_PROC_CHIP |
TARGET_TYPE_MEMBUF_CHIP |
TARGET_TYPE_OCMB_CHIP,

TARGET_TYPE_CHIPLETS = TARGET_TYPE_EX |
TARGET_TYPE_MBA |
TARGET_TYPE_MCS |
TARGET_TYPE_XBUS |
TARGET_TYPE_ABUS |
TARGET_TYPE_L4 |
TARGET_TYPE_CORE |
TARGET_TYPE_EQ |
TARGET_TYPE_MCA |
TARGET_TYPE_MCBIST |
TARGET_TYPE_MI |
TARGET_TYPE_DMI |
TARGET_TYPE_OBUS |
TARGET_TYPE_OBUS_BRICK |
TARGET_TYPE_SBE |
TARGET_TYPE_PPE |
TARGET_TYPE_PERV |
TARGET_TYPE_PEC |
TARGET_TYPE_PHB |
TARGET_TYPE_MC |
TARGET_TYPE_OMI |
TARGET_TYPE_OMIC |
TARGET_TYPE_MCC |
TARGET_TYPE_MEM_PORT,
TARGET_TYPE_CHIPLETS = TARGET_TYPE_EX |
TARGET_TYPE_MBA |
TARGET_TYPE_MCS |
TARGET_TYPE_XBUS |
TARGET_TYPE_ABUS |
TARGET_TYPE_L4 |
TARGET_TYPE_CORE |
TARGET_TYPE_EQ |
TARGET_TYPE_MCA |
TARGET_TYPE_MCBIST |
TARGET_TYPE_MI |
TARGET_TYPE_DMI |
TARGET_TYPE_OBUS |
TARGET_TYPE_OBUS_BRICK |
TARGET_TYPE_SBE |
TARGET_TYPE_PPE |
TARGET_TYPE_PERV |
TARGET_TYPE_PEC |
TARGET_TYPE_PHB |
TARGET_TYPE_MC |
TARGET_TYPE_OMI |
TARGET_TYPE_OMIC |
TARGET_TYPE_MCC |
TARGET_TYPE_MEM_PORT |
TARGET_TYPE_NMMU |
TARGET_TYPE_PAU |
TARGET_TYPE_IOHS |
TARGET_TYPE_FC,

// Mappings to target types found in the error xml files
TARGET_TYPE_EX_CHIPLET = TARGET_TYPE_EX,
Expand Down Expand Up @@ -266,8 +276,8 @@ enum TargetFilter : uint64_t
/// @cond
constexpr TargetType operator|(TargetType x, TargetType y)
{
return static_cast<TargetType>(static_cast<int>(x) |
static_cast<int>(y));
return static_cast<TargetType>(static_cast<uint64_t>(x) |
static_cast<uint64_t>(y));
}
#endif

Expand Down
4 changes: 2 additions & 2 deletions src/import/hwpf/fapi2/src/error_info.C
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
/* Contributors Listed Below - COPYRIGHT 2015,2016 */
/* Contributors Listed Below - COPYRIGHT 2015,2019 */
/* [+] International Business Machines Corp. */
/* */
/* */
Expand Down Expand Up @@ -368,7 +368,7 @@ void ErrorInfoEntryChildrenCDG::addErrorInfo(
iv_childNumber);

FAPI_DBG("addErrorInfo: Adding children cdg (%d:%d:%d), type:"
" 0x%08x, pri: %d",
" 0x%16lX, pri: %d",
ei->iv_callout, ei->iv_deconfigure, ei->iv_gard,
ei->iv_childType, ei->iv_calloutPriority);

Expand Down
4 changes: 2 additions & 2 deletions src/import/hwpf/fapi2/src/fapi2_utils.C
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ uint16_t convertSbeTargInstanceToFapiPos(fapi2::TargetType i_targType,
if( max_targets == INVALID_TARGET_COUNT )
{
FAPI_ERR("Unable to determine the target count "
"for target type = 0x%x and instance 0x%d "
"for target type = 0x%.16lX and instance 0x%d "
"associated with proc position %d",
i_targType, i_instance, l_procPosition);
}
Expand All @@ -209,7 +209,7 @@ uint16_t convertSbeTargInstanceToFapiPos(fapi2::TargetType i_targType,
}
}

FAPI_INF("Returning FAPI_POS= %d for target type 0x%x", fapi_pos, i_targType);
FAPI_INF("Returning FAPI_POS= %d for target type 0x%.16lX", fapi_pos, i_targType);

return fapi_pos;
}
Expand Down

0 comments on commit 9f1d0e3

Please sign in to comment.