blob: 73fa34e92cb7a4bc983a8de16f72a3c2fcc23063 [file] [log] [blame]
Jianliang Shen710cb952022-10-08 11:32:35 +08001#-------------------------------------------------------------------------------
2# Copyright (c) 2022, Arm Limited. All rights reserved.
3#
4# SPDX-License-Identifier: BSD-3-Clause
5#
6#-------------------------------------------------------------------------------
7
8# Load platform Kconfig file if exists
9osource "$(PLATFORM_PATH)/Kconfig"
10
11################################# SPM ##########################################
12
13menu "SPM"
14config TFM_ISOLATION_LEVEL
15 int "Isolation level"
16 default 1
Kevin Peng6727c042023-02-03 10:52:19 +080017 range 1 1 if CONFIG_TFM_SPM_BACKEND_SFN
Jianliang Shen710cb952022-10-08 11:32:35 +080018 range 1 3 if PLATFORM_HAS_ISOLATION_L3_SUPPORT
19 range 1 2
20
21choice
22 prompt "SPM Backend"
Kevin Peng6727c042023-02-03 10:52:19 +080023 default CONFIG_TFM_SPM_BACKEND_SFN
Jianliang Shen710cb952022-10-08 11:32:35 +080024
Kevin Peng6727c042023-02-03 10:52:19 +080025 config CONFIG_TFM_SPM_BACKEND_SFN
Jianliang Shen710cb952022-10-08 11:32:35 +080026 bool "SFN Backend"
27
Kevin Peng6727c042023-02-03 10:52:19 +080028 config CONFIG_TFM_SPM_BACKEND_IPC
Jianliang Shen2b24f252022-11-25 11:08:54 +080029 bool "IPC Backend"
Jianliang Shen710cb952022-10-08 11:32:35 +080030endchoice
31
32config CONFIG_TFM_SPM_BACKEND
33 string
Kevin Peng6727c042023-02-03 10:52:19 +080034 default "IPC" if CONFIG_TFM_SPM_BACKEND_IPC
35 default "SFN" if CONFIG_TFM_SPM_BACKEND_SFN
Jianliang Shen710cb952022-10-08 11:32:35 +080036 default ""
37
38choice
39 prompt "Fault injection hardening profile"
40
41 config TFM_FIH_PROFILE_OFF
42 bool "OFF"
43
44 config TFM_FIH_PROFILE_LOW
45 bool "Low"
46
47 config TFM_FIH_PROFILE_MEDIUM
48 bool "Medium"
49
50 config TFM_FIH_PROFILE_HIGH
51 bool "High"
52endchoice
53
54config TFM_FIH_PROFILE
55 string
56 default "OFF" if TFM_FIH_PROFILE_OFF
57 default "LOW" if TFM_FIH_PROFILE_LOW
58 default "MEDIUM" if TFM_FIH_PROFILE_MEDIUM
59 default "HIGH" if TFM_FIH_PROFILE_HIGH
60
61config PSA_FRAMEWORK_HAS_MM_IOVEC
62 bool "Enable MM-IOVEC"
63 default n
64 depends on TFM_ISOLATION_LEVEL = 1
65endmenu
66
67################################# Secure partitions ############################
68
69# These are partition switches.
70rsource "secure_fw/partitions/Kconfig"
71
72################################# Platforms ####################################
73
74rsource "platform/Kconfig"
75
Jianliang Shen710cb952022-10-08 11:32:35 +080076################################# TEST #########################################
77
78menu "TF-M tests"
79rsource "lib/ext/tf-m-tests/Kconfig"
80rsource "lib/ext/psa_arch_tests/Kconfig"
81endmenu
82
83################################# Component ####################################
84
Jianliang Shen2b24f252022-11-25 11:08:54 +080085# These configs in this menu are local to a component or externally referenced
86# when components are coupled. Usually, such options are located in C header
87# file. The Header File Config System has more details about it.
Jianliang Shen710cb952022-10-08 11:32:35 +080088
89# Other configs above which are not in component menu are TF-M build options to
90# select which file or component to include into compilation. These are options,
91# usually used by a build system to enable/disable modules, specify location of
92# external dependency or other selection, global to a project. These options
93# shall be considered while adopting TF-M to other build systems.
94
95menu "TF-M component configs"
96rsource "secure_fw/spm/Kconfig"
97
98menu "Secure Partitions component configs"
99 rsource "secure_fw/partitions/*/Kconfig"
100endmenu
101endmenu