mirror of
https://github.com/espressif/ESP8266_RTOS_SDK.git
synced 2025-12-15 10:17:49 +08:00
fix(spi_flash): Fix no exit critical after enter critical
This commit is contained in:
@@ -287,10 +287,14 @@ static esp_err_t IRAM_ATTR spi_flash_write_status(uint32_t status_value)
|
|||||||
Cache_Read_Disable_2();
|
Cache_Read_Disable_2();
|
||||||
|
|
||||||
Wait_SPI_Idle(&flashchip);
|
Wait_SPI_Idle(&flashchip);
|
||||||
if(ESP_OK != SPI_write_enable(&flashchip))
|
if(ESP_OK != SPI_write_enable(&flashchip)){
|
||||||
|
FLASH_INTR_UNLOCK(c_tmp);
|
||||||
return ESP_ERR_FLASH_OP_FAIL;
|
return ESP_ERR_FLASH_OP_FAIL;
|
||||||
if(ESP_OK != SPI_write_status(&flashchip,status_value))
|
}
|
||||||
|
if(ESP_OK != SPI_write_status(&flashchip,status_value)){
|
||||||
|
FLASH_INTR_UNLOCK(c_tmp);
|
||||||
return ESP_ERR_FLASH_OP_FAIL;
|
return ESP_ERR_FLASH_OP_FAIL;
|
||||||
|
}
|
||||||
Wait_SPI_Idle(&flashchip);
|
Wait_SPI_Idle(&flashchip);
|
||||||
|
|
||||||
Cache_Read_Enable_2();
|
Cache_Read_Enable_2();
|
||||||
|
|||||||
Reference in New Issue
Block a user