Skip to content

Commit 90a91e0

Browse files
nordicjmjfischer-no
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]> Signed-off-by: Dominik Ermel <[email protected]> (cherry picked from commit c19337f)
1 parent 8e373cc commit 90a91e0

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
@@ -362,3 +362,14 @@ zephyr_library_sources(
362362
${BOOT_DIR}/zephyr/nrf_cleanup.c
363363
)
364364
endif()
365+
366+
if(SYSBUILD AND CONFIG_PCD_APP)
367+
# Sysbuild requires details of the RAM flash device are stored to the cache of MCUboot so
368+
# that they can be read when running partition manager
369+
dt_nodelabel(ram_flash_dev NODELABEL flash_sim0)
370+
dt_reg_addr(ram_flash_addr PATH ${ram_flash_dev})
371+
dt_reg_size(ram_flash_size PATH ${ram_flash_dev})
372+
373+
set(RAM_FLASH_ADDR "${ram_flash_addr}" CACHE STRING "" FORCE)
374+
set(RAM_FLASH_SIZE "${ram_flash_size}" CACHE STRING "" FORCE)
375+
endif()

0 commit comments

Comments
 (0)