Commit 6439c0c1 authored by Daniel DeGrasse's avatar Daniel DeGrasse Committed by Fabio Baltieri
Browse files

cmake: mcuboot: prefer confirmed image when one is created



Prefer flashing the confirmed image when one is created with
CONFIG_MCUBOOT_GENERATE_CONFIRMED_IMAGE. This way, the west runner will
flash this image over the signed image if it exists.

Signed-off-by: default avatarDaniel DeGrasse <ddegrasse@tenstorrent.com>
parent 77e592c6
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -186,6 +186,7 @@ function(zephyr_mcuboot_tasks)
      set_property(GLOBAL APPEND PROPERTY extra_post_build_commands COMMAND
                   ${imgtool_sign} ${imgtool_args} --pad --confirm ${output}.bin
                   ${output}.signed.confirmed.bin)
      zephyr_runner_file(bin ${output}.signed.confirmed.bin)
    endif()

    if(NOT "${keyfile_enc}" STREQUAL "")
@@ -249,6 +250,7 @@ function(zephyr_mcuboot_tasks)
      set_property(GLOBAL APPEND PROPERTY extra_post_build_commands COMMAND
                   ${imgtool_sign} ${imgtool_args} --pad --confirm ${output}.hex
                   ${output}.signed.confirmed.hex)
      zephyr_runner_file(hex ${output}.signed.confirmed.hex)
    endif()

    if(NOT "${keyfile_enc}" STREQUAL "")