-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
samples: tfm: psa_template: Add support for netcore update
Add support for updating network core with nRF5340. External flash will be used for update images. Signed-off-by: Markus Lassila <[email protected]>
- Loading branch information
1 parent
5c93263
commit dd2e330
Showing
8 changed files
with
112 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# | ||
# Copyright (c) 2024 Nordic Semiconductor | ||
# | ||
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause | ||
# | ||
|
||
source "${ZEPHYR_BASE}/share/sysbuild/Kconfig" | ||
|
||
if BOARD_NRF5340DK_NRF5340_CPUAPP_NS | ||
|
||
choice NETCORE | ||
default NETCORE_EMPTY | ||
endchoice | ||
|
||
config SECURE_BOOT_NETCORE | ||
default y | ||
|
||
config NETCORE_APP_UPDATE | ||
default y | ||
|
||
config MCUBOOT_APP_SYNC_UPDATEABLE_IMAGES | ||
default y | ||
|
||
config PM_EXTERNAL_FLASH_MCUBOOT_SECONDARY | ||
default y | ||
|
||
config MCUBOOT_USE_ALL_AVAILABLE_RAM | ||
default y | ||
|
||
endif |
8 changes: 8 additions & 0 deletions
8
samples/tfm/tfm_psa_template/boards/nrf5340dk_nrf5340_cpuapp_ns.conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# | ||
# Copyright (c) 2024 Nordic Semiconductor ASA | ||
# | ||
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause | ||
# | ||
|
||
CONFIG_FPU=y | ||
CONFIG_BOARD_ENABLE_CPUNET=y |
11 changes: 11 additions & 0 deletions
11
samples/tfm/tfm_psa_template/boards/nrf5340dk_nrf5340_cpuapp_ns.overlay
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
/* | ||
* Copyright (c) 2024 Nordic Semiconductor ASA | ||
* | ||
* SPDX-License-Identifier: LicenseRef-Nordic-5-Clause | ||
*/ | ||
|
||
/ { | ||
chosen { | ||
nordic,pm-ext-flash = &mx25r64; | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# | ||
# Copyright (c) 2024 Nordic Semiconductor ASA | ||
# | ||
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause | ||
# | ||
CONFIG_NCS_SAMPLES_DEFAULTS=y | ||
|
||
CONFIG_IS_SECURE_BOOTLOADER=y | ||
CONFIG_MULTITHREADING=n | ||
CONFIG_GPIO=n | ||
CONFIG_ARM_MPU=n | ||
CONFIG_TICKLESS_KERNEL=n | ||
CONFIG_ERRNO=n | ||
CONFIG_SYS_CLOCK_EXISTS=y | ||
CONFIG_FPROTECT=y | ||
CONFIG_FW_INFO=y | ||
CONFIG_SECURE_BOOT_CRYPTO=y | ||
CONFIG_SECURE_BOOT_VALIDATION=y | ||
CONFIG_SECURE_BOOT_STORAGE=y | ||
CONFIG_PCD_NET=y | ||
CONFIG_FLASH=y | ||
CONFIG_FLASH_PAGE_LAYOUT=y | ||
CONFIG_LOG=y | ||
|
||
# To build with a minimal configuration, use the overlay file | ||
# '-DOVERLAY_CONFIG=overlay-minimal-size.conf' | ||
|
||
# Enable locking the network core for debugging | ||
CONFIG_PCD_LOCK_NETCORE_DEBUG=y |
22 changes: 22 additions & 0 deletions
22
samples/tfm/tfm_psa_template/sysbuild/mcuboot/boards/nrf5340dk_nrf5340_cpuapp.conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# | ||
# Copyright (c) 2024 Nordic Semiconductor ASA | ||
# | ||
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause | ||
# | ||
|
||
CONFIG_BOOT_MAX_IMG_SECTORS=256 | ||
|
||
CONFIG_PCD_APP=y | ||
|
||
CONFIG_UPDATEABLE_IMAGE_NUMBER=2 | ||
CONFIG_NRF53_MULTI_IMAGE_UPDATE=y | ||
CONFIG_BOOT_IMAGE_ACCESS_HOOK_NRF5340=y | ||
CONFIG_BOOT_IMAGE_ACCESS_HOOKS=y | ||
|
||
CONFIG_FLASH_SIMULATOR=y | ||
CONFIG_FLASH_SIMULATOR_DOUBLE_WRITES=y | ||
CONFIG_FLASH_SIMULATOR_STATS=n | ||
|
||
CONFIG_NORDIC_QSPI_NOR=y | ||
CONFIG_NORDIC_QSPI_NOR_FLASH_LAYOUT_PAGE_SIZE=4096 | ||
CONFIG_NORDIC_QSPI_NOR_STACK_WRITE_BUFFER_SIZE=16 |
11 changes: 11 additions & 0 deletions
11
samples/tfm/tfm_psa_template/sysbuild/mcuboot/boards/nrf5340dk_nrf5340_cpuapp.overlay
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
/* | ||
* Copyright (c) 2024 Nordic Semiconductor ASA | ||
* | ||
* SPDX-License-Identifier: LicenseRef-Nordic-5-Clause | ||
*/ | ||
|
||
/ { | ||
chosen { | ||
nordic,pm-ext-flash = &mx25r64; | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters