Skip to content

Commit 2184344

Browse files
nordic-mik7rlubos
authored andcommitted
samples: zephyr: smp_svr_mini_boot: Add 'swap using move' config
This commit adds a new sample configuration for the SMP server mini boot sample that uses the swap using move mode of MCUboot. This configuration is useful for testing and demonstrating the functionality of the swap using move feature in a minimal setup. Documentation has been updated with instructions on how to build the sample with direct-xip mode or swap using move mode. Signed-off-by: Michal Kozikowski <[email protected]>
1 parent ad0f918 commit 2184344

File tree

3 files changed

+17
-2
lines changed

3 files changed

+17
-2
lines changed

samples/zephyr/smp_svr_mini_boot/README.rst

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,12 @@ Overview
1414

1515
This sample shows how to configure MCUboot for secure boot and Device Firmware Update (DFU) capabilities using the Zephyr RTOS.
1616
The MCUboot is configured to utilize hardware cryptography with the :ref:`ED25519 signature <ug_nrf54l_cryptography>`. Additionally, for nRF54L15 DK :ref:`Key Management Unit (KMU) <ug_nrf54l_developing_basics_kmu>` for secure key storage is used.
17-
The setup uses LTO, direct-xip mode and disables non-essential functionalities to downsize the MCUboot non-volatile memory footprint.
17+
The setup uses LTO and disables non-essential functionalities to downsize the MCUboot non-volatile memory footprint.
1818

1919
The SMP server sample is configured to support Bluetooth® LE and shell for the MCUmgr protocol, which facilitates image management and OS commands.
2020

21+
To achieve minimal size, direct-xip mode can be used, though you can build the sample with the swap using move mode as well.
22+
2123
Requirements
2224
************
2325

@@ -34,6 +36,9 @@ Building and running
3436

3537
For nRF54L15 DK, make sure you are building your project with the ``SB_CONFIG_MCUBOOT_GENERATE_DEFAULT_KMU_KEYFILE`` Kconfig option enabled.
3638

39+
For direct-xip mode, you must build the sample with the ``SB_CONFIG_MCUBOOT_MODE_DIRECT_XIP`` Kconfig option enabled.
40+
For swap using move mode, use the ``SB_CONFIG_MCUBOOT_MODE_SWAP_USING_MOVE`` Kconfig option instead.
41+
3742
You will notice that the size of MCUboot is significantly reduced in comparison to the default configuration.
3843

3944
If you are using command line, you must run the ``west flash --erase`` command to enable KMU provisioning.

samples/zephyr/smp_svr_mini_boot/sample.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,17 @@ common:
1212
- "smp_sample: build time:"
1313
tests:
1414
sample.smp_svr_mini_boot:
15+
extra_args:
16+
- SB_CONFIG_MCUBOOT_MODE_DIRECT_XIP=y
17+
platform_allow:
18+
- nrf54l15dk/nrf54l15/cpuapp
19+
- nrf54h20dk/nrf54h20/cpuapp
20+
integration_platforms:
21+
- nrf54l15dk/nrf54l15/cpuapp
22+
- nrf54h20dk/nrf54h20/cpuapp
23+
sample.smp_svr_mini_boot.swap_move:
24+
extra_args:
25+
- SB_CONFIG_MCUBOOT_MODE_SWAP_USING_MOVE=y
1526
platform_allow:
1627
- nrf54l15dk/nrf54l15/cpuapp
1728
- nrf54h20dk/nrf54h20/cpuapp
Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
# Enable MCUboot bootloader support
22
SB_CONFIG_BOOTLOADER_MCUBOOT=y
3-
SB_CONFIG_MCUBOOT_MODE_DIRECT_XIP=y
43
SB_CONFIG_BOOT_SIGNATURE_TYPE_ED25519=y
54
SB_CONFIG_BOOT_SIGNATURE_TYPE_PURE=y

0 commit comments

Comments
 (0)