summaryrefslogtreecommitdiffstats
path: root/src/usr/hwpf/fapi/fapiTarget.C
diff options
context:
space:
mode:
authorMike Jones <mjjones@us.ibm.com>2014-02-25 11:31:25 -0600
committerA. Patrick Williams III <iawillia@us.ibm.com>2014-02-27 14:20:37 -0600
commit0c77c1149543e775fe0168e9e99947a33d16f6d3 (patch)
tree344b8f9d969db69c3b6fd660286df263b41365bc /src/usr/hwpf/fapi/fapiTarget.C
parentcfb19f068394a358ce21fa3976d0aca834bb3030 (diff)
downloadtalos-hostboot-0c77c1149543e775fe0168e9e99947a33d16f6d3.tar.gz
talos-hostboot-0c77c1149543e775fe0168e9e99947a33d16f6d3.zip
Extend FAPI Error XML to callout specific children by affinity and containment
Change-Id: Iedad86021ba4773b6cc0584dc2983b13b2b0af37 RTC: 98365 Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/9141 Reviewed-by: STEPHEN M. CPREK <smcprek@us.ibm.com> Reviewed-by: William H. Schwartz <whs@us.ibm.com> Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
Diffstat (limited to 'src/usr/hwpf/fapi/fapiTarget.C')
-rw-r--r--src/usr/hwpf/fapi/fapiTarget.C56
1 files changed, 44 insertions, 12 deletions
diff --git a/src/usr/hwpf/fapi/fapiTarget.C b/src/usr/hwpf/fapi/fapiTarget.C
index 057267477..006e2fb36 100644
--- a/src/usr/hwpf/fapi/fapiTarget.C
+++ b/src/usr/hwpf/fapi/fapiTarget.C
@@ -20,7 +20,7 @@
/* Origin: 30 */
/* */
/* IBM_PROLOG_END_TAG */
-// $Id: fapiTarget.C,v 1.9 2013/10/15 13:13:42 dcrowell Exp $
+// $Id: fapiTarget.C,v 1.10 2014/02/26 14:51:07 mjjones Exp $
// $Source: /afs/awd/projects/eclipz/KnowledgeBase/.cvsroot/eclipz/hwpf/working/fapi/fapiTarget.C,v $
/**
@@ -40,6 +40,8 @@
* Add XBUS_ENDPOINT ABUS_ENDPOINT
* mjjones 02/21/2012 Add high performance toEcmdString
* mjjones 07/11/2012 Clear iv_pEcmdString on set
+ * mjjones 02/24/2014 Add isChip/Chiplet using types
+ * Add isPhysParentChild
*/
#include <fapiTarget.H>
@@ -136,24 +138,54 @@ void Target::set(void * i_pHandle)
}
//******************************************************************************
-// Is the target a chip?
+// Is a target type a chip?
//******************************************************************************
-bool Target::isChip() const
+bool Target::isChip(const TargetType i_type)
{
- return ((iv_type & (TARGET_TYPE_PROC_CHIP | TARGET_TYPE_MEMBUF_CHIP)) != 0);
+ return ((i_type & (TARGET_TYPE_PROC_CHIP | TARGET_TYPE_MEMBUF_CHIP)) != 0);
}
//******************************************************************************
-// Is the target a chiplet?
+// Is a target type a chiplet?
//******************************************************************************
-bool Target::isChiplet() const
+bool Target::isChiplet(const TargetType i_type)
{
- return ((iv_type & (TARGET_TYPE_EX_CHIPLET |
- TARGET_TYPE_MBA_CHIPLET |
- TARGET_TYPE_MCS_CHIPLET |
- TARGET_TYPE_XBUS_ENDPOINT |
- TARGET_TYPE_ABUS_ENDPOINT |
- TARGET_TYPE_L4 )) != 0);
+ return ((i_type & (TARGET_TYPE_EX_CHIPLET |
+ TARGET_TYPE_MBA_CHIPLET |
+ TARGET_TYPE_MCS_CHIPLET |
+ TARGET_TYPE_XBUS_ENDPOINT |
+ TARGET_TYPE_ABUS_ENDPOINT |
+ TARGET_TYPE_L4 )) != 0);
+}
+
+//******************************************************************************
+// Is a target type pair a physical parent/child?
+//******************************************************************************
+bool Target::isPhysParentChild(const TargetType i_parentType,
+ const TargetType i_childType)
+{
+ bool l_result = false;
+
+ if (i_parentType == TARGET_TYPE_PROC_CHIP)
+ {
+ if ((i_childType == TARGET_TYPE_EX_CHIPLET) ||
+ (i_childType == TARGET_TYPE_MCS_CHIPLET) ||
+ (i_childType == TARGET_TYPE_XBUS_ENDPOINT) ||
+ (i_childType == TARGET_TYPE_ABUS_ENDPOINT))
+ {
+ l_result = true;
+ }
+ }
+ else if (i_parentType == TARGET_TYPE_MEMBUF_CHIP)
+ {
+ if ((i_childType == TARGET_TYPE_MBA_CHIPLET) ||
+ (i_childType == TARGET_TYPE_L4))
+ {
+ l_result = true;
+ }
+ }
+
+ return l_result;
}
}
OpenPOWER on IntegriCloud