@@ -249,7 +249,8 @@ int QSPIFBlockDevice::init()
249249 // Configure BUS Mode to 1_1_1 for all commands other than Read
250250 if (QSPI_STATUS_OK != _qspi_configure_format (QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
251251 0 , QSPI_CFG_BUS_SINGLE, 0 )) {
252- status = QSPIF_BD_ERROR_CONF_FORMAT_FAILED;
252+ tr_error (" _qspi_configure_format failed" );
253+ status = QSPIF_BD_ERROR_DEVICE_ERROR;
253254 goto exit_point;
254255 }
255256
@@ -308,7 +309,8 @@ int QSPIFBlockDevice::read(void *buffer, bd_addr_t addr, bd_size_t size)
308309 // Configure Bus for Reading
309310 if (QSPI_STATUS_OK != _qspi_configure_format (_inst_width, _address_width, _address_size, _address_width, // Alt width == address width
310311 _alt_size, _data_width, _dummy_cycles)) {
311- return QSPIF_BD_ERROR_CONF_FORMAT_FAILED;
312+ tr_error (" _qspi_configure_format failed" );
313+ return QSPIF_BD_ERROR_DEVICE_ERROR;
312314 }
313315
314316 if (QSPI_STATUS_OK != _qspi_send_read_command (_read_instruction, buffer, addr, size)) {
@@ -318,7 +320,8 @@ int QSPIFBlockDevice::read(void *buffer, bd_addr_t addr, bd_size_t size)
318320
319321 // All commands other than Read use default 1-1-1 Bus mode (Program/Erase are constrained by flash memory performance more than bus performance)
320322 if (QSPI_STATUS_OK != _qspi_configure_format (QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE, 0 , QSPI_CFG_BUS_SINGLE, 0 )) {
321- return QSPIF_BD_ERROR_CONF_FORMAT_FAILED;
323+ tr_error (" _qspi_configure_format failed" );
324+ return QSPIF_BD_ERROR_DEVICE_ERROR;
322325 }
323326
324327 _mutex.unlock ();
@@ -726,6 +729,7 @@ int QSPIFBlockDevice::_sfdp_parse_sfdp_headers(uint32_t &basic_table_addr, size_
726729 // Set 1-1-1 bus mode for SFDP header parsing
727730 if (QSPI_STATUS_OK != _qspi_configure_format (QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
728731 0 , QSPI_CFG_BUS_SINGLE, 8 )) {
732+ tr_error (" _qspi_configure_format failed" );
729733 return -1 ;
730734 }
731735
@@ -895,6 +899,7 @@ int QSPIFBlockDevice::_sfdp_set_quad_enabled(uint8_t *basic_param_table_ptr)
895899 // Configure BUS Mode to 1_1_1 for all commands other than Read
896900 if (QSPI_STATUS_OK != _qspi_configure_format (QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
897901 0 , QSPI_CFG_BUS_SINGLE, 0 )) {
902+ tr_error (" _qspi_configure_format failed" );
898903 return -1 ;
899904 }
900905
@@ -1224,7 +1229,7 @@ int QSPIFBlockDevice::_enable_fast_mdoe()
12241229 if (QSPI_STATUS_OK != _qspi_configure_format (QSPI_CFG_BUS_SINGLE, QSPI_CFG_BUS_SINGLE, QSPI_CFG_ADDR_SIZE_24, QSPI_CFG_BUS_SINGLE,
12251230 0 , QSPI_CFG_BUS_SINGLE, 0 )) {
12261231 tr_error (" _qspi_configure_format failed" );
1227- return QSPIF_BD_ERROR_CONF_FORMAT_FAILED ;
1232+ return QSPIF_BD_ERROR_DEVICE_ERROR ;
12281233 }
12291234
12301235 // Read Status Register
0 commit comments