diff options
author | Alvin Wang <wangat@tw.ibm.com> | 2019-03-14 22:36:56 -0500 |
---|---|---|
committer | Daniel M. Crowell <dcrowell@us.ibm.com> | 2019-05-07 15:47:58 -0500 |
commit | 081679022f978b41f7764b50fe5b9e741b0d2ce3 (patch) | |
tree | ec27993c7b95d0f49745579f2badfac43b61f73a /src/import/chips/p9/procedures/hwp/memory/p9_mss_background_scrub.C | |
parent | e28412847eab880521683afc182e3eaceb18a723 (diff) | |
download | talos-hostboot-081679022f978b41f7764b50fe5b9e741b0d2ce3.tar.gz talos-hostboot-081679022f978b41f7764b50fe5b9e741b0d2ce3.zip |
Add exp_scrub
Change-Id: Ibf52a563c7d8ce3e1cc97d07f3801b3bca58eddd
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/70247
Dev-Ready: Alvin Wang <wangat@tw.ibm.com>
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Tested-by: Hostboot CI <hostboot-ci+hostboot@us.ibm.com>
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Reviewed-by: Louis Stermole <stermole@us.ibm.com>
Reviewed-by: STEPHEN GLANCY <sglancy@us.ibm.com>
Reviewed-by: Jennifer A. Stofer <stofer@us.ibm.com>
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/75146
Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Tested-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Diffstat (limited to 'src/import/chips/p9/procedures/hwp/memory/p9_mss_background_scrub.C')
-rw-r--r-- | src/import/chips/p9/procedures/hwp/memory/p9_mss_background_scrub.C | 45 |
1 files changed, 13 insertions, 32 deletions
diff --git a/src/import/chips/p9/procedures/hwp/memory/p9_mss_background_scrub.C b/src/import/chips/p9/procedures/hwp/memory/p9_mss_background_scrub.C index 06e15b95b..7f02e7cf6 100644 --- a/src/import/chips/p9/procedures/hwp/memory/p9_mss_background_scrub.C +++ b/src/import/chips/p9/procedures/hwp/memory/p9_mss_background_scrub.C @@ -43,48 +43,29 @@ #include <generic/memory/lib/utils/mcbist/gen_patterns.H> #include <lib/mcbist/memdiags.H> #include <generic/memory/lib/utils/count_dimm.H> -#include <lib/fir/memdiags_fir.H> +#include <lib/fir/unmask.H> using fapi2::TARGET_TYPE_MCBIST; using fapi2::TARGET_TYPE_MCA; using fapi2::TARGET_TYPE_SYSTEM; using fapi2::FAPI2_RC_SUCCESS; -/// -/// @brief Begin background scrub -/// @param[in] i_target MCBIST -/// @return FAPI2_RC_SUCCESS iff ok -/// -fapi2::ReturnCode p9_mss_background_scrub( const fapi2::Target<TARGET_TYPE_MCBIST>& i_target ) -{ - FAPI_INF("Start mss background scrub on: %s", mss::c_str( i_target )); - // If there are no DIMM we don't need to bother. In fact, we can't as we didn't setup - // attributes for the PHY, etc. - if (mss::count_dimm(i_target) == 0) - { - FAPI_INF("... skipping background scrub for %s - no DIMM ...", mss::c_str(i_target)); - return fapi2::FAPI2_RC_SUCCESS; - } - - // If we're running in the simulator, we want to only touch the addresses which training touched - uint8_t l_sim = 0; - FAPI_TRY( mss::is_simulation(l_sim) ); +extern "C" +{ - // Kick off background scrub if we are not running in sim - if (!(l_sim)) + /// + /// @brief Begin background scrub + /// @param[in] i_target MCBIST + /// @return FAPI2_RC_SUCCESS iff ok + /// + fapi2::ReturnCode p9_mss_background_scrub( const fapi2::Target<TARGET_TYPE_MCBIST>& i_target ) { - // Start background scrub - FAPI_TRY ( mss::memdiags::background_scrub( i_target, - mss::mcbist::stop_conditions<>(), - mss::mcbist::speed::BG_SCRUB, - mss::mcbist::address() ) ); + FAPI_INF("Start mss background scrub on: %s", mss::c_str( i_target )); + FAPI_TRY(mss::memdiags::mss_background_scrub_helper(i_target)); + fapi_try_exit: + return fapi2::current_err; } - // Unmask firs after background scrub is started - FAPI_TRY ( mss::unmask::after_background_scrub( i_target ) ); - -fapi_try_exit: - return fapi2::current_err; } |