spi_flash: Add auto-suspend mode for ESP32-S2

Uses HW auto_wait_idle, HW auto_suspend and SW resume
This commit is contained in:
KonstantinKondrashov
2020-05-10 17:32:07 +08:00
committed by Cao Sen Miao
parent afef16c2e9
commit 60e58eaddb
5 changed files with 21 additions and 0 deletions

View File

@@ -173,6 +173,9 @@ bool esp_flash_chip_driver_initialized(const esp_flash_t *chip)
return true;
}
#ifdef CONFIG_SPI_FLASH_AUTO_SUSPEND
spi_flash_ll_auto_suspend_init(spi_flash_ll_get_hw(SPI_HOST), val);
#endif
esp_err_t IRAM_ATTR esp_flash_init(esp_flash_t *chip)
{
// Chip init flow