summaryrefslogtreecommitdiffstats
path: root/src/usr/hwas
diff options
context:
space:
mode:
Diffstat (limited to 'src/usr/hwas')
-rw-r--r--src/usr/hwas/common/hwas.C10
-rw-r--r--src/usr/hwas/hwasPlat.C29
-rw-r--r--src/usr/hwas/makefile3
3 files changed, 36 insertions, 6 deletions
diff --git a/src/usr/hwas/common/hwas.C b/src/usr/hwas/common/hwas.C
index d8530ad98..2cb7e9491 100644
--- a/src/usr/hwas/common/hwas.C
+++ b/src/usr/hwas/common/hwas.C
@@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
-/* Contributors Listed Below - COPYRIGHT 2012,2018 */
+/* Contributors Listed Below - COPYRIGHT 2012,2019 */
/* [+] Google Inc. */
/* [+] International Business Machines Corp. */
/* */
@@ -701,9 +701,12 @@ errlHndl_t discoverTargets()
PredicateCTM predChip(CLASS_CHIP);
PredicateCTM predDimm(CLASS_LOGICAL_CARD, TYPE_DIMM);
PredicateCTM predMcs(CLASS_UNIT, TYPE_MCS);
+ // We can ignore chips of TYPE_I2C_MUX because they
+ // were already detected above in discoverMuxTargetsAndEnable
+ PredicateCTM predMux(CLASS_CHIP, TYPE_I2C_MUX);
PredicatePostfixExpr checkExpr;
checkExpr.push(&predChip).push(&predDimm).Or().push(&predEnc).Or().
- push(&predMcs).Or();
+ push(&predMcs).Or().push(&predMux).Not().And();
TargetHandleList pCheckPres;
targetService().getAssociated( pCheckPres, pSys,
@@ -764,8 +767,7 @@ errlHndl_t discoverTargets()
if( (pTarget->getAttr<ATTR_CLASS>() == CLASS_CHIP) &&
(l_targetType != TYPE_TPM) &&
(l_targetType != TYPE_SP) &&
- (l_targetType != TYPE_BMC) &&
- (l_targetType != TYPE_I2C_MUX) )
+ (l_targetType != TYPE_BMC) )
{
// read Chip ID/EC data from these physical chips
errl = platReadIDEC(pTarget);
diff --git a/src/usr/hwas/hwasPlat.C b/src/usr/hwas/hwasPlat.C
index cf436b869..35e9588e0 100644
--- a/src/usr/hwas/hwasPlat.C
+++ b/src/usr/hwas/hwasPlat.C
@@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
-/* Contributors Listed Below - COPYRIGHT 2012,2018 */
+/* Contributors Listed Below - COPYRIGHT 2012,2019 */
/* [+] Google Inc. */
/* [+] International Business Machines Corp. */
/* */
@@ -49,6 +49,8 @@
#include <config.h>
#include <targeting/common/targetservice.H>
+#include <chipids.H>
+
namespace HWAS
{
@@ -227,6 +229,31 @@ DEVICE_REGISTER_ROUTE(DeviceFW::WRITE,
TARGETING::TYPE_MEMBUF,
cfamIDEC);
+errlHndl_t ocmbIDEC(DeviceFW::OperationType i_opType,
+ TARGETING::Target* i_target,
+ void* io_buffer,
+ size_t& io_buflen,
+ int64_t i_accessType,
+ va_list i_args)
+{
+ // for now just hardcode the answer to something explicitly invalid
+ uint8_t l_ec = INVALID__ATTR_EC;
+ i_target->setAttr<TARGETING::ATTR_EC>(l_ec);
+ i_target->setAttr<TARGETING::ATTR_HDAT_EC>(l_ec);
+
+ // we can assume this is an Explorer chip though
+ uint32_t l_id = POWER_CHIPID::EXPLORER_16;
+ i_target->setAttr<TARGETING::ATTR_CHIP_ID>(l_id);
+
+ return nullptr;
+}
+
+// Register the presence detect function with the device framework
+DEVICE_REGISTER_ROUTE(DeviceFW::WRITE,
+ DeviceFW::IDEC,
+ TARGETING::TYPE_OCMB_CHIP,
+ ocmbIDEC);
+
//******************************************************************************
// platIsMinHwCheckingAllowed function
// Description: This function will return false always because when Hostboot
diff --git a/src/usr/hwas/makefile b/src/usr/hwas/makefile
index 3d9589578..625a9f677 100644
--- a/src/usr/hwas/makefile
+++ b/src/usr/hwas/makefile
@@ -5,7 +5,7 @@
#
# OpenPOWER HostBoot Project
#
-# Contributors Listed Below - COPYRIGHT 2011,2018
+# Contributors Listed Below - COPYRIGHT 2011,2019
# [+] International Business Machines Corp.
#
#
@@ -36,6 +36,7 @@ EXTRAINCDIR += ${ROOTPATH}/src/usr/isteps
EXTRAINCDIR += ${ROOTPATH}/src/import/hwpf/fapi2/include/
EXTRAINCDIR += ${ROOTPATH}/src/include/usr/fapi2/
EXTRAINCDIR += ${ROOTPATH}/src/import/chips/common/utils/imageProcs/
+EXTRAINCDIR += ${ROOTPATH}/src/import/chips/common/utils/
EXTRAINCDIR += ${ROOTPATH}/src/import/chips/p9/procedures/hwp/ffdc
VPATH += ${ROOTPATH}/src/usr/hwas/plat
OpenPOWER on IntegriCloud