summaryrefslogtreecommitdiffstats
path: root/import/hwpf
diff options
context:
space:
mode:
authorwhs <whs@us.ibm.com>2016-04-28 07:25:54 -0500
committerSachin Gupta <sgupta2m@in.ibm.com>2016-05-20 05:13:11 -0400
commitd400a7beb23440efa9e5abef4a510abcf44bc5c6 (patch)
treee8beea8c84343bf1e658ab7b257ecb6bc9429c66 /import/hwpf
parentdd7781ce7782bd64bfe45e9dfc8c4d883ae155fb (diff)
downloadtalos-sbe-d400a7beb23440efa9e5abef4a510abcf44bc5c6.tar.gz
talos-sbe-d400a7beb23440efa9e5abef4a510abcf44bc5c6.zip
Changes related to packaging of memory vpd on Nimbus
Create a HWP to process MR and MT keyword to map to memory vpd keyword. Change specialization from MCS to MCA. Change-Id: I426e4c7600e2158737c82e3c2380518c392ada5b RTC: 144519 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/23775 Tested-by: Jenkins Server Reviewed-by: Brian R. Silver <bsilver@us.ibm.com> Tested-by: PPE CI Tested-by: Hostboot CI Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com> Reviewed-by: Matt K. Light <mklight@us.ibm.com> Reviewed-by: Jennifer A. Stofer <stofer@us.ibm.com> Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/23797 Reviewed-by: Sachin Gupta <sgupta2m@in.ibm.com>
Diffstat (limited to 'import/hwpf')
-rw-r--r--import/hwpf/fapi2/include/fapi2_vpd_access.H24
-rw-r--r--import/hwpf/fapi2/include/plat/plat_vpd_access.H9
-rw-r--r--import/hwpf/fapi2/include/plat/vpd_access.H6
3 files changed, 21 insertions, 18 deletions
diff --git a/import/hwpf/fapi2/include/fapi2_vpd_access.H b/import/hwpf/fapi2/include/fapi2_vpd_access.H
index b1d889b6..daf8b006 100644
--- a/import/hwpf/fapi2/include/fapi2_vpd_access.H
+++ b/import/hwpf/fapi2/include/fapi2_vpd_access.H
@@ -33,28 +33,32 @@
namespace fapi2
{
+/// constants for VPD Info
+constexpr uint64_t VPD_INFO_INVALID = 0xffffffffffffffff;
+
/// @brief Specialized class representing required VPDInfo to be used
-/// in collecting VPD for the MCS target type.
-/// @tparam T fapi2::TARGET_TYPE_MCS
+/// in collecting VPD for the MCA target type.
+/// @tparam T fapi2::TARGET_TYPE_MCA
template<>
-class VPDInfo<TARGET_TYPE_MCS>
+class VPDInfo<TARGET_TYPE_MCA>
{
public:
// @brief VPDInfo constructor
VPDInfo( const fapi2::MemVpdData& i_vpd_type)
: iv_vpd_type(i_vpd_type),
- iv_size(0), iv_freq(0), iv_rank_count_dimm_0(0),
- iv_rank_count_dimm_1(0), iv_dimm_drop_per_port(0)
+ 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)
{};
// type of vpd field to return
fapi2::MemVpdData_t iv_vpd_type;
// size of the vpd data
size_t iv_size;
- uint64_t iv_freq;
+ uint64_t iv_freq_mhz;
uint64_t iv_rank_count_dimm_0;
uint64_t iv_rank_count_dimm_1;
- uint64_t iv_dimm_drop_per_port;
};
@@ -67,15 +71,15 @@ class VPDInfo<TARGET_TYPE_MCS>
/// @note passing nullptr for o_blob will return the size of the keyword
///
/// Example:
-/// fapi2::VPDInfo<fapi2::TARGET_TYPE_MCS> vpdInfo(MR_keyword);
-/// vpdInfo.iv_speed_bin = 2400_SPEED_BIN;
+/// fapi2::VPDInfo<fapi2::TARGET_TYPE_MCA> vpdInfo(MR_keyword);
+/// vpdInfo.iv_freq = 2667;
///
/// uint8_t * blob = NULL;
///
/// FAPI_TRY(getVPD( mcs, vpdInfo, blob ));
/// blob = static_cast<uint8_t *>(malloc(vpdInfo.iv_size));
/// FAPI_TRY(getVPD( mcs, vpdInfo, blob ));
-/// blob now contains the VPD data for the MCS.
+/// blob now contains the VPD data for the MCA.
///
template<TargetType T>
ReturnCode getVPD(const Target<T>& i_target,
diff --git a/import/hwpf/fapi2/include/plat/plat_vpd_access.H b/import/hwpf/fapi2/include/plat/plat_vpd_access.H
index d9f32ee9..6097689a 100644
--- a/import/hwpf/fapi2/include/plat/plat_vpd_access.H
+++ b/import/hwpf/fapi2/include/plat/plat_vpd_access.H
@@ -30,9 +30,9 @@ namespace fapi2
{
// -- platform specific getVPD implementation goes here --
-// platform specific for MCS target -- test code only
-inline fapi2::ReturnCode platGetVPD(const fapi2::Target<fapi2::TARGET_TYPE_MCS>& i_target,
- VPDInfo<fapi2::TARGET_TYPE_MCS>& io_vpd_info,
+// platform specific for MCA target -- test code only
+inline fapi2::ReturnCode platGetVPD(const fapi2::Target<fapi2::TARGET_TYPE_MCA>& i_target,
+ VPDInfo<fapi2::TARGET_TYPE_MCA>& io_vpd_info,
uint8_t* o_blob)
{
fapi2::ReturnCode l_rc = fapi2::FAPI2_RC_SUCCESS;
@@ -45,10 +45,9 @@ inline fapi2::ReturnCode platGetVPD(const fapi2::Target<fapi2::TARGET_TYPE_MCS>&
{
o_blob[0] = 111;
- io_vpd_info.iv_freq = 10000;
+ io_vpd_info.iv_freq_mhz = 10000;
io_vpd_info.iv_rank_count_dimm_0 = 1;
io_vpd_info.iv_rank_count_dimm_1 = 8;
- io_vpd_info.iv_dimm_drop_per_port = 6;
}
diff --git a/import/hwpf/fapi2/include/plat/vpd_access.H b/import/hwpf/fapi2/include/plat/vpd_access.H
index b227fab1..ed6fefaf 100644
--- a/import/hwpf/fapi2/include/plat/vpd_access.H
+++ b/import/hwpf/fapi2/include/plat/vpd_access.H
@@ -33,9 +33,9 @@ namespace fapi2
{
// -- platform specializations for getVPD go here --
-// specialization for MCS target
-template<> fapi2::ReturnCode getVPD(const fapi2::Target<fapi2::TARGET_TYPE_MCS>& i_target,
- VPDInfo<fapi2::TARGET_TYPE_MCS>& io_vpd_info,
+// specialization for MCA target
+template<> fapi2::ReturnCode getVPD(const fapi2::Target<fapi2::TARGET_TYPE_MCA>& i_target,
+ VPDInfo<fapi2::TARGET_TYPE_MCA>& io_vpd_info,
uint8_t* o_blob)
{
return platGetVPD( i_target, io_vpd_info, o_blob );
OpenPOWER on IntegriCloud