diff options
author | Mark Pizzutillo <Mark.Pizzutillo@ibm.com> | 2019-09-16 17:08:27 -0400 |
---|---|---|
committer | RAJA DAS <rajadas2@in.ibm.com> | 2019-10-20 22:07:47 -0500 |
commit | 9346ae92afe770520eab50b82073b43bef7769d1 (patch) | |
tree | c8bbea7ddbd1730309ab779da07c7b518c1fb95c /src/import/chips | |
parent | 2b61547bd03e4919a113b2fa19ec587724c66573 (diff) | |
download | talos-sbe-9346ae92afe770520eab50b82073b43bef7769d1.tar.gz talos-sbe-9346ae92afe770520eab50b82073b43bef7769d1.zip |
Add code and workarounds for *_omi_setup and *_omi_train for Swift
Change-Id: I139357a553e621b25b46bee6303357c712b67be2
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/83848
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Dev-Ready: Steven B Janssen <janssens@us.ibm.com>
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Tested-by: PPE CI <ppe-ci+hostboot@us.ibm.com>
Reviewed-by: STEPHEN GLANCY <sglancy@us.ibm.com>
Reviewed-by: Christian R Geddes <crgeddes@us.ibm.com>
Reviewed-by: Louis Stermole <stermole@us.ibm.com>
Reviewed-by: Jennifer A Stofer <stofer@us.ibm.com>
Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/84274
Reviewed-by: RAJA DAS <rajadas2@in.ibm.com>
Diffstat (limited to 'src/import/chips')
-rw-r--r-- | src/import/chips/ocmb/explorer/procedures/hwp/memory/lib/i2c/exp_i2c.H | 38 | ||||
-rw-r--r-- | src/import/chips/ocmb/explorer/procedures/xml/error_info/mss_exp_errors.xml | 22 |
2 files changed, 55 insertions, 5 deletions
diff --git a/src/import/chips/ocmb/explorer/procedures/hwp/memory/lib/i2c/exp_i2c.H b/src/import/chips/ocmb/explorer/procedures/hwp/memory/lib/i2c/exp_i2c.H index 9d415e92..e4cdec0a 100644 --- a/src/import/chips/ocmb/explorer/procedures/hwp/memory/lib/i2c/exp_i2c.H +++ b/src/import/chips/ocmb/explorer/procedures/hwp/memory/lib/i2c/exp_i2c.H @@ -295,11 +295,39 @@ inline fapi2::ReturnCode boot_config(const fapi2::Target<fapi2::TARGET_TYPE_OCMB // The command takes ~300ms and we poll for around 100ms, so wait 250ms here FAPI_TRY( fapi2::delay( (mss::DELAY_1MS * 250), 200) ); - // Poll for status response - // Note: the EXP_FW_BOOT_CONFIG command trains the OMI, which takes a - // significant amount of time. We're waiting 1ms between polls, and poll for 100 loops, - // which totals at least 100ms - FAPI_TRY(fw_status(i_target, DELAY_1MS, 100)); +fapi_try_exit: + return fapi2::current_err; +} + +/// +/// @brief Check that the FW status code returns a busy status (expected for exp_omi_train) +/// +/// @param[in] i_target OCMB +/// @return fapi2::ReturnCode FAPI2_RC_SUCCESS iff busy and no error code, else, error code +/// +inline fapi2::ReturnCode check_fw_status_busy(const fapi2::Target<fapi2::TARGET_TYPE_OCMB_CHIP>& i_target) +{ + uint8_t l_status = ~(0); + + std::vector<uint8_t> l_data; + FAPI_TRY(get_fw_status(i_target, l_data)); + + FAPI_TRY(status::get_status_code(i_target, l_data, l_status)); + + // Post bootconfig1, we should see a busy status until p9a_omi_train is kicked off (setting axone to AUTO_TRAIN) + // explorer will return busy status until then. if we have another status, then we may not have executed bootconfig1 + // or some previous command correctly, so we should check it here + // After p9a_omi_train, exp_omi_train_check will check fw_status for success (in addition to checking training completion) + // to make sure things went smoothly + FAPI_ASSERT( l_status == status_codes::FW_BUSY, + fapi2::MSS_EXP_I2C_FW_BOOT_CONFIG_STATUS_CODE_INVALID(). + set_TARGET(i_target). + set_STATUS_CODE(l_status). + set_CMD_ID(FW_STATUS), + "Status code did not return BUSY (%d) as expected post BOOT_CONFIG1, received (%d) for " TARGIDFORMAT , + status_codes::FW_BUSY, l_status, TARGID ); + + return fapi2::FAPI2_RC_SUCCESS; fapi_try_exit: return fapi2::current_err; diff --git a/src/import/chips/ocmb/explorer/procedures/xml/error_info/mss_exp_errors.xml b/src/import/chips/ocmb/explorer/procedures/xml/error_info/mss_exp_errors.xml index 6533f82b..f2ed87b6 100644 --- a/src/import/chips/ocmb/explorer/procedures/xml/error_info/mss_exp_errors.xml +++ b/src/import/chips/ocmb/explorer/procedures/xml/error_info/mss_exp_errors.xml @@ -373,6 +373,28 @@ </hwpError> <hwpError> + <rc>RC_MSS_EXP_I2C_FW_BOOT_CONFIG_STATUS_CODE_INVALID</rc> + <description> + Unexpected Explorer status code returned during OMI link training pattern handshake. + Expected FW_BUSY, but received STATUS_CODE in FFDC data + </description> + <ffdc>TARGET</ffdc> + <ffdc>STATUS_CODE</ffdc> + <ffdc>CMD_ID</ffdc> + <callout> + <procedure>CODE</procedure> + <priority>MEDIUM</priority> + </callout> + <callout> + <target>TARGET</target> + <priority>HIGH</priority> + </callout> + <deconfigure> + <target>TARGET</target> + </deconfigure> + </hwpError> + + <hwpError> <rc>RC_MSS_EXP_I2C_FW_STATUS_BUSY</rc> <description> Received FW_BUSY status after polling timeout for |