Skip to content

Commit 5393df9

Browse files
committed
boards: nrf54h20_iron: Allow radio updates
Add necessary changes to provide a simple, updateable radio image. Ref: NCSDK-33316 Signed-off-by: Tomasz Chyrowicz <[email protected]>
1 parent d07064e commit 5393df9

File tree

7 files changed

+49
-1
lines changed

7 files changed

+49
-1
lines changed

boards/nordic/nrf54h20dk/Kconfig.defconfig

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,3 +27,10 @@ config FLASH_LOAD_OFFSET
2727
default 0x2c000 if !USE_DT_CODE_PARTITION
2828

2929
endif # BOARD_NRF54H20DK_NRF54H20_CPUAPP_IRON
30+
31+
if BOARD_NRF54H20DK_NRF54H20_CPURAD_IRON
32+
33+
config ROM_START_OFFSET
34+
default 0x800 if BOOTLOADER_MCUBOOT
35+
36+
endif # BOARD_NRF54H20DK_NRF54H20_CPURAD_IRON

boards/nordic/nrf54h20dk/nrf54h20dk_nrf54h20_cpuapp_iron.dts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,3 +35,11 @@ slot0_partition: &cpuapp_slot0_partition {
3535
slot1_partition: &cpuapp_slot1_partition {
3636
label = "image-1";
3737
};
38+
39+
slot2_partition: &cpurad_slot0_partition {
40+
label = "image-2";
41+
};
42+
43+
slot3_partition: &cpurad_slot1_partition {
44+
label = "image-3";
45+
};

boards/nordic/nrf54h20dk/nrf54h20dk_nrf54h20_cpurad_iron.dts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,11 @@
1919
mbox-names = "tx", "rx";
2020
status = "okay";
2121
};
22+
23+
slot0_partition: &cpurad_slot0_partition {
24+
label = "image-0";
25+
};
26+
27+
slot1_partition: &cpurad_slot1_partition {
28+
label = "image-1";
29+
};

modules/Kconfig.mcuboot

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -227,6 +227,7 @@ config MCUBOOT_BOOTLOADER_MODE_DIRECT_XIP
227227

228228
config MCUBOOT_BOOTLOADER_MODE_DIRECT_XIP_WITH_REVERT
229229
bool "MCUboot has been configured for DirectXIP with revert"
230+
select MCUBOOT_BOOTUTIL_LIB
230231
select MCUBOOT_BOOTUTIL_LIB_FOR_DIRECT_XIP
231232
select MCUBOOT_BOOTLOADER_MODE_HAS_NO_DOWNGRADE
232233
select MCUBOOT_BOOTLOADER_NO_DOWNGRADE

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

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -230,3 +230,10 @@ tests:
230230
- nrf5340dk/nrf5340/cpuapp
231231
integration_platforms:
232232
- nrf5340dk/nrf5340/cpuapp
233+
sample.mcumgr.smp_svr.serial.empty_radio.nrf54h20_iron:
234+
extra_args:
235+
- EXTRA_CONF_FILE="overlay-serial.conf"
236+
- SB_CONFIG_NETCORE_EMPTY=y
237+
- CONFIG_SOC_NRF54H20_CPURAD_ENABLE=y
238+
platform_allow:
239+
- nrf54h20dk/nrf54h20/cpuapp/iron

soc/nordic/nrf54h/Kconfig

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,22 @@ config SOC_NRF54H20_CPURAD_ENABLE
7777
Radiocore, and also power will be requested to the Radiocore
7878
subsystem. The Radiocore will then start executing instructions.
7979

80+
config SOC_NRF54H20_CPURAD_ROM_START_OFFSET
81+
hex
82+
prompt "ROM start offset" if !BOOTLOADER_MCUBOOT
83+
default 0x800 if BOOTLOADER_MCUBOOT
84+
default 0
85+
depends on SOC_NRF54H20_CPURAD_ENABLE
86+
help
87+
If the radio is built for chain-loading by an application this
88+
variable is required to be set to value that leaves sufficient
89+
space between the beginning of the radio image and the start of
90+
the first section to store an image header or any other metadata.
91+
In the particular case of the MCUboot bootloader this reserves enough
92+
space to store the image header, which should also meet vector table
93+
alignment requirements on most ARM targets, although some targets
94+
may require smaller or larger values.
95+
8096
config SOC_NRF54H20_CPURAD
8197
select SOC_NRF54H20_CPURAD_COMMON
8298

soc/nordic/nrf54h/soc.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,8 @@ void soc_late_init_hook(void)
173173

174174
void *radiocore_address =
175175
(void *)(DT_REG_ADDR(DT_GPARENT(DT_NODELABEL_CPURAD_SLOT0_PARTITION)) +
176-
DT_REG_ADDR(DT_NODELABEL_CPURAD_SLOT0_PARTITION));
176+
DT_REG_ADDR(DT_NODELABEL_CPURAD_SLOT0_PARTITION) +
177+
CONFIG_SOC_NRF54H20_CPURAD_ROM_START_OFFSET);
177178

178179
/* Don't wait as this is not yet supported. */
179180
bool cpu_wait = false;

0 commit comments

Comments
 (0)