summaryrefslogtreecommitdiffstats
path: root/src/usr/hwpf
diff options
context:
space:
mode:
authorVan Lee <vanlee@us.ibm.com>2012-09-20 13:23:13 -0500
committerA. Patrick Williams III <iawillia@us.ibm.com>2012-09-24 11:38:24 -0500
commit6da9817c7cec959bf7ba009533c27decb327a510 (patch)
treee2dec4ba9356a9dd3bf2db3ebf98e3f38e50b86c /src/usr/hwpf
parent877dde22ef9f491c096f22bd3a918ecb083b5a75 (diff)
downloadblackbird-hostboot-6da9817c7cec959bf7ba009533c27decb327a510.tar.gz
blackbird-hostboot-6da9817c7cec959bf7ba009533c27decb327a510.zip
Set up POSITION attribute for DIMM targets
Change-Id: I7633b8c624c54cb447910a3a58212901e650ae3a Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/1843 Tested-by: Jenkins Server Reviewed-by: Terry J. Opie <opiet@us.ibm.com> Reviewed-by: Brian H. Horton <brianh@linux.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
Diffstat (limited to 'src/usr/hwpf')
-rwxr-xr-xsrc/usr/hwpf/hwp/fapiTestHwpAttr.C78
1 files changed, 55 insertions, 23 deletions
diff --git a/src/usr/hwpf/hwp/fapiTestHwpAttr.C b/src/usr/hwpf/hwp/fapiTestHwpAttr.C
index 021502f39..362b0bc7b 100755
--- a/src/usr/hwpf/hwp/fapiTestHwpAttr.C
+++ b/src/usr/hwpf/hwp/fapiTestHwpAttr.C
@@ -1,26 +1,25 @@
-/* IBM_PROLOG_BEGIN_TAG
- * This is an automatically generated prolog.
- *
- * $Source: src/usr/hwpf/hwp/fapiTestHwpAttr.C $
- *
- * IBM CONFIDENTIAL
- *
- * COPYRIGHT International Business Machines Corp. 2011-2012
- *
- * p1
- *
- * Object Code Only (OCO) source materials
- * Licensed Internal Code Source Materials
- * IBM HostBoot Licensed Internal Code
- *
- * The source code for this program is not published or other-
- * wise divested of its trade secrets, irrespective of what has
- * been deposited with the U.S. Copyright Office.
- *
- * Origin: 30
- *
- * IBM_PROLOG_END_TAG
- */
+/* IBM_PROLOG_BEGIN_TAG */
+/* This is an automatically generated prolog. */
+/* */
+/* $Source: src/usr/hwpf/hwp/fapiTestHwpAttr.C $ */
+/* */
+/* IBM CONFIDENTIAL */
+/* */
+/* COPYRIGHT International Business Machines Corp. 2011,2012 */
+/* */
+/* p1 */
+/* */
+/* Object Code Only (OCO) source materials */
+/* Licensed Internal Code Source Materials */
+/* IBM HostBoot Licensed Internal Code */
+/* */
+/* The source code for this program is not published or otherwise */
+/* divested of its trade secrets, irrespective of what has been */
+/* deposited with the U.S. Copyright Office. */
+/* */
+/* Origin: 30 */
+/* */
+/* IBM_PROLOG_END_TAG */
/**
* @file fapiTestHwpAttr.C
*
@@ -46,7 +45,9 @@
*/
#include <fapiTestHwpAttr.H>
+#include <targeting/common/target.H>
#include <targeting/common/commontargeting.H>
+#include <targeting/common/utilFilter.H>
extern "C"
{
@@ -65,6 +66,37 @@ fapi::ReturnCode hwpTestAttributes()
// Test ATTR_MSS_DIMM_MFG_ID_CODE
//----------------------------------------------------------------------
{
+ uint32_t l_data;
+ TARGETING::TargetHandleList l_dimmList;
+ getAllLogicalCards( l_dimmList, TARGETING::TYPE_DIMM );
+
+ for( size_t i = 0; i < l_dimmList.size(); i++)
+ {
+ fapi::Target l_target( fapi::TARGET_TYPE_DIMM,
+ (void *)(l_dimmList[i]) );
+ l_rc = FAPI_ATTR_GET(ATTR_POS, &l_target, l_data);
+
+ if (l_rc)
+ {
+ FAPI_ERR("hwpTestAttributes: ATTR_POS. Error from GET");
+ break;
+ }
+ else
+ {
+ FAPI_INF("hwpTestAttributes: ATTR_POS = %d", l_data);
+ }
+ }
+
+ if (l_rc)
+ {
+ break;
+ }
+ }
+
+ //----------------------------------------------------------------------
+ // Test ATTR_MSS_DIMM_MFG_ID_CODE
+ //----------------------------------------------------------------------
+ {
uint32_t l_data[2][2];
TARGETING::PredicateCTM l_pred(TARGETING::CLASS_UNIT, TARGETING::TYPE_MBA);
OpenPOWER on IntegriCloud