summaryrefslogtreecommitdiffstats
path: root/src/import/hwpf/fapi2/include/fapi2_vpd_access.H
diff options
context:
space:
mode:
authorDan Crowell <dcrowell@us.ibm.com>2019-01-17 08:57:31 -0600
committerRAJA DAS <rajadas2@in.ibm.com>2019-01-24 02:49:25 -0600
commit2e253cebdaffb92d67fe19999d818e327daca1fb (patch)
tree8b3c98812d3c9612ff4b587fc4a89ab9a7766edc /src/import/hwpf/fapi2/include/fapi2_vpd_access.H
parent0121de3404a4cc217f8c5445d8a2e14684718886 (diff)
downloadtalos-sbe-2e253cebdaffb92d67fe19999d818e327daca1fb.tar.gz
talos-sbe-2e253cebdaffb92d67fe19999d818e327daca1fb.zip
Interface for OCMB getVPD
Add new getVPD interface to support the OCMB chip with the DDIMM SPD. Change-Id: I7bb8b7958aeeaca2fda788b013e9e5e244013c27 Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/70596 Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Reviewed-by: STEPHEN GLANCY <sglancy@us.ibm.com> Tested-by: PPE CI <ppe-ci+hostboot@us.ibm.com> Tested-by: Hostboot CI <hostboot-ci+hostboot@us.ibm.com> Reviewed-by: Louis Stermole <stermole@us.ibm.com> Reviewed-by: ANDRE A. MARIN <aamarin@us.ibm.com> Reviewed-by: Jennifer A. Stofer <stofer@us.ibm.com> Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/70600 Reviewed-by: RAJA DAS <rajadas2@in.ibm.com>
Diffstat (limited to 'src/import/hwpf/fapi2/include/fapi2_vpd_access.H')
-rw-r--r--src/import/hwpf/fapi2/include/fapi2_vpd_access.H71
1 files changed, 64 insertions, 7 deletions
diff --git a/src/import/hwpf/fapi2/include/fapi2_vpd_access.H b/src/import/hwpf/fapi2/include/fapi2_vpd_access.H
index 0482e74d..d71a2195 100644
--- a/src/import/hwpf/fapi2/include/fapi2_vpd_access.H
+++ b/src/import/hwpf/fapi2/include/fapi2_vpd_access.H
@@ -5,7 +5,7 @@
/* */
/* OpenPOWER sbe Project */
/* */
-/* Contributors Listed Below - COPYRIGHT 2016,2018 */
+/* Contributors Listed Below - COPYRIGHT 2016,2019 */
/* [+] International Business Machines Corp. */
/* */
/* */
@@ -40,7 +40,9 @@ namespace fapi2
{
/// constants for VPD Info
-constexpr uint64_t VPD_INFO_INVALID = 0xffffffffffffffff;
+constexpr uint64_t VPD_INFO_INVALID_64 = 0xffffffffffffffff;
+constexpr uint64_t VPD_INFO_INVALID_16 = 0xffff;
+constexpr uint64_t VPD_INFO_INVALID_8 = 0xff;
/// @brief Specialized class representing required VPDInfo to be used
/// in collecting VPD for the MCS target type.
@@ -49,13 +51,14 @@ template<>
class VPDInfo<TARGET_TYPE_MCS>
{
public:
- // @brief VPDInfo constructor
+ /// @brief VPDInfo constructor
+ /// @param[in] Type of VPD data to return
VPDInfo( const fapi2::MemVpdData& i_vpd_type)
: iv_vpd_type(i_vpd_type),
- iv_size(VPD_INFO_INVALID),
- iv_freq_mhz(VPD_INFO_INVALID),
- iv_rank_count_dimm_0(VPD_INFO_INVALID),
- iv_rank_count_dimm_1(VPD_INFO_INVALID),
+ iv_size(VPD_INFO_INVALID_64),
+ iv_freq_mhz(VPD_INFO_INVALID_64),
+ iv_rank_count_dimm_0(VPD_INFO_INVALID_64),
+ iv_rank_count_dimm_1(VPD_INFO_INVALID_64),
iv_is_config_ffdc_enabled(true)
{};
// type of vpd field to return
@@ -63,12 +66,66 @@ class VPDInfo<TARGET_TYPE_MCS>
// size of the vpd data
size_t iv_size;
+
+ // frequency of memory bus
uint64_t iv_freq_mhz;
+
+ // number of ranks per dimm position
uint64_t iv_rank_count_dimm_0;
uint64_t iv_rank_count_dimm_1;
+
+ // set to false to avoid collecting a real ReturnCode
bool iv_is_config_ffdc_enabled;
};
+/// @brief Specialized class representing required VPDInfo to be used
+/// in collecting VPD for the OCMB_CHIP target type.
+/// @tparam T fapi2::TARGET_TYPE_OCMB_CHIP
+template<>
+class VPDInfo<TARGET_TYPE_OCMB_CHIP>
+{
+ public:
+ /// @brief VPDInfo constructor
+ /// @param[in] Type of VPD data to return
+ VPDInfo( const fapi2::MemVpdData& i_vpd_type)
+ : iv_vpd_type(i_vpd_type),
+ iv_size(VPD_INFO_INVALID_64),
+ iv_omi_freq_mhz(VPD_INFO_INVALID_64),
+ iv_rank_count(VPD_INFO_INVALID_64),
+ iv_is_config_ffdc_enabled(true),
+ iv_efd_type(VPD_INFO_INVALID_8),
+ iv_dmb_mfg_id(VPD_INFO_INVALID_16),
+ iv_dmb_revision(VPD_INFO_INVALID_8),
+ iv_ddr_mode(VPD_INFO_INVALID_8)
+ {};
+
+ // *** INPUT DATA ***
+
+ // type of vpd field to return
+ fapi2::MemVpdData_t iv_vpd_type;
+
+ // size of the vpd data in bytes
+ size_t iv_size;
+
+ // frequency of attached OMI bus
+ uint64_t iv_omi_freq_mhz;
+
+ // number of master ranks
+ uint64_t iv_rank_count;
+
+ // set to false to avoid collecting a real ReturnCode
+ bool iv_is_config_ffdc_enabled;
+
+
+ // *** OUTPUT DATA ***
+
+ // metadata describing the EFD data that was returned
+ uint8_t iv_efd_type; // e.g. byte 288 of DDIMM SPD
+ uint16_t iv_dmb_mfg_id; // buffer manufacturer
+ uint8_t iv_dmb_revision; // buffer revision
+ uint8_t iv_ddr_mode; // DDR4 or DDR5
+};
+
/// @brief Return a blob of memory VPD data associated with the input target
/// @param[in] i_target a valid fapi2 target
OpenPOWER on IntegriCloud