Skip to content

Commit

Permalink
Implement BC attributes and make eff_dimm class
Browse files Browse the repository at this point in the history
    Implementing the BC# attributes in eff_config
    Also implementing an eff_dimm object and factory
    Move functions from eff_config.C to eff_dimm.C
    Added MRW attribute for write_crc option
    Eff_config is no more

Change-Id: I16607510454f61410711cbcb5c6715e6f80241dd
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/34253
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Reviewed-by: STEPHEN GLANCY <sglancy@us.ibm.com>
Reviewed-by: Brian R. Silver <bsilver@us.ibm.com>
Tested-by: Hostboot CI <hostboot-ci+hostboot@us.ibm.com>
Reviewed-by: Matt K. Light <mklight@us.ibm.com>
Reviewed-by: Christian R. Geddes <crgeddes@us.ibm.com>
Reviewed-by: Jennifer A. Stofer <stofer@us.ibm.com>
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/34254
Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com>
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
  • Loading branch information
JacobHarvey authored and crgeddes committed Jan 25, 2017
1 parent 9540945 commit 9fe6f88
Show file tree
Hide file tree
Showing 15 changed files with 5,712 additions and 5,082 deletions.
4,194 changes: 4,193 additions & 1 deletion src/import/chips/p9/procedures/hwp/memory/lib/dimm/eff_dimm.C

Large diffs are not rendered by default.

1,238 changes: 1,237 additions & 1 deletion src/import/chips/p9/procedures/hwp/memory/lib/dimm/eff_dimm.H

Large diffs are not rendered by default.

4,100 changes: 0 additions & 4,100 deletions src/import/chips/p9/procedures/hwp/memory/lib/eff_config/eff_config.C

This file was deleted.

825 changes: 0 additions & 825 deletions src/import/chips/p9/procedures/hwp/memory/lib/eff_config/eff_config.H

This file was deleted.

Expand Up @@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
/* Contributors Listed Below - COPYRIGHT 2016 */
/* Contributors Listed Below - COPYRIGHT 2016,2017 */
/* [+] International Business Machines Corp. */
/* */
/* */
Expand Down Expand Up @@ -38,9 +38,9 @@
#include <mss.H>
#include <lib/mss_vpd_decoder.H>

#include <lib/eff_config/eff_config.H>
#include <lib/dimm/rank.H>
#include <lib/utils/assert_noexit.H>
#include <lib/eff_config/plug_rules.H>

using fapi2::TARGET_TYPE_MCA;
using fapi2::TARGET_TYPE_MCS;
Expand Down Expand Up @@ -358,7 +358,7 @@ fapi_try_exit:
/// @param[in] i_target FAPI2 target (MCS)
/// @return fapi2::FAPI2_RC_SUCCESS if okay, otherwise a MSS_PLUG_RULE error code
///
fapi2::ReturnCode eff_config::enforce_plug_rules(const fapi2::Target<fapi2::TARGET_TYPE_MCS>& i_target)
fapi2::ReturnCode plug_rule::enforce_plug_rules(const fapi2::Target<fapi2::TARGET_TYPE_MCS>& i_target)
{
// Check per-MCS plug rules. If those all pass, check each of our MCA

Expand Down Expand Up @@ -410,7 +410,7 @@ fapi_try_exit:
/// @param[in] i_target FAPI2 target (MCA)
/// @return fapi2::FAPI2_RC_SUCCESS if okay, otherwise a MSS_PLUG_RULE error code
///
fapi2::ReturnCode eff_config::enforce_plug_rules(const fapi2::Target<fapi2::TARGET_TYPE_MCA>& i_target)
fapi2::ReturnCode plug_rule::enforce_plug_rules(const fapi2::Target<fapi2::TARGET_TYPE_MCA>& i_target)
{
const auto l_dimms = mss::find_targets<TARGET_TYPE_DIMM>(i_target);

Expand Down
Expand Up @@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
/* Contributors Listed Below - COPYRIGHT 2016 */
/* Contributors Listed Below - COPYRIGHT 2016,2017 */
/* [+] International Business Machines Corp. */
/* */
/* */
Expand Down Expand Up @@ -46,6 +46,21 @@ namespace mss
namespace plug_rule
{


///
/// @brief Enforce the plug-rules per MCS
/// @param[in] i_target FAPI2 target (MCS)
/// @return fapi2::FAPI2_RC_SUCCESS if okay, otherwise a MSS_PLUG_RULE error code
///
fapi2::ReturnCode enforce_plug_rules(const fapi2::Target<fapi2::TARGET_TYPE_MCS>& i_target);

///
/// @brief Enforce the plug-rules per MCA
/// @param[in] i_target FAPI2 target (MCA)
/// @return fapi2::FAPI2_RC_SUCCESS if okay, otherwise a MSS_PLUG_RULE error code
///
fapi2::ReturnCode enforce_plug_rules(const fapi2::Target<fapi2::TARGET_TYPE_MCA>& i_target);

///
/// @brief Helper to evaluate the unsupported rank config override attribute
/// @param[in] i_dimm0_ranks count of the ranks on DIMM in slot 0
Expand Down
Expand Up @@ -20266,6 +20266,26 @@ fapi_try_exit:
return fapi2::current_err;
}

///
/// @brief ATTR_MSS_MRW_DRAM_WRITE_CRC getter
/// @param[out] uint8_t& reference to store the value
/// @note Generated by gen_accessors.pl generateParameters (SYSTEM)
/// @return fapi2::ReturnCode - FAPI2_RC_SUCCESS iff get is OK
/// @note Enables DRAM Write
/// CRC
///
inline fapi2::ReturnCode mrw_dram_write_crc(uint8_t& o_value)
{

FAPI_TRY( FAPI_ATTR_GET(fapi2::ATTR_MSS_MRW_DRAM_WRITE_CRC, fapi2::Target<fapi2::TARGET_TYPE_SYSTEM>(), o_value) );
return fapi2::current_err;

fapi_try_exit:
FAPI_ERR("failed accessing ATTR_MSS_MRW_DRAM_WRITE_CRC: 0x%lx (system target)",
uint64_t(fapi2::current_err));
return fapi2::current_err;
}


///
/// @brief ATTR_MSS_VPD_MR_0_VERSION_LAYOUT getter
Expand Down
Expand Up @@ -5,7 +5,7 @@
/* */
/* OpenPOWER HostBoot Project */
/* */
/* Contributors Listed Below - COPYRIGHT 2016 */
/* Contributors Listed Below - COPYRIGHT 2016,2017 */
/* [+] International Business Machines Corp. */
/* */
/* */
Expand Down Expand Up @@ -143,7 +143,7 @@ class dimm_module_decoder
}

///
/// @brief Decodes number of rows of DRAMs on RDIMM
/// @brief Decodes register and buffer type for LRDIMMs
/// @param[out] o_output encoding from SPD
/// @return FAPI2_RC_SUCCESS if okay
/// @note SPD Byte 131 (Bits 7~4)
Expand Down

0 comments on commit 9fe6f88

Please sign in to comment.