summaryrefslogtreecommitdiffstats
path: root/src/usr/scom/test
diff options
context:
space:
mode:
authorDoug Gilbert <dgilbert@us.ibm.com>2014-03-21 17:05:40 -0500
committerA. Patrick Williams III <iawillia@us.ibm.com>2014-04-03 17:36:47 -0500
commit9d4827735558fe03ee021afb7dacfa6ac76719bb (patch)
treeef528a55914ce8dc17b0b83f94fc1037b525b6d5 /src/usr/scom/test
parent2cdeb532a7d25232ae2f498aa122635374ae6fb6 (diff)
downloadtalos-hostboot-9d4827735558fe03ee021afb7dacfa6ac76719bb.tar.gz
talos-hostboot-9d4827735558fe03ee021afb7dacfa6ac76719bb.zip
HW279456 code workaround for MBSECCQ - HB
Change-Id: Ieb10dbe271c9b0414b3147c809bc3a1a3ab2bf72 RTC: 97286 CQ: SW253664 Backport: release-fips810 Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/9843 Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
Diffstat (limited to 'src/usr/scom/test')
-rw-r--r--src/usr/scom/test/scomtest.H56
1 files changed, 55 insertions, 1 deletions
diff --git a/src/usr/scom/test/scomtest.H b/src/usr/scom/test/scomtest.H
index cb28829bc..2e8bebf99 100644
--- a/src/usr/scom/test/scomtest.H
+++ b/src/usr/scom/test/scomtest.H
@@ -5,7 +5,7 @@
/* */
/* IBM CONFIDENTIAL */
/* */
-/* COPYRIGHT International Business Machines Corp. 2011,2013 */
+/* COPYRIGHT International Business Machines Corp. 2011,2014 */
/* */
/* p1 */
/* */
@@ -35,6 +35,7 @@
#include <devicefw/userif.H>
#include <fsi/fsiif.H>
#include <targeting/common/util.H>
+#include <targeting/common/utilFilter.H>
#include <devicefw/driverif.H>
@@ -1813,6 +1814,59 @@ public:
}
+ /**
+ * Test MBSECCQ bit 16 fix
+ * Bit 16 should be on if ATTR_CENTAUR_EC_ENABLE_RCE_WITH_OTHER_ERRORS set
+ */
+ void test_MBSECCQ(void)
+ {
+ errlHndl_t l_err = NULL;
+
+ // get an existing membuf
+ TARGETING::TargetHandleList targetList;
+ getAllChips(targetList,TARGETING::TYPE_MEMBUF);
+ if(targetList.size())
+ {
+ TARGETING::Target * mbuf = targetList[0];
+ uint8_t enabled = 0;
+
+ // @todo RTC 101877
+ //FAPI_ATTR_GET
+ // (ATTR_CENTAUR_EC_ENABLE_RCE_WITH_OTHER_ERRORS_HW246685,
+ // mbuf,
+ // enabled);
+ // Fow now use this:
+ if(mbuf->getAttr<TARGETING::ATTR_EC>() >= 0x20)
+ {
+ enabled = true;
+ }
+
+ if(enabled)
+ {
+ TRACFCOMP(g_trac_scom,"MBSECCQ test run");
+ uint64_t data = 0;
+ size_t op_size = sizeof(uint64_t);
+
+ l_err = deviceOp(DeviceFW::READ,
+ mbuf,
+ &data,
+ op_size,
+ DEVICE_SCOM_ADDRESS(0x0201144a));
+
+ if(l_err)
+ {
+ TS_FAIL("test_MBSECCQ: unexpected error log");
+ errlCommit(l_err,SCOM_COMP_ID);
+ }
+
+ if( (data & 0x0000800000000000ull) == 0 )
+ {
+ TS_FAIL("test_MBSECCQ: Bit 16 is not set");
+ }
+ }
+ }
+ }
+
};
OpenPOWER on IntegriCloud