summaryrefslogtreecommitdiffstats
path: root/src/usr/vpd
diff options
context:
space:
mode:
authorCorey Swenson <cswenson@us.ibm.com>2014-11-12 11:08:44 -0600
committerA. Patrick Williams III <iawillia@us.ibm.com>2014-12-01 15:42:25 -0600
commitae5a0adb5f8350e95d274947233f57e79cc0385c (patch)
tree4070a136ee19a45db03942bf88ff47dc37932a46 /src/usr/vpd
parent21b982cb3db766c1d59a11085ba2566532983692 (diff)
downloadtalos-hostboot-ae5a0adb5f8350e95d274947233f57e79cc0385c.tar.gz
talos-hostboot-ae5a0adb5f8350e95d274947233f57e79cc0385c.zip
Remove workarounds for SPD presence detect
Change-Id: I39ac81fcf079197d065e839d1237c5107e4c6036 RTC: 111211 Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/14450 Tested-by: Jenkins Server Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com> Reviewed-by: Michael Baiocchi <baiocchi@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
Diffstat (limited to 'src/usr/vpd')
-rwxr-xr-xsrc/usr/vpd/dimmPres.C38
1 files changed, 28 insertions, 10 deletions
diff --git a/src/usr/vpd/dimmPres.C b/src/usr/vpd/dimmPres.C
index ca8b3f149..1524aebd4 100755
--- a/src/usr/vpd/dimmPres.C
+++ b/src/usr/vpd/dimmPres.C
@@ -37,6 +37,7 @@
#include <errl/errlentry.H>
#include <errl/errlmanager.H>
#include <targeting/common/targetservice.H>
+#include <targeting/common/utilFilter.H>
#include <devicefw/driverif.H>
#include <vpd/vpdreasoncodes.H>
#include <vpd/spdenums.H>
@@ -124,21 +125,38 @@ errlHndl_t dimmPresenceDetect( DeviceFW::OperationType i_opType,
// Is the target present
#ifdef CONFIG_DJVPD_READ_FROM_HW
- // Check if the parent MBA is functional.
- // If it is non-functional then no reason to check the DIMM which
- // would otherwise generate tons of FSI errors.
- TARGETING::TargetHandleList membuf_parent;
- TARGETING::PredicateIsFunctional isFunctional;
+ // Check if the parent MBA/MEMBUF is present. If it is not then
+ // no reason to check the DIMM which would otherwise generate
+ // tons of FSI errors. We can't just check if parent MBA
+ // is functional because DIMM presence detect is called before
+ // the parent MBA/MEMBUF is set as present/functional.
+ TARGETING::TargetHandleList membufList;
+ TARGETING::PredicateCTM membufPred( TARGETING::CLASS_CHIP,
+ TARGETING::TYPE_MEMBUF );
TARGETING::targetService().getAssociated(
- membuf_parent,
+ membufList,
i_target,
TARGETING::TargetService::PARENT_BY_AFFINITY,
- TARGETING::TargetService::IMMEDIATE,
- &isFunctional);
- if ( membuf_parent.size() != 1 )
+ TARGETING::TargetService::ALL,
+ &membufPred);
+
+ bool parentPresent = false;
+ const TARGETING::TargetHandle_t membufTarget = *(membufList.begin());
+
+ err = deviceRead(membufTarget, &parentPresent, presentSz,
+ DEVICE_PRESENT_ADDRESS());
+ if (err)
+ {
+ TRACFCOMP(
+ g_trac_spd,
+ "Error reading parent MEMBUF present: huid 0x%X DIMM huid 0x%X",
+ TARGETING::get_huid(membufTarget),
+ TARGETING::get_huid(i_target) );
+ break;
+ }
+ if (!parentPresent)
{
present = false;
-
// Invalidate the SPD in PNOR
err = VPD::invalidatePnorCache(i_target);
if (err)
OpenPOWER on IntegriCloud