Skip to content

Commit 3bb3be2

Browse files
committed
modules: mcuboot: Add Kconfig option for BOOT_MAX_ALIGN
Add a configuration option to override the default BOOT_MAX_ALIGN value in mcuboot. It defaults to the chosen flash's write block size to make it backwards compatible. This can be used when image slots are on different flash devices. Signed-off-by: Pieter De Gendt <[email protected]>
1 parent d1e1e52 commit 3bb3be2

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

modules/Kconfig.mcuboot

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -430,4 +430,14 @@ config MCUBOOT_BOOTUTIL_LIB_FOR_DIRECT_XIP
430430
when bootloader is in DirectXIP-revert mode.
431431
endif
432432

433+
DT_CHOSEN_ZEPHYR_FLASH := zephyr,flash
434+
435+
config MCUBOOT_BOOT_MAX_ALIGN
436+
int "Override programmable flash block alignment"
437+
default $(dt_node_int_prop_int,$(DT_CHOSEN_ZEPHYR_FLASH),write-block-size)
438+
help
439+
Allow to override the programmable flash block alignment size.
440+
By default it's set to the maximum of the write block size of
441+
the chosen zephyr,flash node and 8.
442+
433443
endif # MCUBOOT_BOOTUTIL_LIB

0 commit comments

Comments
 (0)