diff options
| author | Christian Geddes <crgeddes@us.ibm.com> | 2019-01-15 09:47:31 -0600 |
|---|---|---|
| committer | Daniel M. Crowell <dcrowell@us.ibm.com> | 2019-02-13 14:41:48 -0600 |
| commit | aa18e987116a8e03391473c488d0ddb1d5ea8eb5 (patch) | |
| tree | c03228ca69f31fcdf26a84f4cf15e1eb736b5164 /src/usr/hwas | |
| parent | b9678e8f9164c44361614e50cf02b6e31c860303 (diff) | |
| download | blackbird-hostboot-aa18e987116a8e03391473c488d0ddb1d5ea8eb5.tar.gz blackbird-hostboot-aa18e987116a8e03391473c488d0ddb1d5ea8eb5.zip | |
Add EEPROM caching device op
This commit introduces a new EEPROM_CACHE deviceOp and registers
the OCMB_CHIP, PROC, and DIMM targets to it. This is part of the
larger effort to transition for a "VPD" cache to an "EEPROM" cache
in pnor. The deviceOp is currently called in hwasPlat's
platPresenceDetect if the target in question has a
ATTR_EEPROM_VPD_PRIMARY_INFO associated with it. The layout for the
new EECACHE section in pnor is defined in eepromCache_const.H.
Essentially it is a header that contains an array of record headers
that tell where in the EECACHE pnor section a given cached EEPROM
can be found. All EEPROM targets will be allocated space in the
EECACHE section but only present targets will have their cache
filled in.
RTC: 196805
Change-Id: I49c341c9784be04ddf0259bd444f06c9baf8c6f1
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/70520
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com>
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com>
Reviewed-by: Matt Derksen <mderkse1@us.ibm.com>
Reviewed-by: Roland Veloz <rveloz@us.ibm.com>
Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Diffstat (limited to 'src/usr/hwas')
| -rw-r--r-- | src/usr/hwas/hwasPlat.C | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/src/usr/hwas/hwasPlat.C b/src/usr/hwas/hwasPlat.C index 35e9588e0..e72d5109e 100644 --- a/src/usr/hwas/hwasPlat.C +++ b/src/usr/hwas/hwasPlat.C @@ -48,9 +48,12 @@ #include <fsi/fsiif.H> #include <config.h> #include <targeting/common/targetservice.H> - #include <chipids.H> +#ifdef CONFIG_SUPPORT_EEPROM_CACHING +#include <i2c/eepromif.H> +#endif + namespace HWAS { @@ -615,6 +618,18 @@ errlHndl_t platPresenceDetect(TargetHandleList &io_targets) // erase this target, and 'increment' to next pTarget_it = io_targets.erase(pTarget_it); } +#ifdef CONFIG_SUPPORT_EEPROM_CACHING + TARGETING::EepromVpdPrimaryInfo eepromData; + if (pTarget->tryGetAttr<ATTR_EEPROM_VPD_PRIMARY_INFO>(eepromData)) + { + HWAS_INF( "Reading EEPROMs for target, eeprom type = %d , target present = %d , eeprom type = %d", + DEVICE_CACHE_EEPROM_ADDRESS(present, EEPROM::VPD_PRIMARY)); + errl = deviceRead(pTarget, &present, presentSize, + DEVICE_CACHE_EEPROM_ADDRESS(present, EEPROM::VPD_PRIMARY)); + errlCommit(errl, HWAS_COMP_ID); + // errl is now null, move on to next target + } +#endif } // for pTarget_it return errl; |

