Skip to content

Commit 3145152

Browse files
michalek-nonordic-piks
authored andcommitted
samples: smp_svr: nrf54lx support
adds nrf54l series to sample. Signed-off-by: Mateusz Michalek <[email protected]>
1 parent b45d4d1 commit 3145152

28 files changed

+1016
-8
lines changed
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
/ {
2+
chosen {
3+
nordic,pm-ext-flash = &mx25r64;
4+
};
5+
};
6+
7+
/delete-node/ &boot_partition;
8+
/delete-node/ &slot0_partition;
9+
/delete-node/ &slot1_partition;
10+
/delete-node/ &storage_partition;
11+
12+
&cpuapp_rram {
13+
reg = <0x0 DT_SIZE_K(1524)>;
14+
15+
partitions {
16+
boot_partition: partition@0 {
17+
label = "mcuboot";
18+
reg = <0x000000000 0x00014000>;
19+
};
20+
21+
slot0_partition: partition@14000 {
22+
label = "image-0";
23+
reg = <0x000014000 0x0015A000>;
24+
};
25+
26+
storage_partition: partition@16E000 {
27+
label = "storage";
28+
reg = < 0x16E000 0x9000 >;
29+
};
30+
};
31+
};
32+
33+
&mx25r64 {
34+
status = "okay";
35+
36+
partitions {
37+
compatible = "fixed-partitions";
38+
#address-cells = <1>;
39+
#size-cells = <1>;
40+
41+
slot1_partition: partition@0 {
42+
label = "image-1";
43+
reg = <0x000000000 0x0015A000>;
44+
};
45+
};
46+
};
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
/ {
2+
chosen {
3+
nordic,pm-ext-flash = &mx25r64;
4+
};
5+
};
6+
7+
/delete-node/ &boot_partition;
8+
/delete-node/ &slot0_partition;
9+
/delete-node/ &slot1_partition;
10+
/delete-node/ &storage_partition;
11+
12+
&cpuapp_rram {
13+
reg = <0x0 DT_SIZE_K(1524)>;
14+
15+
partitions {
16+
boot_partition: partition@0 {
17+
label = "mcuboot";
18+
reg = <0x000000000 0x00014000>;
19+
};
20+
21+
slot0_partition: partition@14000 {
22+
label = "image-0";
23+
reg = <0x000014000 0x0015A000>;
24+
};
25+
26+
storage_partition: partition@16E000 {
27+
label = "storage";
28+
reg = < 0x16E000 0x9000 >;
29+
};
30+
};
31+
};
32+
33+
&mx25r64 {
34+
status = "okay";
35+
36+
partitions {
37+
compatible = "fixed-partitions";
38+
#address-cells = <1>;
39+
#size-cells = <1>;
40+
41+
slot1_partition: partition@0 {
42+
label = "image-1";
43+
reg = <0x000000000 0x0015A000>;
44+
};
45+
};
46+
};

samples/zephyr/subsys/mgmt/mcumgr/smp_svr/sample.yaml

Lines changed: 198 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,203 @@ common:
1717
- ci_samples_zephyr_subsys_mgmt_mcumgr_smp_svr
1818

1919
tests:
20+
sample.mcumgr.smp_svr.basic:
21+
platform_allow:
22+
- nrf52840dk/nrf52840
23+
- nrf5340dk/nrf5340/cpuapp
24+
- nrf9160dk/nrf9160
25+
- nrf54l15dk/nrf54l15/cpuapp
26+
- nrf54l15dk/nrf54l10/cpuapp
27+
- nrf54l15dk/nrf54l05/cpuapp
28+
- nrf54h20dk/nrf54h20/cpuapp
29+
- nrf54lm20dk/nrf54lm20a/cpuapp
30+
- nrf54lv10dk/nrf54lv10a/cpuapp
31+
extra_args:
32+
- mcuboot_CONFIG_MCUBOOT_DOWNGRADE_PREVENTION=y
33+
sample.mcumgr.smp_svr.encryption.rsa:
34+
platform_allow:
35+
- nrf52840dk/nrf52840
36+
- nrf5340dk/nrf5340/cpuapp
37+
- nrf54l15dk/nrf54l15/cpuapp
38+
- nrf54lm20dk/nrf54lm20a/cpuapp
39+
- nrf54lv10dk/nrf54lv10a/cpuapp
40+
tags:
41+
- encryption
42+
extra_args:
43+
- SB_CONFIG_BOOT_ENCRYPTION=y
44+
- SB_CONFIG_BOOT_SIGNATURE_TYPE_RSA=y
45+
- mcuboot_CONFIG_MCUBOOT_DOWNGRADE_PREVENTION=y
46+
- FILE_SUFFIX=larger_mcuboot
47+
48+
sample.mcumgr.smp_svr.encryption.ecdsa_p256:
49+
platform_allow:
50+
- nrf5340dk/nrf5340/cpuapp
51+
- nrf54l15dk/nrf54l15/cpuapp
52+
- nrf54h20dk/nrf54h20/cpuapp
53+
- nrf54lm20dk/nrf54lm20a/cpuapp
54+
- nrf54lv10dk/nrf54lv10a/cpuapp
55+
tags:
56+
- encryption
57+
extra_args:
58+
- SB_CONFIG_BOOT_ENCRYPTION=y
59+
- SB_CONFIG_BOOT_SIGNATURE_TYPE_ECDSA_P256=y
60+
- FILE_SUFFIX=larger_mcuboot
61+
62+
sample.mcumgr.smp_svr.encryption.ed25519:
63+
platform_allow:
64+
- nrf52840dk/nrf52840
65+
- nrf5340dk/nrf5340/cpuapp
66+
- nrf54l15dk/nrf54l15/cpuapp
67+
- nrf54lm20dk/nrf54lm20a/cpuapp
68+
- nrf54lv10dk/nrf54lv10a/cpuapp
69+
tags:
70+
- encryption
71+
extra_args:
72+
- FILE_SUFFIX=larger_mcuboot
73+
- SB_CONFIG_BOOT_ENCRYPTION=y
74+
- SB_CONFIG_BOOT_SIGNATURE_TYPE_ED25519=y
75+
76+
sample.mcumgr.smp_svr.signature.none:
77+
platform_allow:
78+
- nrf52840dk/nrf52840
79+
- nrf5340dk/nrf5340/cpuapp
80+
- nrf54l15dk/nrf54l15/cpuapp
81+
- nrf54h20dk/nrf54h20/cpuapp
82+
- nrf54lm20dk/nrf54lm20a/cpuapp
83+
- nrf54lv10dk/nrf54lv10a/cpuapp
84+
tags:
85+
- signature
86+
extra_args:
87+
- SB_CONFIG_BOOT_SIGNATURE_TYPE_NONE=y
88+
89+
sample.mcumgr.smp_svr.signature.ed25519:
90+
platform_allow:
91+
- nrf54l15dk/nrf54l15/cpuapp
92+
- nrf54lm20dk/nrf54lm20a/cpuapp
93+
- nrf54lv10dk/nrf54lv10a/cpuapp
94+
- nrf54h20dk/nrf54h20/cpuapp
95+
tags:
96+
- signature
97+
extra_args:
98+
- SB_CONFIG_BOOT_SIGNATURE_TYPE_ED25519=y
99+
100+
sample.mcumgr.smp_svr.signature.ecdsa_p256:
101+
platform_allow:
102+
- nrf54h20dk/nrf54h20/cpuapp
103+
tags:
104+
- signature
105+
extra_args:
106+
- SB_CONFIG_BOOT_SIGNATURE_TYPE_ECDSA_P256=y
107+
108+
sample.mcumgr.smp_svr.signature.pure:
109+
platform_allow:
110+
- nrf54l15dk/nrf54l15/cpuapp
111+
- nrf54h20dk/nrf54h20/cpuapp
112+
tags:
113+
- signature
114+
extra_args:
115+
- SB_CONFIG_BOOT_SIGNATURE_TYPE_ED25519=y
116+
- SB_CONFIG_BOOT_SIGNATURE_TYPE_PURE=y
117+
118+
sample.mcumgr.smp_svr.kmu.basic:
119+
platform_allow:
120+
- nrf54l15dk/nrf54l15/cpuapp
121+
- nrf54l15dk/nrf54l10/cpuapp
122+
- nrf54l15dk/nrf54l05/cpuapp
123+
- nrf54lm20dk/nrf54lm20a/cpuapp
124+
- nrf54lv10dk/nrf54lv10a/cpuapp
125+
tags: kmu
126+
extra_args:
127+
- SB_CONFIG_MCUBOOT_SIGNATURE_USING_KMU=y
128+
- SB_CONFIG_BOOT_SIGNATURE_TYPE_ED25519=y
129+
nsib.sample.mcumgr.smp_svr.kmu.basic:
130+
platform_allow:
131+
- nrf54l15dk/nrf54l15/cpuapp
132+
- nrf54lm20dk/nrf54lm20a/cpuapp
133+
- nrf54lv10dk/nrf54lv10a/cpuapp
134+
tags:
135+
- kmu
136+
- nsib
137+
extra_args:
138+
- SB_CONFIG_SECURE_BOOT_APPCORE=y
139+
- SB_CONFIG_MCUBOOT_SIGNATURE_USING_KMU=y
140+
- SB_CONFIG_BOOT_SIGNATURE_TYPE_ED25519=y
141+
142+
sample.mcumgr.smp_svr.kmu.revocation:
143+
platform_allow:
144+
- nrf54l15dk/nrf54l15/cpuapp
145+
- nrf54lm20dk/nrf54lm20a/cpuapp
146+
- nrf54lv10dk/nrf54lv10a/cpuapp
147+
tags: kmu
148+
extra_args:
149+
- SB_CONFIG_MCUBOOT_SIGNATURE_USING_KMU=y
150+
- SB_CONFIG_BOOT_SIGNATURE_TYPE_ED25519=y
151+
- mcuboot_CONFIG_BOOT_SIGNATURE_KMU_SLOTS=3
152+
- mcuboot_CONFIG_BOOT_KEYS_REVOCATION=y
153+
154+
sample.mcumgr.smp_svr.nrf_compress.basic:
155+
tags:
156+
- nrf_compress
157+
platform_allow:
158+
- nrf52840dk/nrf52840
159+
- nrf5340dk/nrf5340/cpuapp
160+
- nrf54l15dk/nrf54l15/cpuapp
161+
- nrf54h20dk/nrf54h20/cpuapp
162+
- nrf54lm20dk/nrf54lm20a/cpuapp
163+
- nrf54lv10dk/nrf54lv10a/cpuapp
164+
extra_args:
165+
- SB_CONFIG_MCUBOOT_MODE_OVERWRITE_ONLY=y
166+
- SB_CONFIG_MCUBOOT_COMPRESSED_IMAGE_SUPPORT=y
167+
- FILE_SUFFIX=larger_mcuboot
168+
169+
sample.mcumgr.smp_svr.nrf_compress.encryption_rsa:
170+
platform_allow:
171+
- nrf52840dk/nrf52840
172+
- nrf5340dk/nrf5340/cpuapp
173+
tags:
174+
- encryption
175+
- nrf_compress
176+
extra_args:
177+
- SB_CONFIG_MCUBOOT_MODE_OVERWRITE_ONLY=y
178+
- SB_CONFIG_MCUBOOT_COMPRESSED_IMAGE_SUPPORT=y
179+
- SB_CONFIG_BOOT_ENCRYPTION=y
180+
- SB_CONFIG_BOOT_SIGNATURE_TYPE_RSA=y
181+
- FILE_SUFFIX=larger_mcuboot
182+
183+
sample.mcumgr.smp_svr.nrf_compress.encryption_ecdsa_p256:
184+
platform_allow:
185+
- nrf5340dk/nrf5340/cpuapp
186+
- nrf54l15dk/nrf54l15/cpuapp
187+
- nrf54h20dk/nrf54h20/cpuapp
188+
- nrf54lm20dk/nrf54lm20a/cpuapp
189+
- nrf54lv10dk/nrf54lv10a/cpuapp
190+
tags:
191+
- encryption
192+
- nrf_compress
193+
extra_args:
194+
- SB_CONFIG_MCUBOOT_MODE_OVERWRITE_ONLY=y
195+
- SB_CONFIG_MCUBOOT_COMPRESSED_IMAGE_SUPPORT=y
196+
- SB_CONFIG_BOOT_ENCRYPTION=y
197+
- SB_CONFIG_BOOT_SIGNATURE_TYPE_ECDSA_P256=y
198+
- FILE_SUFFIX=larger_mcuboot
199+
200+
sample.mcumgr.smp_svr.nrf_compress.encryption_ed25519:
201+
platform_allow:
202+
- nrf52840dk/nrf52840
203+
- nrf5340dk/nrf5340/cpuapp
204+
- nrf54l15dk/nrf54l15/cpuapp
205+
- nrf54lm20dk/nrf54lm20a/cpuapp
206+
- nrf54lv10dk/nrf54lv10a/cpuapp
207+
tags:
208+
- encryption
209+
- nrf_compress
210+
extra_args:
211+
- SB_CONFIG_MCUBOOT_MODE_OVERWRITE_ONLY=y
212+
- SB_CONFIG_MCUBOOT_COMPRESSED_IMAGE_SUPPORT=y
213+
- SB_CONFIG_BOOT_ENCRYPTION=y
214+
- SB_CONFIG_BOOT_SIGNATURE_TYPE_ED25519=y
215+
- FILE_SUFFIX=larger_mcuboot
216+
20217
sample.mcumgr.smp_svr.bt.nrf5340dk.ext_flash:
21218
sysbuild: true
22219
extra_args:
@@ -37,9 +234,8 @@ tests:
37234
sample.mcumgr.smp_svr.bt.nrf54l15dk.ext_flash:
38235
extra_args:
39236
- OVERLAY_CONFIG="overlay-bt.conf"
237+
- FILE_SUFFIX=ext_flash
40238
- DTC_OVERLAY_FILE="boards/nrf54l15dk_ext_flash.overlay"
41-
- mcuboot_OVERLAY_CONFIG="boards/nrf54l15dk_ext_flash.conf"
42-
- mcuboot_EXTRA_DTC_OVERLAY_FILE="boards/nrf54l15dk_ext_flash.overlay"
43239
- SB_CONFIG_PM_OVERRIDE_EXTERNAL_DRIVER_CHECK=y
44240
- SB_CONFIG_PM_EXTERNAL_FLASH_MCUBOOT_SECONDARY=y
45241
platform_allow:

samples/zephyr/subsys/mgmt/mcumgr/smp_svr/sysbuild/mcuboot.conf

Lines changed: 0 additions & 6 deletions
This file was deleted.
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# MCUboot requires a large stack size, otherwise an MPU fault will occur
2+
CONFIG_MAIN_STACK_SIZE=16384
3+
4+
# Enable flash operations
5+
CONFIG_FLASH=y
6+
7+
CONFIG_BOOT_MAX_IMG_SECTORS=256
8+
9+
CONFIG_MULTITHREADING=y
10+
11+
CONFIG_LOG=y
12+
CONFIG_LOG_MODE_MINIMAL=y
13+
CONFIG_LOG_DEFAULT_LEVEL=0
14+
CONFIG_MCUBOOT_LOG_LEVEL_INF=y
15+
# Decrease footprint by ~4 KB in comparison to CBPRINTF_COMPLETE=y
16+
CONFIG_CBPRINTF_NANO=y
17+
# Use minimal C library instead of the Picolib
18+
CONFIG_MINIMAL_LIBC=y
19+
20+
CONFIG_FW_INFO_FIRMWARE_VERSION=2
21+
22+
# NCS boot banner
23+
CONFIG_NCS_APPLICATION_BOOT_BANNER_STRING="MCUboot"
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
CONFIG_PM_PARTITION_SIZE_MCUBOOT=0x13e00
2+
# MCUboot requires a large stack size, otherwise an MPU fault will occur
3+
CONFIG_MAIN_STACK_SIZE=16384
4+
5+
# Enable flash operations
6+
CONFIG_FLASH=y
7+
8+
CONFIG_BOOT_MAX_IMG_SECTORS=256
9+
10+
CONFIG_MULTITHREADING=y
11+
12+
CONFIG_LOG=y
13+
CONFIG_LOG_MODE_MINIMAL=y
14+
CONFIG_LOG_DEFAULT_LEVEL=0
15+
CONFIG_MCUBOOT_LOG_LEVEL_INF=y
16+
# Decrease footprint by ~4 KB in comparison to CBPRINTF_COMPLETE=y
17+
CONFIG_CBPRINTF_NANO=y
18+
# Use minimal C library instead of the Picolib
19+
CONFIG_MINIMAL_LIBC=y
20+
21+
CONFIG_FW_INFO_FIRMWARE_VERSION=2
22+
23+
# NCS boot banner
24+
CONFIG_NCS_APPLICATION_BOOT_BANNER_STRING="MCUboot"
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# MCUboot requires a large stack size, otherwise an MPU fault will occur
2+
CONFIG_MAIN_STACK_SIZE=16384
3+
4+
# Enable flash operations
5+
CONFIG_FLASH=y
6+
7+
CONFIG_BOOT_MAX_IMG_SECTORS=256
8+
9+
CONFIG_MULTITHREADING=y
10+
11+
CONFIG_LOG=y
12+
CONFIG_LOG_MODE_MINIMAL=y
13+
CONFIG_LOG_DEFAULT_LEVEL=0
14+
CONFIG_MCUBOOT_LOG_LEVEL_INF=y
15+
# Decrease footprint by ~4 KB in comparison to CBPRINTF_COMPLETE=y
16+
CONFIG_CBPRINTF_NANO=y
17+
# Use minimal C library instead of the Picolib
18+
CONFIG_MINIMAL_LIBC=y
19+
20+
CONFIG_FW_INFO_FIRMWARE_VERSION=2
21+
22+
# NCS boot banner
23+
CONFIG_NCS_APPLICATION_BOOT_BANNER_STRING="MCUboot"

0 commit comments

Comments
 (0)