-
Notifications
You must be signed in to change notification settings - Fork 624
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[nrf noup] boards: Add non-secure target for nrf54L15dk
This adds the nrf54l15dk/nrf54l15/cpuapp/ns board variant to sdk-zephyr. It allows to build nRF54l15dk with TF-M in nRF Connect SDK. This is done as a noup as the out-of-tree board extension feature is not available. When zephyrproject-rtos/zephyr#69548 is completed this commit can be reverted and the variant be placed in sdk-nrf. Signed-off-by: Tomi Fontanilles <[email protected]> (cherry picked from commit 6b4c840)
- Loading branch information
1 parent
0f77131
commit 787a64f
Showing
8 changed files
with
147 additions
and
1 deletion.
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,34 @@ | ||
# nRF54L15 DK board configuration | ||
|
||
# Copyright (c) 2024 Nordic Semiconductor ASA | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
if BOARD_NRF54L15DK_NRF54L15_CPUAPP_NS | ||
|
||
config NRF_MPC_REGION_SIZE | ||
hex | ||
default 0x1000 | ||
help | ||
Region size for the Memory Protection Controller (MPC) in bytes. | ||
|
||
config NRF_TRUSTZONE_FLASH_REGION_SIZE | ||
hex | ||
default NRF_MPC_REGION_SIZE | ||
help | ||
This defines the flash region size from the TRUSTZONE perspective. | ||
It is used when configuring the TRUSTZONE and when setting alignments | ||
requirements for the partitions. | ||
This abstraction allows us to configure TRUSTZONE without depending | ||
on peripheral specific symbols. | ||
|
||
config NRF_TRUSTZONE_RAM_REGION_SIZE | ||
hex | ||
default NRF_MPC_REGION_SIZE | ||
help | ||
This defines the RAM region size from the TRUSTZONE perspective. | ||
It is used when configuring the TRUSTZONE and when setting alignments | ||
requirements for the partitions. | ||
This abstraction allows us to configure TRUSTZONE without depending | ||
on peripheral specific symbols. | ||
|
||
endif #BOARD_NRF54L15DK_NRF54L15_CPUAPP_NS |
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
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 |
---|---|---|
|
@@ -9,3 +9,5 @@ board: | |
variants: | ||
- name: xip | ||
cpucluster: cpuflpr | ||
- name: ns | ||
cpucluster: cpuapp |
31 changes: 31 additions & 0 deletions
31
boards/nordic/nrf54l15dk/nrf54l15dk_nrf54l15_cpuapp_ns.dts
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,31 @@ | ||
/* | ||
* Copyright (c) 2024 Nordic Semiconductor ASA | ||
* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
/dts-v1/; | ||
|
||
#define USE_NON_SECURE_ADDRESS_MAP 1 | ||
|
||
#include "nrf54l15_cpuapp_common.dtsi" | ||
|
||
/ { | ||
compatible = "nordic,nrf54l15dk_nrf54l15-cpuapp"; | ||
model = "Nordic nRF54L15 DK nRF54L15 Application MCU"; | ||
|
||
chosen { | ||
zephyr,code-partition = &slot0_partition; | ||
zephyr,sram = &cpuapp_sram; | ||
}; | ||
}; | ||
|
||
&uart30 { | ||
/* Disable so that TF-M can use this UART */ | ||
status = "disabled"; | ||
|
||
current-speed = <115200>; | ||
pinctrl-0 = <&uart30_default>; | ||
pinctrl-1 = <&uart30_sleep>; | ||
pinctrl-names = "default", "sleep"; | ||
}; |
22 changes: 22 additions & 0 deletions
22
boards/nordic/nrf54l15dk/nrf54l15dk_nrf54l15_cpuapp_ns.yaml
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 | ||
|
||
identifier: nrf54l15dk/nrf54l15/cpuapp/ns | ||
name: nRF54l15-DK-nRF54l15-Application-Non-Secure | ||
type: mcu | ||
arch: arm | ||
toolchain: | ||
- gnuarmemb | ||
- xtools | ||
- zephyr | ||
ram: 256 | ||
flash: 1524 | ||
supported: | ||
- adc | ||
- gpio | ||
- i2c | ||
- spi | ||
- counter | ||
- watchdog | ||
- adc | ||
- i2s |
31 changes: 31 additions & 0 deletions
31
boards/nordic/nrf54l15dk/nrf54l15dk_nrf54l15_cpuapp_ns_defconfig
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,31 @@ | ||
# Copyright (c) 2024 Nordic Semiconductor ASA | ||
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause | ||
|
||
# Enable MPU | ||
CONFIG_ARM_MPU=y | ||
|
||
# Enable hardware stack protection | ||
CONFIG_HW_STACK_PROTECTION=y | ||
|
||
CONFIG_NULL_POINTER_EXCEPTION_DETECTION_NONE=y | ||
|
||
# Enable TrustZone-M | ||
CONFIG_ARM_TRUSTZONE_M=y | ||
|
||
# This Board implies building Non-Secure firmware | ||
CONFIG_TRUSTED_EXECUTION_NONSECURE=y | ||
|
||
# Don't enable the cache in the non-secure image as it is a | ||
# secure-only peripheral on 54l | ||
CONFIG_CACHE_MANAGEMENT=n | ||
CONFIG_EXTERNAL_CACHE=n | ||
|
||
CONFIG_UART_CONSOLE=y | ||
CONFIG_CONSOLE=y | ||
CONFIG_SERIAL=y | ||
|
||
# Enable GPIO | ||
CONFIG_GPIO=y | ||
|
||
# Start SYSCOUNTER on driver init | ||
CONFIG_NRF_GRTC_START_SYSCOUNTER=y |