blob: f21453b3d4856698766093f4004d0fe7b18f7550 [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"],
Xinyu Zhang694eb492020-11-04 18:29:08 +080077 "musca_a": [("srec_cat "
Xinyu Zhangb708f572020-09-15 11:43:46 +080078 "%(_tbm_build_dir_)s/bin/"
79 "bl2.bin "
Minos Galanakisea421232019-06-20 17:11:28 +010080 "-Binary -offset 0x200000 "
Raef Coles543aab32020-12-03 11:12:02 +000081 "-fill 0xFF 0x200000 0x220000 "
Xinyu Zhangb708f572020-09-15 11:43:46 +080082 "%(_tbm_build_dir_)s/bin/"
Xinyu Zhang694eb492020-11-04 18:29:08 +080083 "tfm_s_ns_signed.bin "
Raef Coles543aab32020-12-03 11:12:02 +000084 "-Binary -offset 0x220000 "
85 "-fill 0xFF 0x220000 0xA00000 "
86 "-o %(_tbm_build_dir_)s/bin/"
Xinyu Zhang694eb492020-11-04 18:29:08 +080087 "tfm.hex -Intel")],
Mark Horvath8d281cd2020-12-07 15:20:26 +010088 "musca_b1/sse_200": [("srec_cat "
89 "%(_tbm_build_dir_)s/bin/"
90 "bl2.bin "
91 "-Binary -offset 0xA000000 "
92 "-fill 0xFF 0xA000000 0xA020000 "
93 "%(_tbm_build_dir_)s/bin/"
94 "tfm_s_ns_signed.bin "
95 "-Binary -offset 0xA020000 "
96 "-fill 0xFF 0xA020000 0xA200000 "
97 "-o %(_tbm_build_dir_)s/bin/"
98 "tfm.hex -Intel")],
Xinyu Zhang694eb492020-11-04 18:29:08 +080099 "musca_s1": [("srec_cat "
Xinyu Zhangb708f572020-09-15 11:43:46 +0800100 "%(_tbm_build_dir_)s/bin/"
101 "bl2.bin "
Karl Zhangeffed972020-06-30 15:48:01 +0800102 "-Binary -offset 0xA000000 "
Raef Coles543aab32020-12-03 11:12:02 +0000103 "-fill 0xFF 0xA000000 0xA020000 "
Xinyu Zhangb708f572020-09-15 11:43:46 +0800104 "%(_tbm_build_dir_)s/bin/"
Xinyu Zhang694eb492020-11-04 18:29:08 +0800105 "tfm_s_ns_signed.bin "
Raef Coles543aab32020-12-03 11:12:02 +0000106 "-Binary -offset 0xA020000 "
107 "-fill 0xFF 0xA020000 0xA200000 "
108 "-o %(_tbm_build_dir_)s/bin/"
Xinyu Zhang694eb492020-11-04 18:29:08 +0800109 "tfm.hex -Intel")]
Minos Galanakisea421232019-06-20 17:11:28 +0100110 },
111
112 # (Optional) If set will fail if those artefacts are missing post build
113 "required_artefacts": {"all": [
Xinyu Zhangb708f572020-09-15 11:43:46 +0800114 "%(_tbm_build_dir_)s/bin/"
115 "tfm_s.bin",
116 "%(_tbm_build_dir_)s/bin/"
117 "tfm_ns.bin"],
Xinyu Zhang694eb492020-11-04 18:29:08 +0800118 "musca_a": [
Xinyu Zhangb708f572020-09-15 11:43:46 +0800119 "%(_tbm_build_dir_)s/bin/"
120 "tfm.hex",
121 "%(_tbm_build_dir_)s/bin/"
Xinyu Zhang694eb492020-11-04 18:29:08 +0800122 "bl2.bin",
Xinyu Zhangb708f572020-09-15 11:43:46 +0800123 "%(_tbm_build_dir_)s/bin/"
124 "tfm_sign.bin"],
Mark Horvath8d281cd2020-12-07 15:20:26 +0100125 "musca_b1/sse_200": [
Xinyu Zhangb708f572020-09-15 11:43:46 +0800126 "%(_tbm_build_dir_)s/bin/"
127 "tfm.hex",
128 "%(_tbm_build_dir_)s/bin/"
Xinyu Zhang694eb492020-11-04 18:29:08 +0800129 "bl2.bin",
Xinyu Zhangb708f572020-09-15 11:43:46 +0800130 "%(_tbm_build_dir_)s/bin/"
131 "tfm_sign.bin"],
Xinyu Zhang694eb492020-11-04 18:29:08 +0800132 "musca_s1": [
Xinyu Zhangb708f572020-09-15 11:43:46 +0800133 "%(_tbm_build_dir_)s/bin/"
134 "tfm.hex",
135 "%(_tbm_build_dir_)s/bin/"
Xinyu Zhang694eb492020-11-04 18:29:08 +0800136 "bl2.bin",
Xinyu Zhangb708f572020-09-15 11:43:46 +0800137 "%(_tbm_build_dir_)s/bin/"
138 "tfm_sign.bin"]
Minos Galanakisea421232019-06-20 17:11:28 +0100139 }
140}
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +0100141
Xinyu Zhangb708f572020-09-15 11:43:46 +0800142# List of all build configs that are impossible under all circumstances
143_common_tfm_invalid_configs = [
Xinyu Zhang6bf39f52021-03-19 17:03:09 +0800144 # Load range overlap on Musca B1 for IPC Debug type: T895
145 ("musca_b1/sse_200", "toolchain_ARMCLANG.cmake", "*", "*", "*", "IPC", "Debug", "*", "*", "*", "*", "*"),
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800146 # LVL2 and LVL3 requires PSA api
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800147 ("*", "*", False, "2", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800148 ("*", "*", False, "3", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800149 # Regression requires NS
150 ("*", "*", "*", "*", True, "*", "*", "*", "*", False, "*", "*"),
Xinyu Zhang11d66112020-11-04 15:38:29 +0800151 # psoc64 requires PSA api
152 ("cypress/psoc64", "*", False, "*", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800153 # No PSA_ACK with regression
154 ("*", "*", "*", "*", True, "IPC", "*", "*", "*", "*", "*", "*"),
155 ("*", "*", "*", "*", True, "CRYPTO", "*", "*", "*", "*", "*", "*"),
156 ("*", "*", "*", "*", True, "PROTECTED_STORAGE", "*", "*", "*", "*", "*", "*"),
157 ("*", "*", "*", "*", True, "INITIAL_ATTESTATION", "*", "*", "*", "*", "*", "*"),
158 ("*", "*", "*", "*", True, "INTERNAL_TRUSTED_STORAGE", "*", "*", "*", "*", "*", "*"),
159 # PSA_ACK requires NS
160 ("*", "*", "*", "*", "*", "IPC", "*", "*", "*", False, "*", "*"),
161 ("*", "*", "*", "*", "*", "CRYPTO", "*", "*", "*", False, "*", "*"),
162 ("*", "*", "*", "*", "*", "PROTECTED_STORAGE", "*", "*", "*", False, "*", "*"),
163 ("*", "*", "*", "*", "*", "INITIAL_ATTESTATION", "*", "*", "*", False, "*", "*"),
164 ("*", "*", "*", "*", "*", "INTERNAL_TRUSTED_STORAGE", "*", "*", "*", False, "*", "*"),
Xinyu Zhang3227da42021-03-19 17:37:17 +0800165 # PSA_ACK does not support LVL3
166 ("*", "*", "*", "3", "*", "IPC", "*", "*", "*", "*", "*", "*"),
167 ("*", "*", "*", "3", "*", "CRYPTO", "*", "*", "*", "*", "*", "*"),
168 ("*", "*", "*", "3", "*", "PROTECTED_STORAGE", "*", "*", "*", "*", "*", "*"),
169 ("*", "*", "*", "3", "*", "INITIAL_ATTESTATION", "*", "*", "*", "*", "*", "*"),
170 ("*", "*", "*", "3", "*", "INTERNAL_TRUSTED_STORAGE", "*", "*", "*", "*", "*", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800171 # Musca requires BL2
172 ("musca_a", "*", "*", "*", "*", "*", "*", "*", False, "*", "*", "*"),
Mark Horvath8d281cd2020-12-07 15:20:26 +0100173 ("musca_b1/sse_200", "*", "*", "*", "*", "*", "*", "*", False, "*", "*", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800174 ("musca_s1", "*", "*", "*", "*", "*", "*", "*", False, "*", "*", "*"),
175 # psoc64 cannot use BL2
176 ("cypress/psoc64", "*", "*", "*", "*", "*", "*", "*", True, "*", "*", "*"),
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800177 # psoc64 does not support Debug build type
178 ("cypress/psoc64", "*", "*", "*", "*", "*", "Debug", "*", "*", "*", "*", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800179 # Musca b1 does not support Profile S
Mark Horvath8d281cd2020-12-07 15:20:26 +0100180 ("musca_b1/sse_200", "*", "*", "*", "*", "*", "*", "*", "*", "*", "profile_small", "*"),
181 # Musca B1 Secure Enclave requires PSA api, BL2, and supports only Isolation Level 1
182 ("musca_b1/secure_enclave", "*", False, "*", "*", "*", "*", "*", "*", "*", "*", "*"),
183 ("musca_b1/secure_enclave", "*", "*", "*", "*", "*", "*", "*", False, "*", "*", "*"),
184 ("musca_b1/secure_enclave", "*", "*", "2", "*", "*", "*", "*", "*", "*", "*", "*"),
185 # Musca B1 Secure Enclave does not support tests, profiles, NS side building
186 ("musca_b1/secure_enclave", "*", "*", "*", True, "*", "*", "*", "*", "*", "*", "*"),
187 ("musca_b1/secure_enclave", "*", "*", "*", "*", "IPC", "*", "*", "*", "*", "*", "*"),
188 ("musca_b1/secure_enclave", "*", "*", "*", "*", "CRYPTO", "*", "*", "*", "*", "*", "*"),
189 ("musca_b1/secure_enclave", "*", "*", "*", "*", "PROTECTED_STORAGE", "*", "*", "*", "*", "*", "*"),
190 ("musca_b1/secure_enclave", "*", "*", "*", "*", "INITIAL_ATTESTATION", "*", "*", "*", "*", "*", "*"),
191 ("musca_b1/secure_enclave", "*", "*", "*", "*", "INTERNAL_TRUSTED_STORAGE", "*", "*", "*", "*", "*", "*"),
192 ("musca_b1/secure_enclave", "*", "*", "*", "*", "*", "*", "*", "*", "*", "profile_small", "*"),
193 ("musca_b1/secure_enclave", "*", "*", "*", "*", "*", "*", "*", "*", "*", "profile_medium", "*"),
194 ("musca_b1/secure_enclave", "*", "*", "*", "*", "*", "*", "*", "*", True, "*", "*"),
Xinyu Zhang709c1542020-11-02 18:41:07 +0800195 # PARTITION_PS could be OFF only for Profile S and M
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800196 ("*", "*", "*", "*", "*", "*", "*", "*", "*", "*", "", "OFF"),
Xinyu Zhang9b1aef92021-03-12 15:36:44 +0800197 ("*", "*", "*", "*", "*", "*", "*", "*", "*", "*", "profile_large", "OFF"),
Xinyu Zhang709c1542020-11-02 18:41:07 +0800198 # PARTITION_PS should be OFF for Profile S
199 ("*", "*", "*", "*", "*", "*", "*", "*", "*", "*", "profile_small", "ON"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800200 # Proile M only support for PSA_API
201 ("*", "*", False, "*", "*", "*", "*", "*", "*", "*", "profile_medium", "*"),
202 # Profile M only support for Isolation Level 2
203 ("*", "*", "*", "1", "*", "*", "*", "*", "*", "*", "profile_medium", "*"),
Xinyu Zhange8de4512020-11-13 10:37:56 +0800204 ("*", "*", "*", "3", "*", "*", "*", "*", "*", "*", "profile_medium", "*"),
Xinyu Zhang9b1aef92021-03-12 15:36:44 +0800205 # Profile L only support for Isolation Level 3
206 ("*", "*", "*", "1", "*", "*", "*", "*", "*", "*", "profile_large", "*"),
207 ("*", "*", "*", "2", "*", "*", "*", "*", "*", "*", "profile_large", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800208 # Profile S does not support PSA_API
209 ("*", "*", True, "*", "*", "*", "*", "*", "*", "*", "profile_small", "*"),
210 # Profile S only supports Isolation Level 2
211 ("*", "*", "*", "2", "*", "*", "*", "*", "*", "*", "profile_small", "*"),
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800212 # Only AN521 and MUSCA_B1 support Isolation Level 3
213 ("mps2/an519", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800214 ("mps3/an524", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800215 ("musca_a", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
216 ("musca_s1", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
217 ("cypress/psoc64", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
Mark Horvath8d281cd2020-12-07 15:20:26 +0100218 ("musca_b1/secure_enclave", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800219 ]
220
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +0100221# Configure build manager to build several combinations
Karl Zhangaff558a2020-05-15 14:28:23 +0100222config_AN524 = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800223 "tfm_platform": ["mps3/an524"],
224 "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_AN521 = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800242 "tfm_platform": ["mps2/an521"],
243 "toolchain_file": ["toolchain_GNUARM.cmake",
244 "toolchain_ARMCLANG.cmake"],
245 "psa_api": [True, False],
246 "isolation_level": ["1", "2"],
247 "test_regression": [True, False],
248 "test_psa_api": ["OFF"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100249 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800250 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800251 "with_bl2": [True, False],
252 "with_ns": [True, False],
253 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800254 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100255 },
256 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800257 "invalid": _common_tfm_invalid_configs + []
Karl Zhangaff558a2020-05-15 14:28:23 +0100258 }
259
Karl Zhangaff558a2020-05-15 14:28:23 +0100260config_PSA_API = {"seed_params": {
Karl Zhang5ccb5522021-03-01 22:16:29 +0800261 "tfm_platform": ["mps2/an521", "musca_b1/sse_200",
262 "musca_s1"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800263 "toolchain_file": ["toolchain_GNUARM.cmake",
264 "toolchain_ARMCLANG.cmake"],
265 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800266 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800267 "test_regression": [False],
268 "test_psa_api": ["CRYPTO",
269 "PROTECTED_STORAGE",
270 "INITIAL_ATTESTATION",
271 "INTERNAL_TRUSTED_STORAGE"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100272 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800273 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800274 "with_bl2": [True],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800275 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800276 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800277 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100278 },
279 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800280 "invalid": _common_tfm_invalid_configs + []
Karl Zhangaff558a2020-05-15 14:28:23 +0100281 }
282
Karl Zhangaff558a2020-05-15 14:28:23 +0100283config_PSA_FF = {"seed_params": {
Karl Zhang5ccb5522021-03-01 22:16:29 +0800284 "tfm_platform": ["mps2/an521", "musca_b1/sse_200",
285 "musca_s1"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800286 "toolchain_file": ["toolchain_GNUARM.cmake",
287 "toolchain_ARMCLANG.cmake"],
288 "psa_api": [True],
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": ["IPC"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100292 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800293 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800294 "with_bl2": [True],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800295 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800296 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800297 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100298 },
299 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800300 "invalid": _common_tfm_invalid_configs + []
Karl Zhangaff558a2020-05-15 14:28:23 +0100301 }
302
Karl Zhangaff558a2020-05-15 14:28:23 +0100303config_PSA_API_OTP = {"seed_params": {
Mark Horvath8d281cd2020-12-07 15:20:26 +0100304 "tfm_platform": ["musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800305 "toolchain_file": ["toolchain_GNUARM.cmake",
306 "toolchain_ARMCLANG.cmake"],
307 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800308 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800309 "test_regression": [False],
310 "test_psa_api": ["CRYPTO",
311 "PROTECTED_STORAGE",
312 "INITIAL_ATTESTATION",
313 "INTERNAL_TRUSTED_STORAGE"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100314 "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"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100320 },
321 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800322 "invalid": _common_tfm_invalid_configs + []
Karl Zhangaff558a2020-05-15 14:28:23 +0100323 }
Minos Galanakisea421232019-06-20 17:11:28 +0100324
Xinyu Zhangb708f572020-09-15 11:43:46 +0800325config_PSA_FF_OTP = {"seed_params": {
Mark Horvath8d281cd2020-12-07 15:20:26 +0100326 "tfm_platform": ["musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800327 "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": [False],
332 "test_psa_api": ["IPC"],
333 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800334 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800335 "with_bl2": [True],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800336 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800337 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800338 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800339 },
340 "common_params": _common_tfm_builder_cfg,
341 "invalid": _common_tfm_invalid_configs + []
342 }
343
Karl Zhang96dfe2d2020-05-11 11:31:40 +0800344config_PSOC64 = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800345 "tfm_platform": ["cypress/psoc64"],
346 "toolchain_file": ["toolchain_GNUARM.cmake",
347 "toolchain_ARMCLANG.cmake"],
348 "psa_api": [True],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800349 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800350 "test_regression": [True],
351 "test_psa_api": ["OFF"],
Karl Zhang96dfe2d2020-05-11 11:31:40 +0800352 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800353 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800354 "with_bl2": [False],
355 "with_ns": [True, False],
356 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800357 "partition_ps": ["ON"],
Karl Zhang96dfe2d2020-05-11 11:31:40 +0800358 },
359 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800360 "invalid": _common_tfm_invalid_configs + []
Karl Zhang96dfe2d2020-05-11 11:31:40 +0800361 }
362
Minos Galanakisea421232019-06-20 17:11:28 +0100363config_AN519 = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800364 "tfm_platform": ["mps2/an519"],
365 "toolchain_file": ["toolchain_GNUARM.cmake",
366 "toolchain_ARMCLANG.cmake"],
367 "psa_api": [True, False],
368 "isolation_level": ["1", "2"],
369 "test_regression": [True, False],
370 "test_psa_api": ["OFF"],
Minos Galanakisea421232019-06-20 17:11:28 +0100371 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800372 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800373 "with_bl2": [True, False],
374 "with_ns": [True, False],
375 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800376 "partition_ps": ["ON"],
Minos Galanakisea421232019-06-20 17:11:28 +0100377 },
378 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800379 "invalid": _common_tfm_invalid_configs + []
Minos Galanakisea421232019-06-20 17:11:28 +0100380 }
381
Xinyu Zhangb708f572020-09-15 11:43:46 +0800382config_IPC = {"seed_params": {
Mark Horvath8d281cd2020-12-07 15:20:26 +0100383 "tfm_platform": ["mps2/an521", "mps2/an519", "musca_a",
384 "musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800385 "toolchain_file": ["toolchain_GNUARM.cmake",
386 "toolchain_ARMCLANG.cmake"],
387 "psa_api": [True],
388 "isolation_level": ["1", "2"],
389 "test_regression": [True, False],
390 "test_psa_api": ["OFF"],
391 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800392 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800393 "with_bl2": [True, False],
394 "with_ns": [True, False],
395 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800396 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800397 },
Minos Galanakisea421232019-06-20 17:11:28 +0100398 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800399 "invalid": _common_tfm_invalid_configs + []
Minos Galanakisea421232019-06-20 17:11:28 +0100400 }
401
Minos Galanakisea421232019-06-20 17:11:28 +0100402config_full = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800403 "tfm_platform": ["mps2/an521", "mps2/an519",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100404 "musca_a", "musca_b1/sse_200",
Karl Zhang6919ff62021-01-05 14:17:44 +0800405 "mps3/an524", "cypress/psoc64",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100406 "musca_b1/secure_enclave"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800407 "toolchain_file": ["toolchain_GNUARM.cmake",
408 "toolchain_ARMCLANG.cmake"],
409 "psa_api": [True, False],
410 "isolation_level": ["1", "2"],
411 "test_regression": [True, False],
412 "test_psa_api": ["OFF"],
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800413 "cmake_build_type": ["Debug", "Release", "RelWithDebInfo"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800414 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800415 "with_bl2": [True, False],
416 "with_ns": [True, False],
417 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800418 "partition_ps": ["ON"],
Dean Birchd6ce2c82020-05-13 13:16:15 +0100419 },
420 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800421 "invalid": _common_tfm_invalid_configs + [
422 ("cypress/psoc64", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800423 "*", "*", "Debug", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800424 ("cypress/psoc64", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800425 "*", "*", "*", "*", True, True, "*", "*"),
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800426 ("mps2/an521", "*", "*", "*",
427 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
428 ("mps2/an519", "*", "*", "*",
429 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
430 ("musca_a", "*", "*", "*",
431 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Mark Horvath8d281cd2020-12-07 15:20:26 +0100432 ("musca_b1/sse_200", "*", "*", "*",
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800433 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800434 ("mps3/an524", "*", "*", "*",
435 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800436 ]
Karl Zhang81a76772020-05-11 18:28:52 +0800437 }
438
Karl Zhangaff558a2020-05-15 14:28:23 +0100439config_tfm_test = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800440 "tfm_platform": ["mps2/an521", "musca_a",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100441 "musca_b1/sse_200", "musca_s1"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800442 "toolchain_file": ["toolchain_ARMCLANG.cmake",
443 "toolchain_GNUARM.cmake"],
444 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800445 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800446 "test_regression": [True, False],
447 "test_psa_api": ["OFF"],
448 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800449 "with_otp": ["off"],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800450 "with_bl2": [True],
451 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800452 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800453 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800454 },
455 "common_params": _common_tfm_builder_cfg,
456 "invalid": _common_tfm_invalid_configs + []
457 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800458
Karl Zhangaff558a2020-05-15 14:28:23 +0100459config_tfm_test2 = {"seed_params": {
Karl Zhang6919ff62021-01-05 14:17:44 +0800460 "tfm_platform": ["mps2/an519", "mps3/an524"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800461 "toolchain_file": ["toolchain_ARMCLANG.cmake",
462 "toolchain_GNUARM.cmake"],
463 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800464 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800465 "test_regression": [True, False],
466 "test_psa_api": ["OFF"],
467 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800468 "with_otp": ["off"],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800469 "with_bl2": [True],
470 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800471 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800472 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800473 },
474 "common_params": _common_tfm_builder_cfg,
475 "invalid": _common_tfm_invalid_configs + [
476 ("mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800477 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800478 ]
479 }
Karl Zhangaff558a2020-05-15 14:28:23 +0100480
Karl Zhang14573bc2020-06-08 09:23:21 +0800481config_tfm_profile = {"seed_params": {
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800482 "tfm_platform": ["mps2/an519", "mps2/an521",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100483 "musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800484 "toolchain_file": ["toolchain_ARMCLANG.cmake",
485 "toolchain_GNUARM.cmake"],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800486 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800487 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800488 "test_regression": [True, False],
489 "test_psa_api": ["OFF"],
490 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800491 "with_otp": ["off"],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800492 "with_bl2": [True],
493 "with_ns": [True],
Xinyu Zhang9b1aef92021-03-12 15:36:44 +0800494 "profile": ["profile_small", "profile_medium", "profile_large"],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800495 "partition_ps": ["ON", "OFF"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800496 },
497 "common_params": _common_tfm_builder_cfg,
498 "invalid": _common_tfm_invalid_configs + [
499 ("mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800500 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhang9b1aef92021-03-12 15:36:44 +0800501 # Profile Large is only supported by AN521
502 ("mps2/an519", "*", "*",
503 "*", "*", "*", "*", "*", "*", "*", "profile_large", "*"),
504 ("musca_b1/sse_200", "*", "*",
505 "*", "*", "*", "*", "*", "*", "*", "profile_large", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800506 ]
507 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800508
Karl Zhangaff558a2020-05-15 14:28:23 +0100509config_tfm_test_OTP = {"seed_params": {
Mark Horvath8d281cd2020-12-07 15:20:26 +0100510 "tfm_platform": ["musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800511 "toolchain_file": ["toolchain_ARMCLANG.cmake",
512 "toolchain_GNUARM.cmake"],
513 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800514 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800515 "test_regression": [True, False],
516 "test_psa_api": ["OFF"],
517 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800518 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800519 "with_bl2": [True],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800520 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800521 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800522 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800523 },
524 "common_params": _common_tfm_builder_cfg,
525 "invalid": _common_tfm_invalid_configs + []
526 }
Karl Zhangaff558a2020-05-15 14:28:23 +0100527
Minos Galanakisea421232019-06-20 17:11:28 +0100528config_MUSCA_A = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800529 "tfm_platform": ["musca_a"],
530 "toolchain_file": ["toolchain_ARMCLANG.cmake",
531 "toolchain_GNUARM.cmake"],
532 "psa_api": [True, False],
533 "isolation_level": ["1", "2"],
534 "test_regression": [True, False],
535 "test_psa_api": ["OFF"],
536 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800537 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800538 "with_bl2": [True],
539 "with_ns": [True, False],
540 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800541 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800542 },
543 "common_params": _common_tfm_builder_cfg,
544 "invalid": _common_tfm_invalid_configs + []
545 }
Minos Galanakisea421232019-06-20 17:11:28 +0100546
547config_MUSCA_B1 = {"seed_params": {
Mark Horvath8d281cd2020-12-07 15:20:26 +0100548 "tfm_platform": ["musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800549 "toolchain_file": ["toolchain_ARMCLANG.cmake",
550 "toolchain_GNUARM.cmake"],
551 "psa_api": [True, False],
552 "isolation_level": ["1", "2"],
553 "test_regression": [True, False],
554 "test_psa_api": ["OFF"],
555 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800556 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800557 "with_bl2": [True],
558 "with_ns": [True, False],
559 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800560 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800561 },
562 "common_params": _common_tfm_builder_cfg,
563 "invalid": _common_tfm_invalid_configs + []
564 }
Minos Galanakisea421232019-06-20 17:11:28 +0100565
Mark Horvath8d281cd2020-12-07 15:20:26 +0100566config_MUSCA_B1_SE = {"seed_params": {
567 "tfm_platform": ["musca_b1/secure_enclave"],
568 "toolchain_file": ["toolchain_ARMCLANG.cmake",
569 "toolchain_GNUARM.cmake"],
570 "psa_api": [True],
571 "isolation_level": ["1"],
572 "test_regression": [False],
573 "test_psa_api": ["OFF"],
574 "cmake_build_type": ["Debug", "Release"],
575 "with_otp": ["off"],
576 "with_bl2": [True],
577 "with_ns": [False],
578 "profile": [""],
579 "partition_ps": ["ON"],
580 },
581 "common_params": _common_tfm_builder_cfg,
582 "invalid": _common_tfm_invalid_configs + []
583 }
584
Karl Zhangeffed972020-06-30 15:48:01 +0800585config_MUSCA_S1 = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800586 "tfm_platform": ["musca_s1"],
587 "toolchain_file": ["toolchain_ARMCLANG.cmake",
588 "toolchain_GNUARM.cmake"],
589 "psa_api": [True, False],
590 "isolation_level": ["1", "2"],
591 "test_regression": [True, False],
592 "test_psa_api": ["OFF"],
593 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800594 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800595 "with_bl2": [True],
596 "with_ns": [True, False],
597 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800598 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800599 },
600 "common_params": _common_tfm_builder_cfg,
601 "invalid": _common_tfm_invalid_configs + []
602 }
Karl Zhangeffed972020-06-30 15:48:01 +0800603
Karl Zhangaff558a2020-05-15 14:28:23 +0100604config_release = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800605 "tfm_platform": ["mps2/an521", "mps2/an519",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100606 "musca_a", "musca_b1/sse_200", "musca_s1",
Karl Zhang6919ff62021-01-05 14:17:44 +0800607 "mps3/an524"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800608 "toolchain_file": ["toolchain_ARMCLANG.cmake",
609 "toolchain_GNUARM.cmake"],
610 "psa_api": [True, False],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800611 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800612 "test_regression": [True, False],
613 "test_psa_api": ["OFF"],
614 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800615 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800616 "with_bl2": [True, False],
617 "with_ns": [True, False],
618 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800619 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800620 },
621 "common_params": _common_tfm_builder_cfg,
622 "invalid": _common_tfm_invalid_configs + [
623 ("mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800624 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800625 ]
626 }
Karl Zhangaff558a2020-05-15 14:28:23 +0100627
628# Configure build manager to build several combinations
629config_AN521_PSA_API = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800630 "tfm_platform": ["mps2/an521", "mps2/an519",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100631 "musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800632 "toolchain_file": ["toolchain_GNUARM.cmake",
633 "toolchain_ARMCLANG.cmake"],
634 "psa_api": [True, False],
635 "isolation_level": ["1", "2"],
636 "test_regression": [False],
637 "test_psa_api": ["IPC",
638 "CRYPTO",
639 "PROTECTED_STORAGE",
640 "INITIAL_ATTESTATION",
641 "INTERNAL_TRUSTED_STORAGE"],
642 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800643 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800644 "with_bl2": [True],
645 "with_ns": [True, False],
646 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800647 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100648 },
649 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800650 "invalid": _common_tfm_invalid_configs + [
651 ("mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800652 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800653 ]
Karl Zhangaff558a2020-05-15 14:28:23 +0100654 }
655
Karl Zhangaff558a2020-05-15 14:28:23 +0100656config_AN521_PSA_IPC = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800657 "tfm_platform": ["mps2/an521", "mps2/an519",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100658 "musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800659 "toolchain_file": ["toolchain_GNUARM.cmake",
660 "toolchain_ARMCLANG.cmake"],
661 "psa_api": [True],
662 "isolation_level": ["1", "2"],
663 "test_regression": [False],
664 "test_psa_api": ["IPC"],
665 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800666 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800667 "with_bl2": [True],
668 "with_ns": [True, False],
669 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800670 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100671 },
672 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800673 "invalid": _common_tfm_invalid_configs + [
674 ("mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800675 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800676 ]
Karl Zhangaff558a2020-05-15 14:28:23 +0100677 }
678
Karl Zhang14573bc2020-06-08 09:23:21 +0800679config_nightly = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800680 "tfm_platform": ["mps2/an521", "mps2/an519",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100681 "musca_a", "musca_b1/sse_200", "musca_s1",
Karl Zhang6919ff62021-01-05 14:17:44 +0800682 "mps3/an524", "cypress/psoc64",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100683 "musca_b1/secure_enclave"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800684 "toolchain_file": ["toolchain_GNUARM.cmake",
685 "toolchain_ARMCLANG.cmake"],
686 "psa_api": [True, False],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800687 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800688 "test_regression": [True, False],
689 "test_psa_api": ["OFF"],
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800690 "cmake_build_type": ["Debug", "Release", "Minsizerel", "RelWithDebInfo"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800691 "with_otp": ["off"],
Xinyu Zhang55363aa2020-11-16 16:38:30 +0800692 "with_bl2": [True],
693 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800694 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800695 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800696 },
697 "common_params": _common_tfm_builder_cfg,
698 "invalid": _common_tfm_invalid_configs + [
699 ("mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800700 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800701 ("cypress/psoc64", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800702 "*", "*", "Debug", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800703 ("cypress/psoc64", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800704 "*", "*", "*", "*", True, True, "*", "*"),
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800705 ("mps2/an521", "*", "*", "*",
706 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
707 ("mps2/an519", "*", "*", "*",
708 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
709 ("musca_a", "*", "*", "*",
710 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Mark Horvath8d281cd2020-12-07 15:20:26 +0100711 ("musca_b1/sse_200", "*", "*", "*",
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800712 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
713 ("musca_s1", "*", "*", "*",
714 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800715 ("mps3/an524", "*", "*", "*",
716 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800717 ]
718 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800719
Karl Zhang14573bc2020-06-08 09:23:21 +0800720config_nightly_profile = {"seed_params": {
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800721 "tfm_platform": ["mps2/an519", "mps2/an521",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100722 "musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800723 "toolchain_file": ["toolchain_ARMCLANG.cmake",
724 "toolchain_GNUARM.cmake"],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800725 "psa_api": [True, False],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800726 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800727 "test_regression": [True, False],
728 "test_psa_api": ["OFF"],
729 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800730 "with_otp": ["off"],
Xinyu Zhang55363aa2020-11-16 16:38:30 +0800731 "with_bl2": [True],
732 "with_ns": [True],
Xinyu Zhang9b1aef92021-03-12 15:36:44 +0800733 "profile": ["profile_small", "profile_medium", "profile_large"],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800734 "partition_ps": ["ON", "OFF"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800735 },
736 "common_params": _common_tfm_builder_cfg,
737 "invalid": _common_tfm_invalid_configs + [
738 ("mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800739 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhang9b1aef92021-03-12 15:36:44 +0800740 # Profile Large is only supported by AN521
741 ("mps2/an519", "*", "*",
742 "*", "*", "*", "*", "*", "*", "*", "profile_large", "*"),
743 ("musca_b1/sse_200", "*", "*",
744 "*", "*", "*", "*", "*", "*", "*", "profile_large", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800745 ]
746 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800747
Karl Zhang14573bc2020-06-08 09:23:21 +0800748config_nightly_PSA_API = {"seed_params": {
Karl Zhang5ccb5522021-03-01 22:16:29 +0800749 "tfm_platform": ["mps2/an521", "musca_b1/sse_200",
750 "musca_s1"],
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": [False],
756 "test_psa_api": ["CRYPTO",
757 "PROTECTED_STORAGE",
758 "INITIAL_ATTESTATION",
759 "INTERNAL_TRUSTED_STORAGE"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800760 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800761 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800762 "with_bl2": [True],
Xinyu Zhang55363aa2020-11-16 16:38:30 +0800763 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800764 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800765 "partition_ps": ["ON"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800766 },
767 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800768 "invalid": _common_tfm_invalid_configs + []
Karl Zhang14573bc2020-06-08 09:23:21 +0800769 }
770
Karl Zhang14573bc2020-06-08 09:23:21 +0800771config_nightly_PSA_FF = {"seed_params": {
Karl Zhang5ccb5522021-03-01 22:16:29 +0800772 "tfm_platform": ["mps2/an521", "musca_b1/sse_200",
773 "musca_s1"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800774 "toolchain_file": ["toolchain_GNUARM.cmake",
775 "toolchain_ARMCLANG.cmake"],
776 "psa_api": [True],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800777 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800778 "test_regression": [False],
779 "test_psa_api": ["IPC"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800780 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800781 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800782 "with_bl2": [True],
Xinyu Zhang55363aa2020-11-16 16:38:30 +0800783 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800784 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800785 "partition_ps": ["ON"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800786 },
787 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800788 "invalid": _common_tfm_invalid_configs + []
Karl Zhang14573bc2020-06-08 09:23:21 +0800789 }
790
Karl Zhang14573bc2020-06-08 09:23:21 +0800791config_nightly_OTP = {"seed_params": {
Mark Horvath8d281cd2020-12-07 15:20:26 +0100792 "tfm_platform": ["musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800793 "toolchain_file": ["toolchain_GNUARM.cmake",
794 "toolchain_ARMCLANG.cmake"],
795 "psa_api": [True, False],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800796 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800797 "test_regression": [True],
798 "test_psa_api": ["OFF"],
799 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800800 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800801 "with_bl2": [True],
Xinyu Zhang55363aa2020-11-16 16:38:30 +0800802 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800803 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800804 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800805 },
806 "common_params": _common_tfm_builder_cfg,
807 "invalid": _common_tfm_invalid_configs + []
808 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800809
Karl Zhang14573bc2020-06-08 09:23:21 +0800810config_pp_test = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800811 "tfm_platform": ["mps2/an521", "mps2/an519",
Karl Zhang0d765af2021-01-05 11:32:29 +0800812 "musca_b1/sse_200", "musca_s1"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800813 "toolchain_file": ["toolchain_GNUARM.cmake",
814 "toolchain_ARMCLANG.cmake"],
815 "psa_api": [True, False],
Karl Zhangde36b772021-01-08 10:17:03 +0800816 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800817 "test_regression": [True],
818 "test_psa_api": ["OFF"],
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800819 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800820 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800821 "with_bl2": [True],
822 "with_ns": [True, False],
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800823 "profile": ["", "profile_small", "profile_medium"],
824 "partition_ps": ["ON", "OFF"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800825 },
826 "common_params": _common_tfm_builder_cfg,
827 "invalid": _common_tfm_invalid_configs + [
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800828 # invalid configs that are not supported by TF-M
829 ("musca_s1", "*", "*", "*", "*", "*",
830 "*", "*", "*", "*", "profile_medium", "*"),
831 # valid configs supported by TF-M but not needed in per-patch
832 ("*", "*", "*", "1", "*", "*", "Release",
833 "*", "*", "*", "*", "*"),
834 ("*", "*", "*", "1", "*", "*", "Minsizerel",
835 "*", "*", "*", "*", "*"),
836 ("*", "*", "*", "2", "*", "*", "Debug",
837 "*", "*", "*", "*", "*"),
838 ("*", "*", "*", "2", "*", "*", "Minsizerel",
839 "*", "*", "*", "*", "*"),
840 ("*", "*", "*", "3", "*", "*", "Debug",
841 "*", "*", "*", "*", "*"),
842 ("*", "*", "*", "3", "*", "*", "Release",
843 "*", "*", "*", "*", "*"),
844 ("mps2/an519", "*", "*", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800845 "*", "*", "*", "*", "profile_small", "*"),
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800846 ("musca_s1", "*", "*", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800847 "*", "*", "*", "*", "profile_small", "*"),
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800848 ("mps2/an519", "*", "*", "*", "*", "*",
849 "*", "*", "*", "*", "profile_medium", "*"),
850 ("mps2/an521", "*", "*", "*", "*", "*",
851 "*", "*", "*", "*", "profile_medium", "*"),
852 ("*", "toolchain_GNUARM.cmake", "*", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800853 "*", "*", "*", "*", "profile_small", "*"),
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800854 ("*", "toolchain_ARMCLANG.cmake", "*", "*", "*", "*",
855 "*", "*", "*", "*", "profile_medium", "*"),
856 ("*", "toolchain_ARMCLANG.cmake", "False", "*", "*", "*",
857 "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800858 ]
859 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800860
Karl Zhang14573bc2020-06-08 09:23:21 +0800861config_pp_OTP = {"seed_params": {
Mark Horvath8d281cd2020-12-07 15:20:26 +0100862 "tfm_platform": ["musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800863 "toolchain_file": ["toolchain_GNUARM.cmake"],
864 "psa_api": [True, False],
865 "isolation_level": ["1", "2"],
866 "test_regression": [True],
867 "test_psa_api": ["OFF"],
868 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800869 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800870 "with_bl2": [True],
871 "with_ns": [True, False],
872 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800873 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800874 },
875 "common_params": _common_tfm_builder_cfg,
876 "invalid": _common_tfm_invalid_configs + []
877 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800878
879# Configure build manager to build several combinations
880config_pp_PSA_API = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800881 "tfm_platform": ["mps2/an521"],
882 "toolchain_file": ["toolchain_GNUARM.cmake"],
883 "psa_api": [True],
884 "isolation_level": ["2"],
885 "test_regression": [False],
886 "test_psa_api": ["IPC",
887 "CRYPTO",
888 "PROTECTED_STORAGE",
889 "INITIAL_ATTESTATION",
890 "INTERNAL_TRUSTED_STORAGE"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800891 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800892 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800893 "with_bl2": [True],
894 "with_ns": [True, False],
895 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800896 "partition_ps": ["ON"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800897 },
898 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800899 "invalid": _common_tfm_invalid_configs + []
Karl Zhang14573bc2020-06-08 09:23:21 +0800900 }
901
Karl Zhang14573bc2020-06-08 09:23:21 +0800902config_pp_PSoC64 = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800903 "tfm_platform": ["cypress/psoc64"],
904 "toolchain_file": ["toolchain_GNUARM.cmake"],
905 "psa_api": [True],
906 "isolation_level": ["1", "2"],
907 "test_regression": [True],
908 "test_psa_api": ["OFF"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800909 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800910 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800911 "with_bl2": [False],
912 "with_ns": [True, False],
913 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800914 "partition_ps": ["ON"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800915 },
916 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800917 "invalid": _common_tfm_invalid_configs + []
Karl Zhang14573bc2020-06-08 09:23:21 +0800918 }
919
Minos Galanakisea421232019-06-20 17:11:28 +0100920# Configruation used for document building
921config_doxygen = {"common_params": {
922 "config_type": "tf-m_documents",
923 "codebase_root_dir": "tf-m",
Xinyu Zhangb708f572020-09-15 11:43:46 +0800924 "build_cmds": {"all": ["-DTFM_PLATFORM=mps2/an521 "
Fathi Boudra324fee72020-11-20 10:31:12 +0100925 "-DTFM_TOOLCHAIN_FILE=%(_tfm_code_dir_)s/toolchain_GNUARM.cmake"
Minos Galanakisea421232019-06-20 17:11:28 +0100926 "-DCMAKE_BUILD_TYPE=Debug "
Minos Galanakisea421232019-06-20 17:11:28 +0100927 "%(_tbm_code_dir_)s/",
Xinyu Zhangb708f572020-09-15 11:43:46 +0800928 "cmake --build ./ -- docs"]},
929 "artifact_capture_rex": r'%(_tbm_build_dir_)s/docs/'
930 r'reference_manual/(?:latex|html)'
Minos Galanakisea421232019-06-20 17:11:28 +0100931 r'/(\w+\.(?:html|md|pdf))$',
932 },
Xinyu Zhangb708f572020-09-15 11:43:46 +0800933 "invalid": _common_tfm_invalid_configs + []
Minos Galanakisea421232019-06-20 17:11:28 +0100934 }
935
Karl Zhangaff558a2020-05-15 14:28:23 +0100936# Configuration used in testing
Minos Galanakisea421232019-06-20 17:11:28 +0100937config_debug = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800938 "tfm_platform": ["mps2/an521"],
939 "toolchain_file": ["toolchain_ARMCLANG.cmake"],
940 "psa_api": [False],
941 "isolation_level": ["1"],
942 "test_regression": [False],
943 "test_psa_api": ["OFF"],
Minos Galanakisea421232019-06-20 17:11:28 +0100944 "cmake_build_type": ["Debug"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800945 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800946 "with_bl2": [True],
947 "with_ns": [True],
948 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800949 "partition_ps": ["ON"],
Minos Galanakisea421232019-06-20 17:11:28 +0100950 },
951 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800952 "invalid": _common_tfm_invalid_configs + []
Minos Galanakisea421232019-06-20 17:11:28 +0100953 }
954
Dean Birch4c6ad622020-03-13 11:28:03 +0000955# Configuration used in CI
Xinyu Zhangb708f572020-09-15 11:43:46 +0800956config_ci = {"seed_params": {
957 "tfm_platform": ["mps2/an521"],
958 "toolchain_file": ["toolchain_ARMCLANG.cmake",
959 "toolchain_GNUARM.cmake"],
960 "psa_api": [True, False],
961 "isolation_level": ["1", "2"],
962 "test_regression": [True, False],
963 "test_psa_api": ["OFF"],
964 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800965 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800966 "with_bl2": [True, False],
967 "with_ns": [True],
968 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800969 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800970 },
971 "common_params": _common_tfm_builder_cfg,
972 "invalid": _common_tfm_invalid_configs + [
973 ("*", "toolchain_ARMCLANG.cmake", True, "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800974 "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800975 ("*", "toolchain_ARMCLANG.cmake", False, "1", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800976 "*", "*", False, "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800977 ]
978 }
Matthew Hartfb6fd362020-03-04 21:03:59 +0000979
Xinyu Zhangb708f572020-09-15 11:43:46 +0800980config_lava_debug = {"seed_params": {
981 "tfm_platform": ["mps2/an521", "mps2/an519"],
982 "toolchain_file": ["toolchain_GNUARM.cmake"],
983 "psa_api": [True, False],
984 "isolation_level": ["1", "2"],
985 "test_regression": [True],
986 "test_psa_api": ["OFF"],
987 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800988 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800989 "with_bl2": [True, False],
990 "with_ns": [True, False],
991 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800992 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800993 },
994 "common_params": _common_tfm_builder_cfg,
995 "invalid": _common_tfm_invalid_configs + [
996 ("mps2/an521", "toolchain_GNUARM.cmake", True, "2", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800997 "*", "*", True, "*", "*", "*")
Xinyu Zhangb708f572020-09-15 11:43:46 +0800998 ]
999 }
Dean Birch4c6ad622020-03-13 11:28:03 +00001000
Karl Zhangaff558a2020-05-15 14:28:23 +01001001_builtin_configs = {
Karl Zhang14573bc2020-06-08 09:23:21 +08001002 #release test group
Karl Zhangaff558a2020-05-15 14:28:23 +01001003 "tfm_test": config_tfm_test,
1004 "tfm_test2": config_tfm_test2,
Karl Zhang14573bc2020-06-08 09:23:21 +08001005 "tfm_profile": config_tfm_profile,
Karl Zhangaff558a2020-05-15 14:28:23 +01001006 "tfm_test_otp": config_tfm_test_OTP,
1007 "psa_api": config_PSA_API,
1008 "psa_api_otp": config_PSA_API_OTP,
1009 "psa_ff": config_PSA_FF,
1010 "psa_ff_otp": config_PSA_FF_OTP,
Karl Zhang14573bc2020-06-08 09:23:21 +08001011 "tfm_psoc64": config_PSOC64,
1012
1013 #nightly test group
1014 "nightly_test": config_nightly,
1015 "nightly_profile": config_nightly_profile,
1016 "nightly_psa_api": config_nightly_PSA_API,
1017 "nightly_ff": config_nightly_PSA_FF,
1018 "nightly_otp": config_nightly_OTP,
1019
1020 #per patch test group
1021 "pp_test": config_pp_test,
1022 "pp_OTP": config_pp_OTP,
1023 "pp_PSA_API": config_pp_PSA_API,
1024 "pp_psoc64": config_pp_PSoC64,
1025
1026 #full test group in the old CI
Karl Zhangaff558a2020-05-15 14:28:23 +01001027 "full": config_full,
Karl Zhang14573bc2020-06-08 09:23:21 +08001028
1029 #specific test group
Karl Zhangaff558a2020-05-15 14:28:23 +01001030 "an524": config_AN524,
Minos Galanakisea421232019-06-20 17:11:28 +01001031 "an521": config_AN521,
Karl Zhang14573bc2020-06-08 09:23:21 +08001032 "an521_psa_api": config_AN521_PSA_API,
1033 "an521_psa_ipc": config_AN521_PSA_IPC,
Minos Galanakisea421232019-06-20 17:11:28 +01001034 "an519": config_AN519,
1035 "musca_a": config_MUSCA_A,
1036 "musca_b1": config_MUSCA_B1,
Mark Horvath8d281cd2020-12-07 15:20:26 +01001037 "musca_b1_se": config_MUSCA_B1_SE,
Karl Zhangeffed972020-06-30 15:48:01 +08001038 "musca_s1": config_MUSCA_S1,
Karl Zhang96dfe2d2020-05-11 11:31:40 +08001039 "psoc64": config_PSOC64,
Minos Galanakisea421232019-06-20 17:11:28 +01001040 "ipc": config_IPC,
1041 "doxygen": config_doxygen,
Dean Birch4c6ad622020-03-13 11:28:03 +00001042 "debug": config_debug,
Karl Zhangaff558a2020-05-15 14:28:23 +01001043 "release": config_release,
Matthew Hartfb6fd362020-03-04 21:03:59 +00001044 "debug": config_debug,
Karl Zhang14573bc2020-06-08 09:23:21 +08001045
1046 #DevOps team test group
Matthew Hartfb6fd362020-03-04 21:03:59 +00001047 "lava_debug": config_lava_debug,
Xinyu Zhanga1000582020-12-04 15:25:24 +08001048 "ci": config_ci}
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +01001049
1050if __name__ == '__main__':
1051 import os
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +01001052
Minos Galanakisea421232019-06-20 17:11:28 +01001053 # Default behavior is to export refference config when called
1054 _dir = os.getcwd()
1055 from utils import save_json
1056 for _cname, _cfg in _builtin_configs.items():
1057 _fname = os.path.join(_dir, _cname + ".json")
1058 print("Exporting config %s" % _fname)
1059 save_json(_fname, _cfg)