diff --git a/cmake/sysbuild/partition_manager.cmake b/cmake/sysbuild/partition_manager.cmake index 6947138418af..6f6c88fd71b4 100644 --- a/cmake/sysbuild/partition_manager.cmake +++ b/cmake/sysbuild/partition_manager.cmake @@ -179,6 +179,13 @@ function(partition_manager) else() set(part "${DEFAULT_IMAGE}") endif() + elseif(${part} STREQUAL "provision") + # Adjust provision name for domain + if("${PM_DOMAIN}" STREQUAL "CPUNET") + set(part "net_${part}") + else() + set(part "app_${part}") + endif() endif() string(TOUPPER ${part} PART) get_property(${part}_PM_HEX_FILE GLOBAL PROPERTY ${part}_PM_HEX_FILE) diff --git a/sysbuild/Kconfig.secureboot b/sysbuild/Kconfig.secureboot index 8186bab932ee..84de6f358a03 100644 --- a/sysbuild/Kconfig.secureboot +++ b/sysbuild/Kconfig.secureboot @@ -29,27 +29,28 @@ config SECURE_BOOT_NETCORE #endchoice -config SECURE_BOOT_IMAGE_NAME - string - default "b0n" if SECURE_BOOT_NETCORE - default "b0" - help - Internal build system name of secure bootloader image. +#config SECURE_BOOT_IMAGE_NAME +# string +# default "b0n" if SECURE_BOOT_NETCORE +# default "b0" +# help +# Internal build system name of secure bootloader image. -config SECURE_BOOT_BOARD +config SECURE_BOOT_NETWORK_BOARD string default "nrf5340dk_nrf5340_cpunet" if SECURE_BOOT_NETCORE && ($(BOARD) = "nrf5340dk_nrf5340_cpuapp" || $(BOARD) = "nrf5340dk_nrf5340_cpuapp_ns") default "thingy53_nrf5340_cpunet" if SECURE_BOOT_NETCORE && ($(BOARD) = "thingy53_nrf5340_cpuapp" || $(BOARD) = "thingy53_nrf5340_cpuapp_ns") + depends on SECURE_BOOT_NETCORE help Remote board when building this sample. If not set, the board given to sysbuild is used. -config SECURE_BOOT_DOMAIN - string - default "CPUNET" if SECURE_BOOT_NETCORE - default "APP" - help - Internal build system domain name used for first stage bootloader. +#config SECURE_BOOT_DOMAIN +# string +# default "CPUNET" if SECURE_BOOT_NETCORE +# default "APP" +# help +# Internal build system domain name used for first stage bootloader. config SECURE_BOOT_BUILD_S1_VARIANT_IMAGE # bool "Build S1 variant image" # Possibly support disabling this in future diff --git a/sysbuild/secureboot.cmake b/sysbuild/secureboot.cmake index 068758e420f4..d7c684ffb0a9 100644 --- a/sysbuild/secureboot.cmake +++ b/sysbuild/secureboot.cmake @@ -9,11 +9,10 @@ if(SB_CONFIG_SECURE_BOOT) set(secure_boot_source_dir ${ZEPHYR_NRF_MODULE_DIR}/samples/nrf5340/netboot) ExternalZephyrProject_Add( -# APPLICATION ${SB_CONFIG_SECURE_BOOT_IMAGE_NAME} APPLICATION b0n # ToDo: which sample is used as secure boot sample in other cases ? SOURCE_DIR ${secure_boot_source_dir} - BOARD ${SB_CONFIG_SECURE_BOOT_BOARD} + BOARD ${SB_CONFIG_SECURE_BOOT_NETWORK_BOARD} BUILD_ONLY true ) set_target_properties(${SB_CONFIG_SECURE_BOOT_IMAGE_NAME} PROPERTIES @@ -45,7 +44,6 @@ endif() set(secure_boot_source_dir ${ZEPHYR_NRF_MODULE_DIR}/samples/bootloader) ExternalZephyrProject_Add( -# APPLICATION ${SB_CONFIG_SECURE_BOOT_IMAGE_NAME} APPLICATION b0 # ToDo: which sample is used as secure boot sample in other cases ? SOURCE_DIR ${secure_boot_source_dir} @@ -88,7 +86,7 @@ endif() endif() set_property(GLOBAL APPEND PROPERTY - PM_${SB_CONFIG_SECURE_BOOT_DOMAIN}_IMAGES + PM_APP_IMAGES "${image}" ) endif()