Skip to content

Commit c620646

Browse files
nordicjmnashif
authored andcommitted
boards: arm: Select TF-M symbols via Kconfig instead of defconfig
This forces a build to fail should it select a symbol that cannot be selected (if the prerequisites cannot be met) instead of silently ignoring it and allowing an invalid build to complete Signed-off-by: Jamie McCrae <[email protected]>
1 parent afa9079 commit c620646

15 files changed

+21
-40
lines changed

boards/arm/mps2/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,4 @@
55
config BOARD_MPS2
66
select HAS_COVERAGE_SUPPORT
77
select QEMU_TARGET if BOARD_MPS2_AN385 || BOARD_MPS2_AN521_CPU0 || BOARD_MPS2_AN521_CPU0_NS || BOARD_MPS2_AN521_CPU1
8+
select TRUSTED_EXECUTION_NONSECURE if BOARD_MPS2_AN521_CPU0_NS

boards/arm/mps2/mps2_an521_cpu0_ns_defconfig

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,3 @@ CONFIG_GPIO=y
1616
CONFIG_CONSOLE=y
1717
CONFIG_UART_CONSOLE=y
1818
CONFIG_SERIAL=y
19-
20-
# Build a non-secure firmware image
21-
CONFIG_TRUSTED_EXECUTION_NONSECURE=y

boards/arm/mps3/Kconfig

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,7 @@
44

55
config BOARD_MPS3
66
select QEMU_TARGET if BOARD_MPS3_CORSTONE300_AN547 || BOARD_MPS3_CORSTONE300_AN547_NS
7+
select TRUSTED_EXECUTION_NONSECURE if BOARD_MPS3_CORSTONE300_AN547_NS || \
8+
BOARD_MPS3_CORSTONE300_AN552_NS || BOARD_MPS3_CORSTONE300_FVP_NS || \
9+
BOARD_MPS3_CORSTONE310_AN555_NS || BOARD_MPS3_CORSTONE310_FVP_NS
10+
select BUILD_WITH_TFM if BOARD_MPS3_CORSTONE310_FVP_NS || BOARD_MPS3_CORSTONE300_FVP_NS

boards/arm/mps3/mps3_corstone300_an547_ns_defconfig

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,3 @@ CONFIG_GPIO=y
1717
CONFIG_CONSOLE=y
1818
CONFIG_UART_CONSOLE=y
1919
CONFIG_SERIAL=y
20-
21-
# Build a Non-secure firmware image
22-
CONFIG_TRUSTED_EXECUTION_SECURE=n
23-
CONFIG_TRUSTED_EXECUTION_NONSECURE=y

boards/arm/mps3/mps3_corstone300_an552_ns_defconfig

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,3 @@ CONFIG_GPIO=y
1212
CONFIG_CONSOLE=y
1313
CONFIG_UART_CONSOLE=y
1414
CONFIG_SERIAL=y
15-
16-
# Build a Non-secure firmware image
17-
CONFIG_TRUSTED_EXECUTION_SECURE=n
18-
CONFIG_TRUSTED_EXECUTION_NONSECURE=y

boards/arm/mps3/mps3_corstone300_fvp_ns_defconfig

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,3 @@ CONFIG_GPIO=y
1212
CONFIG_CONSOLE=y
1313
CONFIG_UART_CONSOLE=y
1414
CONFIG_SERIAL=y
15-
16-
# Build a Non-secure firmware image
17-
CONFIG_TRUSTED_EXECUTION_SECURE=n
18-
CONFIG_TRUSTED_EXECUTION_NONSECURE=y
19-
20-
CONFIG_BUILD_WITH_TFM=y

boards/arm/mps3/mps3_corstone310_an555_ns_defconfig

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,3 @@ CONFIG_GPIO=y
1212
CONFIG_CONSOLE=y
1313
CONFIG_UART_CONSOLE=y
1414
CONFIG_SERIAL=y
15-
16-
# Build a Non-secure firmware image
17-
CONFIG_TRUSTED_EXECUTION_SECURE=n
18-
CONFIG_TRUSTED_EXECUTION_NONSECURE=y

boards/arm/mps3/mps3_corstone310_fvp_ns_defconfig

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,3 @@ CONFIG_GPIO=y
1212
CONFIG_CONSOLE=y
1313
CONFIG_UART_CONSOLE=y
1414
CONFIG_SERIAL=y
15-
16-
# Build a Non-secure firmware image
17-
CONFIG_TRUSTED_EXECUTION_SECURE=n
18-
CONFIG_TRUSTED_EXECUTION_NONSECURE=y
19-
CONFIG_BUILD_WITH_TFM=y

boards/arm/mps4/Kconfig

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Copyright (c) 2025 Nordic Semiconductor ASA
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
config BOARD_MPS4
5+
select BUILD_WITH_TFM if BOARD_MPS4_CORSTONE315_FVP_NS || BOARD_MPS4_CORSTONE320_FVP_NS
6+
select TRUSTED_EXECUTION_NONSECURE if BOARD_MPS4_CORSTONE315_FVP_NS || BOARD_MPS4_CORSTONE320_FVP_NS

boards/arm/mps4/mps4_corstone315_fvp_ns_defconfig

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,3 @@ CONFIG_GPIO=y
1212
CONFIG_CONSOLE=y
1313
CONFIG_UART_CONSOLE=y
1414
CONFIG_SERIAL=y
15-
16-
# Build a Non-secure firmware image
17-
CONFIG_TRUSTED_EXECUTION_SECURE=n
18-
CONFIG_TRUSTED_EXECUTION_NONSECURE=y
19-
CONFIG_BUILD_WITH_TFM=y

0 commit comments

Comments
 (0)