Skip to content

Commit 9f7ec60

Browse files
nordicjmbjarki-andreasen
authored andcommitted
[nrf noup] zephyr: Add RAM flash configuration to cache for sysbuild
Puts the flash simulation configurtion into cache variables that can be used by other applications and CMake code to know specifics on the simulated flash details Signed-off-by: Jamie McCrae <[email protected]> (cherry picked from commit af27205)
1 parent 68339ee commit 9f7ec60

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

boot/zephyr/CMakeLists.txt

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -581,3 +581,14 @@ zephyr_library_sources(
581581
${BOOT_DIR}/zephyr/nrf_cleanup.c
582582
)
583583
endif()
584+
585+
if(SYSBUILD AND CONFIG_PCD_APP)
586+
# Sysbuild requires details of the RAM flash device are stored to the cache of MCUboot so
587+
# that they can be read when running partition manager
588+
dt_nodelabel(ram_flash_dev NODELABEL flash_sim0)
589+
dt_reg_addr(ram_flash_addr PATH ${ram_flash_dev})
590+
dt_reg_size(ram_flash_size PATH ${ram_flash_dev})
591+
592+
set(RAM_FLASH_ADDR "${ram_flash_addr}" CACHE STRING "" FORCE)
593+
set(RAM_FLASH_SIZE "${ram_flash_size}" CACHE STRING "" FORCE)
594+
endif()

0 commit comments

Comments
 (0)