blob: 48c0689a5bcdaa7b708926b1fc267598933d2fc3 [file] [log] [blame]
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +01001#!/usr/bin/env python3
2
3""" builtin_configs.py:
4
5 Default configuration files used as reference """
6
7from __future__ import print_function
8
9__copyright__ = """
10/*
Xinyu Zhangeb442a12021-02-01 15:16:19 +080011 * Copyright (c) 2018-2021, Arm Limited. All rights reserved.
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +010012 *
13 * SPDX-License-Identifier: BSD-3-Clause
14 *
15 */
16 """
Karl Zhang08681e62020-10-30 13:56:03 +080017
18__author__ = "tf-m@lists.trustedfirmware.org"
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +010019__project__ = "Trusted Firmware-M Open CI"
Karl Zhang08681e62020-10-30 13:56:03 +080020__version__ = "1.2.0"
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +010021
Minos Galanakisea421232019-06-20 17:11:28 +010022# common parameters for tf-m build system
23# This configuration template will be passed into the tfm-builder module after
24# the template evaluation is converted to a command
25
26_common_tfm_builder_cfg = {
27 "config_type": "tf-m",
28 "codebase_root_dir": "tf-m",
29 # Order to which the variants are evaluated. This affects the name of
30 # variant configuration and the wildcard replacement logic in invalid
31 # configuration tuples
Xinyu Zhangb708f572020-09-15 11:43:46 +080032 "sort_order": ["tfm_platform",
33 "toolchain_file",
34 "psa_api",
35 "isolation_level",
36 "test_regression",
37 "test_psa_api",
Minos Galanakisea421232019-06-20 17:11:28 +010038 "cmake_build_type",
Xinyu Zhangb708f572020-09-15 11:43:46 +080039 "with_otp",
40 "with_bl2",
41 "with_ns",
Xinyu Zhang9fd74242020-10-22 11:30:50 +080042 "profile",
43 "partition_ps"],
Minos Galanakisea421232019-06-20 17:11:28 +010044
45 # Keys for the templace will come from the combinations of parameters
46 # provided in the seed dictionary.
47
Xinyu Zhangb708f572020-09-15 11:43:46 +080048 "config_template": "cmake " + \
49 "-DTFM_PLATFORM=%(tfm_platform)s " + \
Fathi Boudra324fee72020-11-20 10:31:12 +010050 "-DTFM_TOOLCHAIN_FILE=%(codebase_root_dir)s/%(toolchain_file)s " + \
Xinyu Zhangb708f572020-09-15 11:43:46 +080051 "-DTFM_PSA_API=%(psa_api)s " + \
52 "-DTFM_ISOLATION_LEVEL=%(isolation_level)s " + \
53 "-DTEST_NS=%(test_regression)s -DTEST_S=%(test_regression)s " + \
54 "-DTEST_PSA_API=%(test_psa_api)s " + \
55 "-DCMAKE_BUILD_TYPE=%(cmake_build_type)s " + \
56 "-DCRYPTO_HW_ACCELERATOR_OTP_STATE=%(with_otp)s " + \
57 "-DBL2=%(with_bl2)s " + \
58 "-DNS=%(with_ns)s " + \
59 "-DTFM_TEST_REPO_PATH=%(codebase_root_dir)s/../tf-m-tests " + \
60 "-DMBEDCRYPTO_PATH=%(codebase_root_dir)s/../mbedtls " + \
61 "-DPSA_ARCH_TESTS_PATH=%(codebase_root_dir)s/../psa-arch-tests " + \
62 "-DMCUBOOT_PATH=%(codebase_root_dir)s/../mcuboot " + \
63 "-DTFM_PROFILE=%(profile)s " + \
Xinyu Zhangb5bbb692020-10-26 10:14:33 +080064 "-DTFM_PARTITION_PROTECTED_STORAGE=%(partition_ps)s " + \
Xinyu Zhangb708f572020-09-15 11:43:46 +080065 "%(codebase_root_dir)s",
Karl Zhangaff558a2020-05-15 14:28:23 +010066
Minos Galanakisea421232019-06-20 17:11:28 +010067 # A small subset of string substitution params is allowed in commands.
68 # tfm_build_manager will replace %(_tbm_build_dir_)s, %(_tbm_code_dir_)s,
69 # _tbm_target_platform_ with the paths set when building
70
Xinyu Zhangb708f572020-09-15 11:43:46 +080071 "artifact_capture_rex": (r'%(_tbm_build_dir_)s/bin'
Minos Galanakisea421232019-06-20 17:11:28 +010072 r'/(\w+\.(?:axf|bin|hex))$'),
73
74 # ALL commands will be executed for every build.
75 # Other keys will append extra commands when matching target_platform
Fathi Boudra83e4f292020-12-04 22:33:40 +010076 "build_cmds": {"all": ["cmake --build ./ -- install"],
Summer Qin3c2b5722021-05-26 10:43:45 +080077 "arm/musca_b1/sse_200": [("srec_cat "
Mark Horvath8d281cd2020-12-07 15:20:26 +010078 "%(_tbm_build_dir_)s/bin/"
79 "bl2.bin "
80 "-Binary -offset 0xA000000 "
81 "-fill 0xFF 0xA000000 0xA020000 "
82 "%(_tbm_build_dir_)s/bin/"
83 "tfm_s_ns_signed.bin "
84 "-Binary -offset 0xA020000 "
85 "-fill 0xFF 0xA020000 0xA200000 "
86 "-o %(_tbm_build_dir_)s/bin/"
87 "tfm.hex -Intel")],
Summer Qin3c2b5722021-05-26 10:43:45 +080088 "arm/musca_s1": [("srec_cat "
Xinyu Zhangb708f572020-09-15 11:43:46 +080089 "%(_tbm_build_dir_)s/bin/"
90 "bl2.bin "
Karl Zhangeffed972020-06-30 15:48:01 +080091 "-Binary -offset 0xA000000 "
Raef Coles543aab32020-12-03 11:12:02 +000092 "-fill 0xFF 0xA000000 0xA020000 "
Xinyu Zhangb708f572020-09-15 11:43:46 +080093 "%(_tbm_build_dir_)s/bin/"
Xinyu Zhang694eb492020-11-04 18:29:08 +080094 "tfm_s_ns_signed.bin "
Raef Coles543aab32020-12-03 11:12:02 +000095 "-Binary -offset 0xA020000 "
96 "-fill 0xFF 0xA020000 0xA200000 "
97 "-o %(_tbm_build_dir_)s/bin/"
Xinyu Zhang694eb492020-11-04 18:29:08 +080098 "tfm.hex -Intel")]
Minos Galanakisea421232019-06-20 17:11:28 +010099 },
100
101 # (Optional) If set will fail if those artefacts are missing post build
102 "required_artefacts": {"all": [
Xinyu Zhangb708f572020-09-15 11:43:46 +0800103 "%(_tbm_build_dir_)s/bin/"
104 "tfm_s.bin",
105 "%(_tbm_build_dir_)s/bin/"
106 "tfm_ns.bin"],
Summer Qin3c2b5722021-05-26 10:43:45 +0800107 "arm/musca_b1/sse_200": [
Xinyu Zhangb708f572020-09-15 11:43:46 +0800108 "%(_tbm_build_dir_)s/bin/"
109 "tfm.hex",
110 "%(_tbm_build_dir_)s/bin/"
Xinyu Zhang694eb492020-11-04 18:29:08 +0800111 "bl2.bin",
Xinyu Zhangb708f572020-09-15 11:43:46 +0800112 "%(_tbm_build_dir_)s/bin/"
113 "tfm_sign.bin"],
Summer Qin3c2b5722021-05-26 10:43:45 +0800114 "arm/musca_s1": [
Xinyu Zhangb708f572020-09-15 11:43:46 +0800115 "%(_tbm_build_dir_)s/bin/"
116 "tfm.hex",
117 "%(_tbm_build_dir_)s/bin/"
Xinyu Zhang694eb492020-11-04 18:29:08 +0800118 "bl2.bin",
Xinyu Zhangb708f572020-09-15 11:43:46 +0800119 "%(_tbm_build_dir_)s/bin/"
120 "tfm_sign.bin"]
Minos Galanakisea421232019-06-20 17:11:28 +0100121 }
122}
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +0100123
Xinyu Zhangb708f572020-09-15 11:43:46 +0800124# List of all build configs that are impossible under all circumstances
125_common_tfm_invalid_configs = [
Karl Zhangc858a722021-03-22 21:38:19 +0800126 # Load range overlap on Musca for IPC Debug type: T895
Summer Qin3c2b5722021-05-26 10:43:45 +0800127 ("arm/musca_b1/sse_200", "toolchain_ARMCLANG.cmake", "*", "*", "*", "IPC", "Debug", "*", "*", "*", "*", "*"),
128 ("arm/musca_s1", "toolchain_ARMCLANG.cmake", "*", "*", "*", "IPC", "Debug", "*", "*", "*", "*", "*"),
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800129 # LVL2 and LVL3 requires PSA api
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800130 ("*", "*", False, "2", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800131 ("*", "*", False, "3", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800132 # Regression requires NS
133 ("*", "*", "*", "*", True, "*", "*", "*", "*", False, "*", "*"),
Xinyu Zhang11d66112020-11-04 15:38:29 +0800134 # psoc64 requires PSA api
135 ("cypress/psoc64", "*", False, "*", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800136 # No PSA_ACK with regression
137 ("*", "*", "*", "*", True, "IPC", "*", "*", "*", "*", "*", "*"),
138 ("*", "*", "*", "*", True, "CRYPTO", "*", "*", "*", "*", "*", "*"),
139 ("*", "*", "*", "*", True, "PROTECTED_STORAGE", "*", "*", "*", "*", "*", "*"),
140 ("*", "*", "*", "*", True, "INITIAL_ATTESTATION", "*", "*", "*", "*", "*", "*"),
141 ("*", "*", "*", "*", True, "INTERNAL_TRUSTED_STORAGE", "*", "*", "*", "*", "*", "*"),
142 # PSA_ACK requires NS
143 ("*", "*", "*", "*", "*", "IPC", "*", "*", "*", False, "*", "*"),
144 ("*", "*", "*", "*", "*", "CRYPTO", "*", "*", "*", False, "*", "*"),
145 ("*", "*", "*", "*", "*", "PROTECTED_STORAGE", "*", "*", "*", False, "*", "*"),
146 ("*", "*", "*", "*", "*", "INITIAL_ATTESTATION", "*", "*", "*", False, "*", "*"),
147 ("*", "*", "*", "*", "*", "INTERNAL_TRUSTED_STORAGE", "*", "*", "*", False, "*", "*"),
Xinyu Zhang3227da42021-03-19 17:37:17 +0800148 # PSA_ACK does not support LVL3
149 ("*", "*", "*", "3", "*", "IPC", "*", "*", "*", "*", "*", "*"),
150 ("*", "*", "*", "3", "*", "CRYPTO", "*", "*", "*", "*", "*", "*"),
151 ("*", "*", "*", "3", "*", "PROTECTED_STORAGE", "*", "*", "*", "*", "*", "*"),
152 ("*", "*", "*", "3", "*", "INITIAL_ATTESTATION", "*", "*", "*", "*", "*", "*"),
153 ("*", "*", "*", "3", "*", "INTERNAL_TRUSTED_STORAGE", "*", "*", "*", "*", "*", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800154 # Musca requires BL2
Summer Qin3c2b5722021-05-26 10:43:45 +0800155 ("arm/musca_b1/sse_200", "*", "*", "*", "*", "*", "*", "*", False, "*", "*", "*"),
156 ("arm/musca_s1", "*", "*", "*", "*", "*", "*", "*", False, "*", "*", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800157 # psoc64 cannot use BL2
158 ("cypress/psoc64", "*", "*", "*", "*", "*", "*", "*", True, "*", "*", "*"),
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800159 # psoc64 does not support Debug build type
160 ("cypress/psoc64", "*", "*", "*", "*", "*", "Debug", "*", "*", "*", "*", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800161 # Musca b1 does not support Profile S
Summer Qin3c2b5722021-05-26 10:43:45 +0800162 ("arm/musca_b1/sse_200", "*", "*", "*", "*", "*", "*", "*", "*", "*", "profile_small", "*"),
Mark Horvath8d281cd2020-12-07 15:20:26 +0100163 # Musca B1 Secure Enclave requires PSA api, BL2, and supports only Isolation Level 1
Summer Qin3c2b5722021-05-26 10:43:45 +0800164 ("arm/musca_b1/secure_enclave", "*", False, "*", "*", "*", "*", "*", "*", "*", "*", "*"),
165 ("arm/musca_b1/secure_enclave", "*", "*", "*", "*", "*", "*", "*", False, "*", "*", "*"),
166 ("arm/musca_b1/secure_enclave", "*", "*", "2", "*", "*", "*", "*", "*", "*", "*", "*"),
Mark Horvath8d281cd2020-12-07 15:20:26 +0100167 # Musca B1 Secure Enclave does not support tests, profiles, NS side building
Summer Qin3c2b5722021-05-26 10:43:45 +0800168 ("arm/musca_b1/secure_enclave", "*", "*", "*", True, "*", "*", "*", "*", "*", "*", "*"),
169 ("arm/musca_b1/secure_enclave", "*", "*", "*", "*", "IPC", "*", "*", "*", "*", "*", "*"),
170 ("arm/musca_b1/secure_enclave", "*", "*", "*", "*", "CRYPTO", "*", "*", "*", "*", "*", "*"),
171 ("arm/musca_b1/secure_enclave", "*", "*", "*", "*", "PROTECTED_STORAGE", "*", "*", "*", "*", "*", "*"),
172 ("arm/musca_b1/secure_enclave", "*", "*", "*", "*", "INITIAL_ATTESTATION", "*", "*", "*", "*", "*", "*"),
173 ("arm/musca_b1/secure_enclave", "*", "*", "*", "*", "INTERNAL_TRUSTED_STORAGE", "*", "*", "*", "*", "*", "*"),
174 ("arm/musca_b1/secure_enclave", "*", "*", "*", "*", "*", "*", "*", "*", "*", "profile_small", "*"),
175 ("arm/musca_b1/secure_enclave", "*", "*", "*", "*", "*", "*", "*", "*", "*", "profile_medium", "*"),
176 ("arm/musca_b1/secure_enclave", "*", "*", "*", "*", "*", "*", "*", "*", True, "*", "*"),
Xinyu Zhang709c1542020-11-02 18:41:07 +0800177 # PARTITION_PS could be OFF only for Profile S and M
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800178 ("*", "*", "*", "*", "*", "*", "*", "*", "*", "*", "", "OFF"),
Xinyu Zhang9b1aef92021-03-12 15:36:44 +0800179 ("*", "*", "*", "*", "*", "*", "*", "*", "*", "*", "profile_large", "OFF"),
Xinyu Zhang709c1542020-11-02 18:41:07 +0800180 # PARTITION_PS should be OFF for Profile S
181 ("*", "*", "*", "*", "*", "*", "*", "*", "*", "*", "profile_small", "ON"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800182 # Proile M only support for PSA_API
183 ("*", "*", False, "*", "*", "*", "*", "*", "*", "*", "profile_medium", "*"),
184 # Profile M only support for Isolation Level 2
185 ("*", "*", "*", "1", "*", "*", "*", "*", "*", "*", "profile_medium", "*"),
Xinyu Zhange8de4512020-11-13 10:37:56 +0800186 ("*", "*", "*", "3", "*", "*", "*", "*", "*", "*", "profile_medium", "*"),
Xinyu Zhang9b1aef92021-03-12 15:36:44 +0800187 # Profile L only support for Isolation Level 3
188 ("*", "*", "*", "1", "*", "*", "*", "*", "*", "*", "profile_large", "*"),
189 ("*", "*", "*", "2", "*", "*", "*", "*", "*", "*", "profile_large", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800190 # Profile S does not support PSA_API
191 ("*", "*", True, "*", "*", "*", "*", "*", "*", "*", "profile_small", "*"),
192 # Profile S only supports Isolation Level 2
193 ("*", "*", "*", "2", "*", "*", "*", "*", "*", "*", "profile_small", "*"),
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800194 # Only AN521 and MUSCA_B1 support Isolation Level 3
Summer Qin3c2b5722021-05-26 10:43:45 +0800195 ("arm/mps2/an519", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
196 ("arm/mps3/an524", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
197 ("arm/musca_s1", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800198 ("cypress/psoc64", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800199 ("arm/musca_b1/secure_enclave", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800200 ]
201
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +0100202# Configure build manager to build several combinations
Karl Zhangaff558a2020-05-15 14:28:23 +0100203config_AN524 = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800204 "tfm_platform": ["arm/mps3/an524"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800205 "toolchain_file": ["toolchain_GNUARM.cmake",
206 "toolchain_ARMCLANG.cmake"],
207 "psa_api": [True, False],
208 "isolation_level": ["1", "2"],
209 "test_regression": [True, False],
210 "test_psa_api": ["OFF"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100211 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800212 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800213 "with_bl2": [True, False],
214 "with_ns": [True, False],
215 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800216 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100217 },
218 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800219 "invalid": _common_tfm_invalid_configs + []
Karl Zhangaff558a2020-05-15 14:28:23 +0100220 }
221
Karl Zhangaff558a2020-05-15 14:28:23 +0100222config_AN521 = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800223 "tfm_platform": ["arm/mps2/an521"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800224 "toolchain_file": ["toolchain_GNUARM.cmake",
225 "toolchain_ARMCLANG.cmake"],
226 "psa_api": [True, False],
227 "isolation_level": ["1", "2"],
228 "test_regression": [True, False],
229 "test_psa_api": ["OFF"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100230 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800231 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800232 "with_bl2": [True, False],
233 "with_ns": [True, False],
234 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800235 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100236 },
237 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800238 "invalid": _common_tfm_invalid_configs + []
Karl Zhangaff558a2020-05-15 14:28:23 +0100239 }
240
Karl Zhangaff558a2020-05-15 14:28:23 +0100241config_PSA_API = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800242 "tfm_platform": ["arm/mps2/an521", "arm/musca_b1/sse_200",
243 "arm/musca_s1"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800244 "toolchain_file": ["toolchain_GNUARM.cmake",
245 "toolchain_ARMCLANG.cmake"],
246 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800247 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800248 "test_regression": [False],
249 "test_psa_api": ["CRYPTO",
250 "PROTECTED_STORAGE",
251 "INITIAL_ATTESTATION",
252 "INTERNAL_TRUSTED_STORAGE"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100253 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800254 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800255 "with_bl2": [True],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800256 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800257 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800258 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100259 },
260 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800261 "invalid": _common_tfm_invalid_configs + []
Karl Zhangaff558a2020-05-15 14:28:23 +0100262 }
263
Karl Zhangaff558a2020-05-15 14:28:23 +0100264config_PSA_FF = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800265 "tfm_platform": ["arm/mps2/an521", "arm/musca_b1/sse_200",
266 "arm/musca_s1"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800267 "toolchain_file": ["toolchain_GNUARM.cmake",
268 "toolchain_ARMCLANG.cmake"],
269 "psa_api": [True],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800270 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800271 "test_regression": [False],
272 "test_psa_api": ["IPC"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100273 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800274 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800275 "with_bl2": [True],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800276 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800277 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800278 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100279 },
280 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800281 "invalid": _common_tfm_invalid_configs + []
Karl Zhangaff558a2020-05-15 14:28:23 +0100282 }
283
Karl Zhangaff558a2020-05-15 14:28:23 +0100284config_PSA_API_OTP = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800285 "tfm_platform": ["arm/musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800286 "toolchain_file": ["toolchain_GNUARM.cmake",
287 "toolchain_ARMCLANG.cmake"],
288 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800289 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800290 "test_regression": [False],
291 "test_psa_api": ["CRYPTO",
292 "PROTECTED_STORAGE",
293 "INITIAL_ATTESTATION",
294 "INTERNAL_TRUSTED_STORAGE"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100295 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800296 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800297 "with_bl2": [True],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800298 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800299 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800300 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100301 },
302 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800303 "invalid": _common_tfm_invalid_configs + []
Karl Zhangaff558a2020-05-15 14:28:23 +0100304 }
Minos Galanakisea421232019-06-20 17:11:28 +0100305
Xinyu Zhangb708f572020-09-15 11:43:46 +0800306config_PSA_FF_OTP = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800307 "tfm_platform": ["arm/musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800308 "toolchain_file": ["toolchain_GNUARM.cmake",
309 "toolchain_ARMCLANG.cmake"],
310 "psa_api": [True],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800311 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800312 "test_regression": [False],
313 "test_psa_api": ["IPC"],
314 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800315 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800316 "with_bl2": [True],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800317 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800318 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800319 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800320 },
321 "common_params": _common_tfm_builder_cfg,
322 "invalid": _common_tfm_invalid_configs + []
323 }
324
Karl Zhang96dfe2d2020-05-11 11:31:40 +0800325config_PSOC64 = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800326 "tfm_platform": ["cypress/psoc64"],
327 "toolchain_file": ["toolchain_GNUARM.cmake",
328 "toolchain_ARMCLANG.cmake"],
329 "psa_api": [True],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800330 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800331 "test_regression": [True],
332 "test_psa_api": ["OFF"],
Karl Zhang96dfe2d2020-05-11 11:31:40 +0800333 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800334 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800335 "with_bl2": [False],
336 "with_ns": [True, False],
337 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800338 "partition_ps": ["ON"],
Karl Zhang96dfe2d2020-05-11 11:31:40 +0800339 },
340 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800341 "invalid": _common_tfm_invalid_configs + []
Karl Zhang96dfe2d2020-05-11 11:31:40 +0800342 }
343
Minos Galanakisea421232019-06-20 17:11:28 +0100344config_AN519 = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800345 "tfm_platform": ["arm/mps2/an519"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800346 "toolchain_file": ["toolchain_GNUARM.cmake",
347 "toolchain_ARMCLANG.cmake"],
348 "psa_api": [True, False],
349 "isolation_level": ["1", "2"],
350 "test_regression": [True, False],
351 "test_psa_api": ["OFF"],
Minos Galanakisea421232019-06-20 17:11:28 +0100352 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800353 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800354 "with_bl2": [True, False],
355 "with_ns": [True, False],
356 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800357 "partition_ps": ["ON"],
Minos Galanakisea421232019-06-20 17:11:28 +0100358 },
359 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800360 "invalid": _common_tfm_invalid_configs + []
Minos Galanakisea421232019-06-20 17:11:28 +0100361 }
362
Xinyu Zhangb708f572020-09-15 11:43:46 +0800363config_IPC = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800364 "tfm_platform": ["arm/mps2/an521", "arm/mps2/an519",
365 "arm/musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800366 "toolchain_file": ["toolchain_GNUARM.cmake",
367 "toolchain_ARMCLANG.cmake"],
368 "psa_api": [True],
369 "isolation_level": ["1", "2"],
370 "test_regression": [True, False],
371 "test_psa_api": ["OFF"],
372 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800373 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800374 "with_bl2": [True, False],
375 "with_ns": [True, False],
376 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800377 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800378 },
Minos Galanakisea421232019-06-20 17:11:28 +0100379 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800380 "invalid": _common_tfm_invalid_configs + []
Minos Galanakisea421232019-06-20 17:11:28 +0100381 }
382
Minos Galanakisea421232019-06-20 17:11:28 +0100383config_full = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800384 "tfm_platform": ["arm/mps2/an521", "arm/mps2/an519",
385 "arm/musca_b1/sse_200",
386 "arm/mps3/an524", "cypress/psoc64",
387 "arm/musca_b1/secure_enclave"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800388 "toolchain_file": ["toolchain_GNUARM.cmake",
389 "toolchain_ARMCLANG.cmake"],
390 "psa_api": [True, False],
391 "isolation_level": ["1", "2"],
392 "test_regression": [True, False],
393 "test_psa_api": ["OFF"],
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800394 "cmake_build_type": ["Debug", "Release", "RelWithDebInfo"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800395 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800396 "with_bl2": [True, False],
397 "with_ns": [True, False],
398 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800399 "partition_ps": ["ON"],
Dean Birchd6ce2c82020-05-13 13:16:15 +0100400 },
401 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800402 "invalid": _common_tfm_invalid_configs + [
403 ("cypress/psoc64", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800404 "*", "*", "Debug", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800405 ("cypress/psoc64", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800406 "*", "*", "*", "*", True, True, "*", "*"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800407 ("arm/mps2/an521", "*", "*", "*",
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800408 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800409 ("arm/mps2/an519", "*", "*", "*",
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800410 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800411 ("arm/musca_b1/sse_200", "*", "*", "*",
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800412 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800413 ("arm/mps3/an524", "*", "*", "*",
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800414 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800415 ]
Karl Zhang81a76772020-05-11 18:28:52 +0800416 }
417
Karl Zhangaff558a2020-05-15 14:28:23 +0100418config_tfm_test = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800419 "tfm_platform": ["arm/mps2/an521",
420 "arm/musca_b1/sse_200", "arm/musca_s1"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800421 "toolchain_file": ["toolchain_ARMCLANG.cmake",
422 "toolchain_GNUARM.cmake"],
423 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800424 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800425 "test_regression": [True, False],
426 "test_psa_api": ["OFF"],
427 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800428 "with_otp": ["off"],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800429 "with_bl2": [True],
430 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800431 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800432 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800433 },
434 "common_params": _common_tfm_builder_cfg,
435 "invalid": _common_tfm_invalid_configs + []
436 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800437
Karl Zhangaff558a2020-05-15 14:28:23 +0100438config_tfm_test2 = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800439 "tfm_platform": ["arm/mps2/an519", "arm/mps3/an524"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800440 "toolchain_file": ["toolchain_ARMCLANG.cmake",
441 "toolchain_GNUARM.cmake"],
442 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800443 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800444 "test_regression": [True, False],
445 "test_psa_api": ["OFF"],
446 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800447 "with_otp": ["off"],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800448 "with_bl2": [True],
449 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800450 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800451 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800452 },
453 "common_params": _common_tfm_builder_cfg,
454 "invalid": _common_tfm_invalid_configs + [
Summer Qin3c2b5722021-05-26 10:43:45 +0800455 ("arm/mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800456 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800457 ]
458 }
Karl Zhangaff558a2020-05-15 14:28:23 +0100459
Karl Zhang14573bc2020-06-08 09:23:21 +0800460config_tfm_profile = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800461 "tfm_platform": ["arm/mps2/an519", "arm/mps2/an521",
462 "arm/musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800463 "toolchain_file": ["toolchain_ARMCLANG.cmake",
464 "toolchain_GNUARM.cmake"],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800465 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800466 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800467 "test_regression": [True, False],
468 "test_psa_api": ["OFF"],
469 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800470 "with_otp": ["off"],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800471 "with_bl2": [True],
472 "with_ns": [True],
Xinyu Zhang9b1aef92021-03-12 15:36:44 +0800473 "profile": ["profile_small", "profile_medium", "profile_large"],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800474 "partition_ps": ["ON", "OFF"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800475 },
476 "common_params": _common_tfm_builder_cfg,
477 "invalid": _common_tfm_invalid_configs + [
Summer Qin3c2b5722021-05-26 10:43:45 +0800478 ("arm/mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800479 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhang9b1aef92021-03-12 15:36:44 +0800480 # Profile Large is only supported by AN521
Summer Qin3c2b5722021-05-26 10:43:45 +0800481 ("arm/mps2/an519", "*", "*",
Xinyu Zhang9b1aef92021-03-12 15:36:44 +0800482 "*", "*", "*", "*", "*", "*", "*", "profile_large", "*"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800483 ("arm/musca_b1/sse_200", "*", "*",
Xinyu Zhang9b1aef92021-03-12 15:36:44 +0800484 "*", "*", "*", "*", "*", "*", "*", "profile_large", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800485 ]
486 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800487
Karl Zhangaff558a2020-05-15 14:28:23 +0100488config_tfm_test_OTP = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800489 "tfm_platform": ["arm/musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800490 "toolchain_file": ["toolchain_ARMCLANG.cmake",
491 "toolchain_GNUARM.cmake"],
492 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800493 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800494 "test_regression": [True, False],
495 "test_psa_api": ["OFF"],
496 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800497 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800498 "with_bl2": [True],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800499 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800500 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800501 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800502 },
503 "common_params": _common_tfm_builder_cfg,
504 "invalid": _common_tfm_invalid_configs + []
505 }
Karl Zhangaff558a2020-05-15 14:28:23 +0100506
Minos Galanakisea421232019-06-20 17:11:28 +0100507config_MUSCA_B1 = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800508 "tfm_platform": ["arm/musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800509 "toolchain_file": ["toolchain_ARMCLANG.cmake",
510 "toolchain_GNUARM.cmake"],
511 "psa_api": [True, False],
512 "isolation_level": ["1", "2"],
513 "test_regression": [True, False],
514 "test_psa_api": ["OFF"],
515 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800516 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800517 "with_bl2": [True],
518 "with_ns": [True, False],
519 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800520 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800521 },
522 "common_params": _common_tfm_builder_cfg,
523 "invalid": _common_tfm_invalid_configs + []
524 }
Minos Galanakisea421232019-06-20 17:11:28 +0100525
Mark Horvath8d281cd2020-12-07 15:20:26 +0100526config_MUSCA_B1_SE = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800527 "tfm_platform": ["arm/musca_b1/secure_enclave"],
Mark Horvath8d281cd2020-12-07 15:20:26 +0100528 "toolchain_file": ["toolchain_ARMCLANG.cmake",
529 "toolchain_GNUARM.cmake"],
530 "psa_api": [True],
531 "isolation_level": ["1"],
532 "test_regression": [False],
533 "test_psa_api": ["OFF"],
534 "cmake_build_type": ["Debug", "Release"],
535 "with_otp": ["off"],
536 "with_bl2": [True],
537 "with_ns": [False],
538 "profile": [""],
539 "partition_ps": ["ON"],
540 },
541 "common_params": _common_tfm_builder_cfg,
542 "invalid": _common_tfm_invalid_configs + []
543 }
544
Karl Zhangeffed972020-06-30 15:48:01 +0800545config_MUSCA_S1 = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800546 "tfm_platform": ["arm/musca_s1"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800547 "toolchain_file": ["toolchain_ARMCLANG.cmake",
548 "toolchain_GNUARM.cmake"],
549 "psa_api": [True, False],
550 "isolation_level": ["1", "2"],
551 "test_regression": [True, False],
552 "test_psa_api": ["OFF"],
553 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800554 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800555 "with_bl2": [True],
556 "with_ns": [True, False],
557 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800558 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800559 },
560 "common_params": _common_tfm_builder_cfg,
561 "invalid": _common_tfm_invalid_configs + []
562 }
Karl Zhangeffed972020-06-30 15:48:01 +0800563
Karl Zhangaff558a2020-05-15 14:28:23 +0100564config_release = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800565 "tfm_platform": ["arm/mps2/an521", "arm/mps2/an519",
566 "arm/musca_b1/sse_200", "arm/musca_s1",
567 "arm/mps3/an524"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800568 "toolchain_file": ["toolchain_ARMCLANG.cmake",
569 "toolchain_GNUARM.cmake"],
570 "psa_api": [True, False],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800571 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800572 "test_regression": [True, False],
573 "test_psa_api": ["OFF"],
574 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800575 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800576 "with_bl2": [True, False],
577 "with_ns": [True, False],
578 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800579 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800580 },
581 "common_params": _common_tfm_builder_cfg,
582 "invalid": _common_tfm_invalid_configs + [
Summer Qin3c2b5722021-05-26 10:43:45 +0800583 ("arm/mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800584 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800585 ]
586 }
Karl Zhangaff558a2020-05-15 14:28:23 +0100587
588# Configure build manager to build several combinations
589config_AN521_PSA_API = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800590 "tfm_platform": ["arm/mps2/an521", "arm/mps2/an519",
591 "arm/musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800592 "toolchain_file": ["toolchain_GNUARM.cmake",
593 "toolchain_ARMCLANG.cmake"],
594 "psa_api": [True, False],
595 "isolation_level": ["1", "2"],
596 "test_regression": [False],
597 "test_psa_api": ["IPC",
598 "CRYPTO",
599 "PROTECTED_STORAGE",
600 "INITIAL_ATTESTATION",
601 "INTERNAL_TRUSTED_STORAGE"],
602 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800603 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800604 "with_bl2": [True],
605 "with_ns": [True, False],
606 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800607 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100608 },
609 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800610 "invalid": _common_tfm_invalid_configs + [
Summer Qin3c2b5722021-05-26 10:43:45 +0800611 ("arm/mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800612 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800613 ]
Karl Zhangaff558a2020-05-15 14:28:23 +0100614 }
615
Karl Zhangaff558a2020-05-15 14:28:23 +0100616config_AN521_PSA_IPC = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800617 "tfm_platform": ["arm/mps2/an521", "arm/mps2/an519",
618 "arm/musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800619 "toolchain_file": ["toolchain_GNUARM.cmake",
620 "toolchain_ARMCLANG.cmake"],
621 "psa_api": [True],
622 "isolation_level": ["1", "2"],
623 "test_regression": [False],
624 "test_psa_api": ["IPC"],
625 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800626 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800627 "with_bl2": [True],
628 "with_ns": [True, False],
629 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800630 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100631 },
632 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800633 "invalid": _common_tfm_invalid_configs + [
Summer Qin3c2b5722021-05-26 10:43:45 +0800634 ("arm/mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800635 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800636 ]
Karl Zhangaff558a2020-05-15 14:28:23 +0100637 }
638
Karl Zhang14573bc2020-06-08 09:23:21 +0800639config_nightly = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800640 "tfm_platform": ["arm/mps2/an521", "arm/mps2/an519",
641 "arm/musca_b1/sse_200", "arm/musca_s1",
642 "arm/mps3/an524", "cypress/psoc64",
643 "arm/musca_b1/secure_enclave"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800644 "toolchain_file": ["toolchain_GNUARM.cmake",
645 "toolchain_ARMCLANG.cmake"],
646 "psa_api": [True, False],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800647 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800648 "test_regression": [True, False],
649 "test_psa_api": ["OFF"],
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800650 "cmake_build_type": ["Debug", "Release", "Minsizerel", "RelWithDebInfo"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800651 "with_otp": ["off"],
Xinyu Zhang55363aa2020-11-16 16:38:30 +0800652 "with_bl2": [True],
653 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800654 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800655 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800656 },
657 "common_params": _common_tfm_builder_cfg,
658 "invalid": _common_tfm_invalid_configs + [
Summer Qin3c2b5722021-05-26 10:43:45 +0800659 ("arm/mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800660 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800661 ("cypress/psoc64", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800662 "*", "*", "Debug", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800663 ("cypress/psoc64", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800664 "*", "*", "*", "*", True, True, "*", "*"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800665 ("arm/mps2/an521", "*", "*", "*",
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800666 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800667 ("arm/mps2/an519", "*", "*", "*",
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800668 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800669 ("arm/musca_b1/sse_200", "*", "*", "*",
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800670 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800671 ("arm/musca_s1", "*", "*", "*",
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800672 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800673 ("arm/mps3/an524", "*", "*", "*",
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800674 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800675 ]
676 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800677
Karl Zhang14573bc2020-06-08 09:23:21 +0800678config_nightly_profile = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800679 "tfm_platform": ["arm/mps2/an519", "arm/mps2/an521",
680 "arm/musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800681 "toolchain_file": ["toolchain_ARMCLANG.cmake",
682 "toolchain_GNUARM.cmake"],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800683 "psa_api": [True, False],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800684 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800685 "test_regression": [True, False],
686 "test_psa_api": ["OFF"],
687 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800688 "with_otp": ["off"],
Xinyu Zhang55363aa2020-11-16 16:38:30 +0800689 "with_bl2": [True],
690 "with_ns": [True],
Xinyu Zhang9b1aef92021-03-12 15:36:44 +0800691 "profile": ["profile_small", "profile_medium", "profile_large"],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800692 "partition_ps": ["ON", "OFF"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800693 },
694 "common_params": _common_tfm_builder_cfg,
695 "invalid": _common_tfm_invalid_configs + [
Summer Qin3c2b5722021-05-26 10:43:45 +0800696 ("arm/mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800697 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhang9b1aef92021-03-12 15:36:44 +0800698 # Profile Large is only supported by AN521
Summer Qin3c2b5722021-05-26 10:43:45 +0800699 ("arm/mps2/an519", "*", "*",
Xinyu Zhang9b1aef92021-03-12 15:36:44 +0800700 "*", "*", "*", "*", "*", "*", "*", "profile_large", "*"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800701 ("arm/musca_b1/sse_200", "*", "*",
Xinyu Zhang9b1aef92021-03-12 15:36:44 +0800702 "*", "*", "*", "*", "*", "*", "*", "profile_large", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800703 ]
704 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800705
Karl Zhang14573bc2020-06-08 09:23:21 +0800706config_nightly_PSA_API = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800707 "tfm_platform": ["arm/mps2/an521", "arm/musca_b1/sse_200",
708 "arm/musca_s1"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800709 "toolchain_file": ["toolchain_GNUARM.cmake",
710 "toolchain_ARMCLANG.cmake"],
711 "psa_api": [True, False],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800712 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800713 "test_regression": [False],
714 "test_psa_api": ["CRYPTO",
715 "PROTECTED_STORAGE",
716 "INITIAL_ATTESTATION",
717 "INTERNAL_TRUSTED_STORAGE"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800718 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800719 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800720 "with_bl2": [True],
Xinyu Zhang55363aa2020-11-16 16:38:30 +0800721 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800722 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800723 "partition_ps": ["ON"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800724 },
725 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800726 "invalid": _common_tfm_invalid_configs + []
Karl Zhang14573bc2020-06-08 09:23:21 +0800727 }
728
Karl Zhang14573bc2020-06-08 09:23:21 +0800729config_nightly_PSA_FF = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800730 "tfm_platform": ["arm/mps2/an521", "arm/musca_b1/sse_200",
731 "arm/musca_s1"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800732 "toolchain_file": ["toolchain_GNUARM.cmake",
733 "toolchain_ARMCLANG.cmake"],
734 "psa_api": [True],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800735 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800736 "test_regression": [False],
737 "test_psa_api": ["IPC"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800738 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800739 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800740 "with_bl2": [True],
Xinyu Zhang55363aa2020-11-16 16:38:30 +0800741 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800742 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800743 "partition_ps": ["ON"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800744 },
745 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800746 "invalid": _common_tfm_invalid_configs + []
Karl Zhang14573bc2020-06-08 09:23:21 +0800747 }
748
Karl Zhang14573bc2020-06-08 09:23:21 +0800749config_nightly_OTP = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800750 "tfm_platform": ["arm/musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800751 "toolchain_file": ["toolchain_GNUARM.cmake",
752 "toolchain_ARMCLANG.cmake"],
753 "psa_api": [True, False],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800754 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800755 "test_regression": [True],
756 "test_psa_api": ["OFF"],
757 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800758 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800759 "with_bl2": [True],
Xinyu Zhang55363aa2020-11-16 16:38:30 +0800760 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800761 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800762 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800763 },
764 "common_params": _common_tfm_builder_cfg,
765 "invalid": _common_tfm_invalid_configs + []
766 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800767
Karl Zhang14573bc2020-06-08 09:23:21 +0800768config_pp_test = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800769 "tfm_platform": ["arm/mps2/an521", "arm/mps2/an519",
770 "arm/musca_b1/sse_200", "arm/musca_s1"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800771 "toolchain_file": ["toolchain_GNUARM.cmake",
772 "toolchain_ARMCLANG.cmake"],
773 "psa_api": [True, False],
Karl Zhangde36b772021-01-08 10:17:03 +0800774 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800775 "test_regression": [True],
776 "test_psa_api": ["OFF"],
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800777 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800778 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800779 "with_bl2": [True],
780 "with_ns": [True, False],
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800781 "profile": ["", "profile_small", "profile_medium"],
782 "partition_ps": ["ON", "OFF"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800783 },
784 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangf86d42b2021-05-17 10:51:35 +0800785 "valid": [
Summer Qin3c2b5722021-05-26 10:43:45 +0800786 ("arm/mps2/an521", "toolchain_GNUARM.cmake",
Xinyu Zhangf86d42b2021-05-17 10:51:35 +0800787 False, "1", False, "OFF", "Debug",
788 "off", True, True, "", "ON"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800789 ("arm/mps2/an521", "toolchain_ARMCLANG.cmake",
Xinyu Zhangf86d42b2021-05-17 10:51:35 +0800790 True, "2", False, "OFF", "Debug",
791 "off", True, True, "", "ON"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800792 ("arm/mps2/an521", "toolchain_ARMCLANG.cmake",
Xinyu Zhangf86d42b2021-05-17 10:51:35 +0800793 True, "3", False, "OFF", "Release",
794 "off", True, True, "", "ON"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800795 ("arm/mps2/an521", "toolchain_GNUARM.cmake",
Xinyu Zhangf86d42b2021-05-17 10:51:35 +0800796 True, "2", False, "OFF", "Debug",
797 "off", True, True, "profile_medium", "ON"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800798 ("arm/mps2/an521", "toolchain_GNUARM.cmake",
Xinyu Zhangf86d42b2021-05-17 10:51:35 +0800799 True, "3", False, "OFF", "Debug",
800 "off", True, True, "profile_large", "ON"),
801 ],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800802 "invalid": _common_tfm_invalid_configs + [
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800803 # invalid configs that are not supported by TF-M
Summer Qin3c2b5722021-05-26 10:43:45 +0800804 ("arm/musca_s1", "*", "*", "*", "*", "*",
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800805 "*", "*", "*", "*", "profile_medium", "*"),
806 # valid configs supported by TF-M but not needed in per-patch
807 ("*", "*", "*", "1", "*", "*", "Release",
808 "*", "*", "*", "*", "*"),
809 ("*", "*", "*", "1", "*", "*", "Minsizerel",
810 "*", "*", "*", "*", "*"),
811 ("*", "*", "*", "2", "*", "*", "Debug",
812 "*", "*", "*", "*", "*"),
813 ("*", "*", "*", "2", "*", "*", "Minsizerel",
814 "*", "*", "*", "*", "*"),
815 ("*", "*", "*", "3", "*", "*", "Debug",
816 "*", "*", "*", "*", "*"),
817 ("*", "*", "*", "3", "*", "*", "Release",
818 "*", "*", "*", "*", "*"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800819 ("arm/mps2/an519", "*", "*", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800820 "*", "*", "*", "*", "profile_small", "*"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800821 ("arm/musca_s1", "*", "*", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800822 "*", "*", "*", "*", "profile_small", "*"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800823 ("arm/mps2/an519", "*", "*", "*", "*", "*",
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800824 "*", "*", "*", "*", "profile_medium", "*"),
Summer Qin3c2b5722021-05-26 10:43:45 +0800825 ("arm/mps2/an521", "*", "*", "*", "*", "*",
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800826 "*", "*", "*", "*", "profile_medium", "*"),
827 ("*", "toolchain_GNUARM.cmake", "*", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800828 "*", "*", "*", "*", "profile_small", "*"),
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800829 ("*", "toolchain_ARMCLANG.cmake", "*", "*", "*", "*",
830 "*", "*", "*", "*", "profile_medium", "*"),
Xinyu Zhangf86d42b2021-05-17 10:51:35 +0800831 ("*", "toolchain_ARMCLANG.cmake", False, "*", "*", "*",
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800832 "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800833 ]
834 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800835
Karl Zhang14573bc2020-06-08 09:23:21 +0800836config_pp_OTP = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800837 "tfm_platform": ["arm/musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800838 "toolchain_file": ["toolchain_GNUARM.cmake"],
839 "psa_api": [True, False],
840 "isolation_level": ["1", "2"],
841 "test_regression": [True],
842 "test_psa_api": ["OFF"],
843 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800844 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800845 "with_bl2": [True],
846 "with_ns": [True, False],
847 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800848 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800849 },
850 "common_params": _common_tfm_builder_cfg,
851 "invalid": _common_tfm_invalid_configs + []
852 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800853
854# Configure build manager to build several combinations
855config_pp_PSA_API = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800856 "tfm_platform": ["arm/mps2/an521"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800857 "toolchain_file": ["toolchain_GNUARM.cmake"],
858 "psa_api": [True],
859 "isolation_level": ["2"],
860 "test_regression": [False],
861 "test_psa_api": ["IPC",
862 "CRYPTO",
863 "PROTECTED_STORAGE",
864 "INITIAL_ATTESTATION",
865 "INTERNAL_TRUSTED_STORAGE"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800866 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800867 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800868 "with_bl2": [True],
869 "with_ns": [True, False],
870 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800871 "partition_ps": ["ON"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800872 },
873 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800874 "invalid": _common_tfm_invalid_configs + []
Karl Zhang14573bc2020-06-08 09:23:21 +0800875 }
876
Karl Zhang14573bc2020-06-08 09:23:21 +0800877config_pp_PSoC64 = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800878 "tfm_platform": ["cypress/psoc64"],
879 "toolchain_file": ["toolchain_GNUARM.cmake"],
880 "psa_api": [True],
881 "isolation_level": ["1", "2"],
882 "test_regression": [True],
883 "test_psa_api": ["OFF"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800884 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800885 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800886 "with_bl2": [False],
887 "with_ns": [True, False],
888 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800889 "partition_ps": ["ON"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800890 },
891 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800892 "invalid": _common_tfm_invalid_configs + []
Karl Zhang14573bc2020-06-08 09:23:21 +0800893 }
894
Xinyu Zhangf25856a2021-06-17 14:06:46 +0800895config_cov_an519 = {"seed_params": {
896 "tfm_platform": ["arm/mps2/an519"],
897 "toolchain_file": ["toolchain_GNUARM.cmake"],
898 "psa_api": [True, False],
899 "isolation_level": ["1", "2", "3"],
900 "test_regression": [True, False],
901 "test_psa_api": ["OFF"],
902 "cmake_build_type": ["Debug", "Release"],
903 "with_otp": ["off"],
904 "with_bl2": [True],
905 "with_ns": [True],
906 "profile": ["", "profile_small", "profile_medium"],
907 "partition_ps": ["ON", "OFF"],
908 },
909 "common_params": _common_tfm_builder_cfg,
910 "invalid": _common_tfm_invalid_configs + []
911 }
912
913config_cov_an521 = {"seed_params": {
914 "tfm_platform": ["arm/mps2/an521"],
915 "toolchain_file": ["toolchain_GNUARM.cmake"],
916 "psa_api": [True, False],
917 "isolation_level": ["1", "2", "3"],
918 "test_regression": [True, False],
919 "test_psa_api": ["OFF"],
920 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
921 "with_otp": ["off"],
922 "with_bl2": [True],
923 "with_ns": [True],
924 "profile": ["", "profile_small", "profile_medium", "profile_large"],
925 "partition_ps": ["ON", "OFF"],
926 },
927 "common_params": _common_tfm_builder_cfg,
928 "invalid": _common_tfm_invalid_configs + []
929 }
930
Minos Galanakisea421232019-06-20 17:11:28 +0100931# Configruation used for document building
932config_doxygen = {"common_params": {
933 "config_type": "tf-m_documents",
934 "codebase_root_dir": "tf-m",
Summer Qin3c2b5722021-05-26 10:43:45 +0800935 "build_cmds": {"all": ["-DTFM_PLATFORM=arm/mps2/an521 "
Fathi Boudra324fee72020-11-20 10:31:12 +0100936 "-DTFM_TOOLCHAIN_FILE=%(_tfm_code_dir_)s/toolchain_GNUARM.cmake"
Minos Galanakisea421232019-06-20 17:11:28 +0100937 "-DCMAKE_BUILD_TYPE=Debug "
Minos Galanakisea421232019-06-20 17:11:28 +0100938 "%(_tbm_code_dir_)s/",
Xinyu Zhangb708f572020-09-15 11:43:46 +0800939 "cmake --build ./ -- docs"]},
940 "artifact_capture_rex": r'%(_tbm_build_dir_)s/docs/'
941 r'reference_manual/(?:latex|html)'
Minos Galanakisea421232019-06-20 17:11:28 +0100942 r'/(\w+\.(?:html|md|pdf))$',
943 },
Xinyu Zhangb708f572020-09-15 11:43:46 +0800944 "invalid": _common_tfm_invalid_configs + []
Minos Galanakisea421232019-06-20 17:11:28 +0100945 }
946
Karl Zhangaff558a2020-05-15 14:28:23 +0100947# Configuration used in testing
Minos Galanakisea421232019-06-20 17:11:28 +0100948config_debug = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800949 "tfm_platform": ["arm/mps2/an521"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800950 "toolchain_file": ["toolchain_ARMCLANG.cmake"],
951 "psa_api": [False],
952 "isolation_level": ["1"],
953 "test_regression": [False],
954 "test_psa_api": ["OFF"],
Minos Galanakisea421232019-06-20 17:11:28 +0100955 "cmake_build_type": ["Debug"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800956 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800957 "with_bl2": [True],
958 "with_ns": [True],
959 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800960 "partition_ps": ["ON"],
Minos Galanakisea421232019-06-20 17:11:28 +0100961 },
962 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800963 "invalid": _common_tfm_invalid_configs + []
Minos Galanakisea421232019-06-20 17:11:28 +0100964 }
965
Dean Birch4c6ad622020-03-13 11:28:03 +0000966# Configuration used in CI
Xinyu Zhangb708f572020-09-15 11:43:46 +0800967config_ci = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800968 "tfm_platform": ["arm/mps2/an521"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800969 "toolchain_file": ["toolchain_ARMCLANG.cmake",
970 "toolchain_GNUARM.cmake"],
971 "psa_api": [True, False],
972 "isolation_level": ["1", "2"],
973 "test_regression": [True, False],
974 "test_psa_api": ["OFF"],
975 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800976 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800977 "with_bl2": [True, False],
978 "with_ns": [True],
979 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800980 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800981 },
982 "common_params": _common_tfm_builder_cfg,
983 "invalid": _common_tfm_invalid_configs + [
984 ("*", "toolchain_ARMCLANG.cmake", True, "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800985 "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800986 ("*", "toolchain_ARMCLANG.cmake", False, "1", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800987 "*", "*", False, "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800988 ]
989 }
Matthew Hartfb6fd362020-03-04 21:03:59 +0000990
Xinyu Zhangb708f572020-09-15 11:43:46 +0800991config_lava_debug = {"seed_params": {
Summer Qin3c2b5722021-05-26 10:43:45 +0800992 "tfm_platform": ["arm/mps2/an521", "arm/mps2/an519"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800993 "toolchain_file": ["toolchain_GNUARM.cmake"],
994 "psa_api": [True, False],
995 "isolation_level": ["1", "2"],
996 "test_regression": [True],
997 "test_psa_api": ["OFF"],
998 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800999 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +08001000 "with_bl2": [True, False],
1001 "with_ns": [True, False],
1002 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +08001003 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +08001004 },
1005 "common_params": _common_tfm_builder_cfg,
1006 "invalid": _common_tfm_invalid_configs + [
Summer Qin3c2b5722021-05-26 10:43:45 +08001007 ("arm/mps2/an521", "toolchain_GNUARM.cmake", True, "2", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +08001008 "*", "*", True, "*", "*", "*")
Xinyu Zhangb708f572020-09-15 11:43:46 +08001009 ]
1010 }
Dean Birch4c6ad622020-03-13 11:28:03 +00001011
Karl Zhangaff558a2020-05-15 14:28:23 +01001012_builtin_configs = {
Karl Zhang14573bc2020-06-08 09:23:21 +08001013 #release test group
Karl Zhangaff558a2020-05-15 14:28:23 +01001014 "tfm_test": config_tfm_test,
1015 "tfm_test2": config_tfm_test2,
Karl Zhang14573bc2020-06-08 09:23:21 +08001016 "tfm_profile": config_tfm_profile,
Karl Zhangaff558a2020-05-15 14:28:23 +01001017 "tfm_test_otp": config_tfm_test_OTP,
1018 "psa_api": config_PSA_API,
1019 "psa_api_otp": config_PSA_API_OTP,
1020 "psa_ff": config_PSA_FF,
1021 "psa_ff_otp": config_PSA_FF_OTP,
Karl Zhang14573bc2020-06-08 09:23:21 +08001022 "tfm_psoc64": config_PSOC64,
1023
1024 #nightly test group
1025 "nightly_test": config_nightly,
1026 "nightly_profile": config_nightly_profile,
1027 "nightly_psa_api": config_nightly_PSA_API,
1028 "nightly_ff": config_nightly_PSA_FF,
1029 "nightly_otp": config_nightly_OTP,
1030
1031 #per patch test group
1032 "pp_test": config_pp_test,
1033 "pp_OTP": config_pp_OTP,
1034 "pp_PSA_API": config_pp_PSA_API,
1035 "pp_psoc64": config_pp_PSoC64,
1036
Xinyu Zhangf25856a2021-06-17 14:06:46 +08001037 #code coverage test group
1038 "coverage_an519": config_cov_an519,
1039 "coverage_an521": config_cov_an521,
1040
Karl Zhang14573bc2020-06-08 09:23:21 +08001041 #full test group in the old CI
Karl Zhangaff558a2020-05-15 14:28:23 +01001042 "full": config_full,
Karl Zhang14573bc2020-06-08 09:23:21 +08001043
1044 #specific test group
Karl Zhangaff558a2020-05-15 14:28:23 +01001045 "an524": config_AN524,
Minos Galanakisea421232019-06-20 17:11:28 +01001046 "an521": config_AN521,
Karl Zhang14573bc2020-06-08 09:23:21 +08001047 "an521_psa_api": config_AN521_PSA_API,
1048 "an521_psa_ipc": config_AN521_PSA_IPC,
Minos Galanakisea421232019-06-20 17:11:28 +01001049 "an519": config_AN519,
Minos Galanakisea421232019-06-20 17:11:28 +01001050 "musca_b1": config_MUSCA_B1,
Mark Horvath8d281cd2020-12-07 15:20:26 +01001051 "musca_b1_se": config_MUSCA_B1_SE,
Karl Zhangeffed972020-06-30 15:48:01 +08001052 "musca_s1": config_MUSCA_S1,
Karl Zhang96dfe2d2020-05-11 11:31:40 +08001053 "psoc64": config_PSOC64,
Minos Galanakisea421232019-06-20 17:11:28 +01001054 "ipc": config_IPC,
1055 "doxygen": config_doxygen,
Dean Birch4c6ad622020-03-13 11:28:03 +00001056 "debug": config_debug,
Karl Zhangaff558a2020-05-15 14:28:23 +01001057 "release": config_release,
Matthew Hartfb6fd362020-03-04 21:03:59 +00001058 "debug": config_debug,
Karl Zhang14573bc2020-06-08 09:23:21 +08001059
1060 #DevOps team test group
Matthew Hartfb6fd362020-03-04 21:03:59 +00001061 "lava_debug": config_lava_debug,
Xinyu Zhanga1000582020-12-04 15:25:24 +08001062 "ci": config_ci}
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +01001063
1064if __name__ == '__main__':
1065 import os
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +01001066
Minos Galanakisea421232019-06-20 17:11:28 +01001067 # Default behavior is to export refference config when called
1068 _dir = os.getcwd()
1069 from utils import save_json
1070 for _cname, _cfg in _builtin_configs.items():
1071 _fname = os.path.join(_dir, _cname + ".json")
1072 print("Exporting config %s" % _fname)
1073 save_json(_fname, _cfg)