diff options
author | Joachim Fenkes <fenkes@de.ibm.com> | 2019-02-22 15:47:44 +0100 |
---|---|---|
committer | Daniel M. Crowell <dcrowell@us.ibm.com> | 2019-04-08 09:21:12 -0500 |
commit | 96195e47b5036a027dfa87c79cdae717d0c6cc2b (patch) | |
tree | 1d757a71920d4bc840e6e2ed9ddbfee36787827b /src/import/chips/p9/procedures/hwp | |
parent | 63a8b58f12b7127eafebd3cd5a716ecfe3d924d6 (diff) | |
download | talos-hostboot-96195e47b5036a027dfa87c79cdae717d0c6cc2b.tar.gz talos-hostboot-96195e47b5036a027dfa87c79cdae717d0c6cc2b.zip |
Fix for workaround for HW480181
The workaround works fine when Cronus only sets up a single
TOD topology, but once _actual_ firmware on an _actual_ system
sets up a primary and backup topology, the simpleton fix wipes
out part of the primary config when the backup config is set up.
Fixed by only updating the partial register and only while the
primary topology is being set up.
Also fix MPIPL setup where a copy-paste error cause an invalid
value in the master path control register.
Change-Id: Ief4757cd1d082f18e625142f3e3246dfdc5771a2
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/72337
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Tested-by: HWSV CI <hwsv-ci+hostboot@us.ibm.com>
Tested-by: Hostboot CI <hostboot-ci+hostboot@us.ibm.com>
Reviewed-by: Joseph J. McGill <jmcgill@us.ibm.com>
Reviewed-by: Manish K. Chowdhary <manichow@in.ibm.com>
Reviewed-by: Jennifer A. Stofer <stofer@us.ibm.com>
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/72350
Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com>
Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Diffstat (limited to 'src/import/chips/p9/procedures/hwp')
-rw-r--r-- | src/import/chips/p9/procedures/hwp/nest/p9_tod_setup.C | 24 |
1 files changed, 17 insertions, 7 deletions
diff --git a/src/import/chips/p9/procedures/hwp/nest/p9_tod_setup.C b/src/import/chips/p9/procedures/hwp/nest/p9_tod_setup.C index 1c7b2c6c3..04ce62cd9 100644 --- a/src/import/chips/p9/procedures/hwp/nest/p9_tod_setup.C +++ b/src/import/chips/p9/procedures/hwp/nest/p9_tod_setup.C @@ -42,7 +42,7 @@ //-------------------------------------------------------------------------- #include <p9_tod_setup.H> -const uint64_t M_PATH_CTRL_REG_CLEAR_VALUE = 0x0000003F00000000; +const uint64_t M_PATH_CTRL_REG_CLEAR_VALUE = 0x0000000000000000; const uint64_t S_PATH_CTRL_REG_CLEAR_VALUE = 0x0000003F00000000; /// @brief MPIPL specific steps to clear the previous topology, this should be @@ -173,12 +173,22 @@ fapi2::ReturnCode clear_tod_node( 0x0ULL), "Error from putScom (0x%08X)!", l_port_ctrl_check_reg); - // Workaround for HW480181: Init remote sync checker tolerance to maximum; - // will be closed down by tod_init later. - FAPI_TRY(fapi2::putScom(*(i_tod_node->i_target), - PERV_TOD_S_PATH_CTRL_REG, - S_PATH_CTRL_REG_CLEAR_VALUE), - "Error from putScom (0x%08X)!", l_port_ctrl_check_reg); + if (i_tod_sel == TOD_PRIMARY) + { + // Workaround for HW480181: Init remote sync checker tolerance to maximum; + // will be closed down by configure_tod_node later. + fapi2::buffer<uint64_t> l_data; + FAPI_TRY(fapi2::getScom(*(i_tod_node->i_target), PERV_TOD_S_PATH_CTRL_REG, l_data), + "Error from getScom (PERV_TOD_S_PATH_CTRL_REG)!"); + l_data.insertFromRight<PERV_TOD_S_PATH_CTRL_REG_REMOTE_SYNC_CHECK_CPS_DEVIATION, + PERV_TOD_S_PATH_CTRL_REG_REMOTE_SYNC_CHECK_CPS_DEVIATION_LEN> + (STEP_CHECK_CPS_DEVIATION_93_75_PCENT); + l_data.insertFromRight<PERV_TOD_S_PATH_CTRL_REG_REMOTE_SYNC_CHECK_CPS_DEVIATION_FACTOR, + PERV_TOD_S_PATH_CTRL_REG_REMOTE_SYNC_CHECK_CPS_DEVIATION_FACTOR_LEN> + (STEP_CHECK_CPS_DEVIATION_FACTOR_8); + FAPI_TRY(fapi2::putScom(*(i_tod_node->i_target), PERV_TOD_S_PATH_CTRL_REG, l_data), + "Error from putScom (PERV_TOD_S_PATH_CTRL_REG)!"); + } // TOD is cleared for this node; if it has children, start clearing |