From cf5d76cbc8911c5ac71fd539b2f5d2c7470d49a0 Mon Sep 17 00:00:00 2001 From: Jacob Harvey Date: Thu, 12 Oct 2017 13:02:26 -0500 Subject: Set blue waterfall range to 1-4 for all freqs If red waterfall workaround was ran Change-Id: I7ae2433e1e5aaa7f0f0f77455a78f411c1768ef3 CQ: SW404923 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/48313 Tested-by: FSP CI Jenkins Dev-Ready: JACOB L. HARVEY Reviewed-by: STEPHEN GLANCY Tested-by: Jenkins Server Tested-by: Hostboot CI Reviewed-by: Louis Stermole Reviewed-by: Jennifer A. Stofer Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/48327 Tested-by: Jenkins OP Build CI Tested-by: Jenkins OP HW Reviewed-by: Christian R. Geddes --- .../chips/p9/procedures/hwp/memory/lib/phy/dp16.C | 4 ++++ .../hwp/memory/lib/workarounds/dp16_workarounds.H | 18 ++++++++++++++++++ 2 files changed, 22 insertions(+) (limited to 'src/import/chips/p9/procedures/hwp/memory') diff --git a/src/import/chips/p9/procedures/hwp/memory/lib/phy/dp16.C b/src/import/chips/p9/procedures/hwp/memory/lib/phy/dp16.C index e41461bb1..89bf21328 100644 --- a/src/import/chips/p9/procedures/hwp/memory/lib/phy/dp16.C +++ b/src/import/chips/p9/procedures/hwp/memory/lib/phy/dp16.C @@ -2495,6 +2495,10 @@ fapi2::ReturnCode reset_drift_limits( const fapi2::Target& i_ta blue_waterfall_range::TWO_TO_FIVE : blue_waterfall_range::ONE_TO_FOUR; + // So if the red waterfall workaround was/ is going to run, we have to change the blue waterfall range + // This is freq independent + mss::workarounds::dp16::update_blue_waterfall_extend_range( i_target, l_value); + //From John Bialas : the value is good for hardware, but not so much in sim, in sim they should be 0s - bgass - 10/6/2017 l_value = (l_sim == 1) ? blue_waterfall_range::ZERO_TO_THREE : l_value; diff --git a/src/import/chips/p9/procedures/hwp/memory/lib/workarounds/dp16_workarounds.H b/src/import/chips/p9/procedures/hwp/memory/lib/workarounds/dp16_workarounds.H index 40918277c..586d5419d 100644 --- a/src/import/chips/p9/procedures/hwp/memory/lib/workarounds/dp16_workarounds.H +++ b/src/import/chips/p9/procedures/hwp/memory/lib/workarounds/dp16_workarounds.H @@ -219,6 +219,24 @@ inline void update_red_waterfall(uint64_t& io_red_waterfall) } } +/// +/// @brief If red_waterfall workaround is run, the blue waterfall range needs to be 1-4 +/// @param[in] i_target - the target to operate on +/// @param[in,out] io_blue_extended_range - the blue waterfall range variable +/// @return fapi2::ReturnCode FAPI2_RC_SUCCESS if ok +/// @note this is freq independant +/// +inline void update_blue_waterfall_extend_range( const fapi2::Target& i_target, + blue_waterfall_range& io_blue_extended_range) +{ + const bool l_red_waterfall = mss::chip_ec_feature_red_waterfall_adjust(i_target); + + if ( l_red_waterfall ) + { + io_blue_extended_range = blue_waterfall_range::ONE_TO_FOUR; + } +} + /// /// @brief Gets the red waterfall and gate delay values for a given DP quad /// @tparam uint64_t QUAD - which quad to access -- cgit v1.2.1