From f83005325604106a140cfc3f3673165a36b93b7e Mon Sep 17 00:00:00 2001 From: "Andre A. Marin" Date: Thu, 9 May 2019 10:08:25 -0500 Subject: Added Nimbus NDVDIMM specific DIMM slot attribute Change-Id: I4ae692f931ebaac275cd3a66783a5fceb2d6894f Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/77179 Tested-by: FSP CI Jenkins Tested-by: Jenkins Server Tested-by: Hostboot CI Reviewed-by: Louis Stermole Reviewed-by: TSUNG K YEUNG Tested-by: HWSV CI Reviewed-by: Jennifer A. Stofer Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/77193 Tested-by: Jenkins OP Build CI Reviewed-by: Daniel M. Crowell --- .../hwp/memory/lib/mss_attribute_accessors.H | 25 ++++++++++++++++++++++ 1 file changed, 25 insertions(+) (limited to 'src/import/chips/p9/procedures/hwp/memory') diff --git a/src/import/chips/p9/procedures/hwp/memory/lib/mss_attribute_accessors.H b/src/import/chips/p9/procedures/hwp/memory/lib/mss_attribute_accessors.H index 8d6458ed3..d41445265 100644 --- a/src/import/chips/p9/procedures/hwp/memory/lib/mss_attribute_accessors.H +++ b/src/import/chips/p9/procedures/hwp/memory/lib/mss_attribute_accessors.H @@ -14141,6 +14141,31 @@ fapi_try_exit: } +/// +/// @brief ATTR_MSS_MRW_NVDIMM_SLOT_POSITION getter +/// @param[in] const ref to the TARGET_TYPE_DIMM +/// @param[out] uint8_t& reference to store the value +/// @note Generated by gen_accessors.pl generateParameters (PROC_CHIP) +/// @return fapi2::ReturnCode - FAPI2_RC_SUCCESS iff get is OK +/// @note The position of a dimm is based on which mca it is associated with and which +/// drop behind that mca, with 16 dimms possible per processor socket. The formula +/// is: [processor position with no gaps, i.e. 0,1,2,3]*16 + [mca position on this +/// processor * 2] + [dimm location behind this +/// mca] +/// +inline fapi2::ReturnCode mrw_nvdimm_slot_position(const fapi2::Target& i_target, + uint8_t& o_value) +{ + + FAPI_TRY( FAPI_ATTR_GET(fapi2::ATTR_MSS_MRW_NVDIMM_SLOT_POSITION, i_target, o_value) ); + return fapi2::current_err; + +fapi_try_exit: + FAPI_ERR("failed accessing ATTR_MSS_MRW_NVDIMM_SLOT_POSITION: 0x%lx", + uint64_t(fapi2::current_err)); + return fapi2::current_err; +} + /// /// @brief ATTR_MSS_MRW_UNSUPPORTED_RANK_CONFIG getter /// @param[in] const ref to the fapi2::Target -- cgit v1.2.1