feat(app_update): add API for checking the spi mode compatibility

New API to check the SPI flash mode from the incoming firmware image
during OTA updates could prevent bootloader/app incompatibility of
DIO vs QIO flash modes.

More information:
 - https://github.com/espressif/esp-hosted-mcu/issues/143#issuecomment-3741753788
 - https://github.com/espressif/esp-idf/issues/9674#issuecomment-1232533757
 - https://github.com/espressif/esp-idf/issues/9542#issuecomment-1211317354
This commit is contained in:
Mahavir Jain
2026-01-18 19:01:20 +05:30
parent 1837390102
commit 21f8ca5e6f
11 changed files with 131 additions and 26 deletions
+9
View File
@@ -33,4 +33,13 @@ menu "ESP HTTPS OTA"
This enables use of range header in esp_https_ota component.
The firmware image will be downloaded over multiple HTTP requests.
config ESP_HTTPS_OTA_VERIFY_SPI_MODE
bool "Verify SPI flash mode compatibility for application during OTA"
default y
help
When enabled, the OTA process will verify that the SPI flash mode of the new
application image is compatible with the currently running firmware. This helps
prevent flashing firmware with incompatible SPI mode settings which could
cause flash write failures.
endmenu