diff --git a/soc/espressif/common/Kconfig b/soc/espressif/common/Kconfig index ca056ffcb18..5e3a0503d52 100644 --- a/soc/espressif/common/Kconfig +++ b/soc/espressif/common/Kconfig @@ -15,6 +15,15 @@ config ESP32_USE_UNSUPPORTED_REVISION set this option to enable support for them. Note that this is not recommended and may lead to unexpected behavior. +config ESP_SIMPLE_BOOT + bool "Simple Boot method" + default y if !BOOTLOADER_MCUBOOT && !MCUBOOT + help + The Simple Boot is a booting method that doesn't need a 2nd stage bootloader. + Output is a single image that should be flashed at a offset defined by used SOC. + Please note that this method brings the system up with all memories set-up, but + all other features, such as secure boot OTA or slots management are not available. + rsource "Kconfig.spiram" rsource "Kconfig.esptool" rsource "Kconfig.flash" diff --git a/soc/espressif/common/Kconfig.flash b/soc/espressif/common/Kconfig.flash index 6b89e809249..84f565f85aa 100644 --- a/soc/espressif/common/Kconfig.flash +++ b/soc/espressif/common/Kconfig.flash @@ -127,12 +127,4 @@ config SPI_FLASH_HPM_ENABLE This option is invisible, and will be selected automatically when ``ESPTOOLPY_FLASHFREQ_120M`` is selected. -config ESP_SIMPLE_BOOT - bool "Simple Boot method" - default y if !BOOTLOADER_MCUBOOT - help - The Simple Boot is a method of booting that doesn't depend on a - 2nd stage bootloader. Please note that some of the bootloader features - are not available using simple boot, such secure boot and OTA. - endif # SOC_FAMILY_ESPRESSIF_ESP32 diff --git a/soc/espressif/esp32/CMakeLists.txt b/soc/espressif/esp32/CMakeLists.txt index f6f38056a4d..d5373b0b78f 100644 --- a/soc/espressif/esp32/CMakeLists.txt +++ b/soc/espressif/esp32/CMakeLists.txt @@ -69,10 +69,10 @@ else() dt_nodelabel(dts_partition_path NODELABEL "slot0_partition") dt_reg_addr(img_0_off PATH ${dts_partition_path}) - if(CONFIG_ESP_SIMPLE_BOOT) - board_finalize_runner_args(esp32 "--esp-app-address=${boot_off}") - else() + if(CONFIG_BOOTLOADER_MCUBOOT) board_finalize_runner_args(esp32 "--esp-app-address=${img_0_off}") + else() + board_finalize_runner_args(esp32 "--esp-app-address=${boot_off}") endif() endif() diff --git a/soc/espressif/esp32c2/CMakeLists.txt b/soc/espressif/esp32c2/CMakeLists.txt index 7581a7179b5..d8cb333e9d4 100644 --- a/soc/espressif/esp32c2/CMakeLists.txt +++ b/soc/espressif/esp32c2/CMakeLists.txt @@ -53,10 +53,10 @@ dt_prop(monitor_baud PATH ${dts_shell_uart} PROPERTY "current-speed") board_runner_args(esp32 "--esp-flash-freq=60m") board_runner_args(esp32 "--esp-monitor-baud=${monitor_baud}") -if(CONFIG_ESP_SIMPLE_BOOT) - board_finalize_runner_args(esp32 "--esp-app-address=${boot_off}") -else() +if(CONFIG_BOOTLOADER_MCUBOOT) board_finalize_runner_args(esp32 "--esp-app-address=${img_0_off}") +else() + board_finalize_runner_args(esp32 "--esp-app-address=${boot_off}") endif() if(CONFIG_MCUBOOT) diff --git a/soc/espressif/esp32c3/CMakeLists.txt b/soc/espressif/esp32c3/CMakeLists.txt index 75ee06e2a06..80b90a76379 100644 --- a/soc/espressif/esp32c3/CMakeLists.txt +++ b/soc/espressif/esp32c3/CMakeLists.txt @@ -48,10 +48,10 @@ dt_reg_addr(img_0_off PATH ${dts_partition_path}) dt_nodelabel(dts_partition_path NODELABEL "boot_partition") dt_reg_addr(boot_off PATH ${dts_partition_path}) -if(CONFIG_ESP_SIMPLE_BOOT) - board_finalize_runner_args(esp32 "--esp-app-address=${boot_off}") -else() +if(CONFIG_BOOTLOADER_MCUBOOT) board_finalize_runner_args(esp32 "--esp-app-address=${img_0_off}") +else() + board_finalize_runner_args(esp32 "--esp-app-address=${boot_off}") endif() if(CONFIG_MCUBOOT) diff --git a/soc/espressif/esp32c6/CMakeLists.txt b/soc/espressif/esp32c6/CMakeLists.txt index 4e90a854cb0..1bf55e1a315 100644 --- a/soc/espressif/esp32c6/CMakeLists.txt +++ b/soc/espressif/esp32c6/CMakeLists.txt @@ -48,10 +48,10 @@ dt_reg_addr(img_0_off PATH ${dts_partition_path}) dt_nodelabel(dts_partition_path NODELABEL "boot_partition") dt_reg_addr(boot_off PATH ${dts_partition_path}) -if(CONFIG_ESP_SIMPLE_BOOT) - board_finalize_runner_args(esp32 "--esp-app-address=${boot_off}") -else() +if(CONFIG_BOOTLOADER_MCUBOOT) board_finalize_runner_args(esp32 "--esp-app-address=${img_0_off}") +else() + board_finalize_runner_args(esp32 "--esp-app-address=${boot_off}") endif() if(CONFIG_MCUBOOT) diff --git a/soc/espressif/esp32s2/CMakeLists.txt b/soc/espressif/esp32s2/CMakeLists.txt index 77610b2fb0c..d4f6a7c5c94 100644 --- a/soc/espressif/esp32s2/CMakeLists.txt +++ b/soc/espressif/esp32s2/CMakeLists.txt @@ -49,10 +49,10 @@ dt_reg_addr(boot_off PATH ${dts_partition_path}) dt_nodelabel(dts_partition_path NODELABEL "slot0_partition") dt_reg_addr(img_0_off PATH ${dts_partition_path}) -if(CONFIG_ESP_SIMPLE_BOOT) - board_finalize_runner_args(esp32 "--esp-app-address=${boot_off}") -else() +if(CONFIG_BOOTLOADER_MCUBOOT) board_finalize_runner_args(esp32 "--esp-app-address=${img_0_off}") +else() + board_finalize_runner_args(esp32 "--esp-app-address=${boot_off}") endif() if(CONFIG_MCUBOOT) diff --git a/soc/espressif/esp32s3/CMakeLists.txt b/soc/espressif/esp32s3/CMakeLists.txt index d60d8aa6dc8..5f64bd335c2 100644 --- a/soc/espressif/esp32s3/CMakeLists.txt +++ b/soc/espressif/esp32s3/CMakeLists.txt @@ -70,10 +70,10 @@ else() dt_nodelabel(dts_partition_path NODELABEL "slot0_partition") dt_reg_addr(img_0_off PATH ${dts_partition_path}) - if(NOT CONFIG_BOOTLOADER_MCUBOOT) - board_finalize_runner_args(esp32 "--esp-app-address=${boot_off}") - else() + if(CONFIG_BOOTLOADER_MCUBOOT) board_finalize_runner_args(esp32 "--esp-app-address=${img_0_off}") + else() + board_finalize_runner_args(esp32 "--esp-app-address=${boot_off}") endif() endif()