Skip to content

Commit cd002af

Browse files
de-nordiccarlescufi
authored andcommitted
[nrf fromlist] mgmt/mcumgr: Add Kconfig option to select number ...
... of supported images The commit adds IMG_MGMT_UPDATABLE_IMAGE_NUMBER Kconfig option, int, that allows to select how many images are supported by mcumgr. Signed-off-by: Dominik Ermel <[email protected]>
1 parent 38a185a commit cd002af

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

subsys/mgmt/mcumgr/Kconfig

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,17 @@ config IMG_MGMT_UL_CHUNK_SIZE
156156
this size gets allocated on the stack during handling of a image upload
157157
command.
158158

159+
config IMG_MGMT_UPDATABLE_IMAGE_NUMBER
160+
int "Number of supported images"
161+
default UPDATEABLE_IMAGE_NUMBER
162+
range 1 2
163+
help
164+
Sets how many application images are supported (pairs of secondary and primary slots).
165+
Setting this to 2 requires MCUMGR_BUF_SIZE to be at least 512b.
166+
NOTE: The UPDATEABLE_IMAGE_NUMBER of MCUBOOT configuration, even for Zephyr build,
167+
needs to be set to the same value; this is due to the fact that the mcumgr uses
168+
boot_util and the UPDATEABLE_IMAGE_NUMBER controls number of images supported
169+
by that library.
159170

160171
config IMG_MGMT_VERBOSE_ERR
161172
bool "Verbose logging when uploading a new image"

0 commit comments

Comments
 (0)