From 3dc237792334ac38075f21c4e41acea133d48482 Mon Sep 17 00:00:00 2001 From: Matthew Raybuck Date: Thu, 1 Aug 2019 07:56:16 -0500 Subject: Add error logs to BPM update procedure Adds error logs throughout various locations in the code in bpm_update.C that were not included in prior commits. Change-Id: Id547744c48b8654120f57a1a356db8defa5aa9ec RTC: 212447 Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/81507 Reviewed-by: Roland Veloz Reviewed-by: Christian R Geddes Tested-by: Jenkins Server Tested-by: Jenkins OP Build CI Tested-by: Jenkins OP HW Tested-by: FSP CI Jenkins Reviewed-by: Daniel M Crowell --- src/include/usr/isteps/nvdimm/bpmreasoncodes.H | 76 ++++++++++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 src/include/usr/isteps/nvdimm/bpmreasoncodes.H (limited to 'src/include') diff --git a/src/include/usr/isteps/nvdimm/bpmreasoncodes.H b/src/include/usr/isteps/nvdimm/bpmreasoncodes.H new file mode 100644 index 000000000..bceee7bfc --- /dev/null +++ b/src/include/usr/isteps/nvdimm/bpmreasoncodes.H @@ -0,0 +1,76 @@ +/* IBM_PROLOG_BEGIN_TAG */ +/* This is an automatically generated prolog. */ +/* */ +/* $Source: src/include/usr/isteps/nvdimm/bpmreasoncodes.H $ */ +/* */ +/* OpenPOWER HostBoot Project */ +/* */ +/* Contributors Listed Below - COPYRIGHT 2019 */ +/* [+] International Business Machines Corp. */ +/* */ +/* */ +/* Licensed under the Apache License, Version 2.0 (the "License"); */ +/* you may not use this file except in compliance with the License. */ +/* You may obtain a copy of the License at */ +/* */ +/* http://www.apache.org/licenses/LICENSE-2.0 */ +/* */ +/* Unless required by applicable law or agreed to in writing, software */ +/* distributed under the License is distributed on an "AS IS" BASIS, */ +/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or */ +/* implied. See the License for the specific language governing */ +/* permissions and limitations under the License. */ +/* */ +/* IBM_PROLOG_END_TAG */ +/** + * @file bpmreasoncode.H + * + * @brief Reason codes and module ids for the BPM + */ +#ifndef __BPMREASONCODES_H +#define __BPMREASONCODES_H + +#include + +namespace BPM_RC +{ + + enum bpmModuleId + { + BPM_ISSUE_COMMAND = 0x00, + BPM_IN_UPDATE_MODE = 0x01, + BPM_UPDATE_FIRMWARE = 0x02, + BPM_ENTER_BSL_MODE = 0x03, + BPM_SETUP_PAYLOAD = 0x04, + BPM_DUMP_SEGMENT = 0x05, + BPM_DISABLE_WRITE_PROTECTION = 0x06, + BPM_WRITE_MAGIC_REG = 0x07, + BPM_GET_RESPONSE = 0x08, + BPM_RETRY_BLOCK_WRITE = 0x09, + BPM_WAIT_FOR_CMD_BIT_RESET = 0x0A, + BPM_WAIT_FOR_BUSY_BIT_RESET = 0x0B, + BPM_CHECK_FIRMWARE_CRC = 0x0C, + BPM_DUMMY_ERROR = 0xFF, + }; + + enum bpmReasonCode + { + BPM_INVALID_PAYLOAD_SIZE = BPM_COMP_ID | 0x00, + BPM_UPDATE_MODE_VERIFICATION_FAIL = BPM_COMP_ID | 0x01, + BPM_RESET_VECTOR_NEVER_RECEIVED = BPM_COMP_ID | 0x02, + BPM_FAILED_TO_ENTER_BSL_MODE = BPM_COMP_ID | 0x03, + BPM_INVALID_PAYLOAD_DATA_SIZE = BPM_COMP_ID | 0x04, + BPM_BSL_MODE_ENABLED = BPM_COMP_ID | 0x05, + BPM_DISABLE_WRITE_PROTECTION_FAILED = BPM_COMP_ID | 0x06, + BPM_WRITE_TO_MAGIC_REG_FAILED = BPM_COMP_ID | 0x07, + BPM_RESPONSE_CRC_MISMATCH = BPM_COMP_ID | 0x08, + BPM_EXCEEDED_RETRY_LIMIT = BPM_COMP_ID | 0x09, + BPM_CMD_STATUS_ERROR_BIT_SET = BPM_COMP_ID | 0x0A, + BPM_FIRMWARE_CRC_VERIFY_FAILURE = BPM_COMP_ID | 0x0B, + BPM_DUMMY_REASONCODE = BPM_COMP_ID | 0xFF, + }; + +}; + + +#endif -- cgit v1.2.1