blob: f63a7cd57f72326092da71b96b61383535ff3215 [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 Zhangb1c550f2020-10-28 15:32:38 +0800144 # LVL2 and LVL3 requires PSA api
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800145 ("*", "*", False, "2", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800146 ("*", "*", False, "3", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800147 # Regression requires NS
148 ("*", "*", "*", "*", True, "*", "*", "*", "*", False, "*", "*"),
Xinyu Zhang11d66112020-11-04 15:38:29 +0800149 # psoc64 requires PSA api
150 ("cypress/psoc64", "*", False, "*", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800151 # No PSA_ACK with regression
152 ("*", "*", "*", "*", True, "IPC", "*", "*", "*", "*", "*", "*"),
153 ("*", "*", "*", "*", True, "CRYPTO", "*", "*", "*", "*", "*", "*"),
154 ("*", "*", "*", "*", True, "PROTECTED_STORAGE", "*", "*", "*", "*", "*", "*"),
155 ("*", "*", "*", "*", True, "INITIAL_ATTESTATION", "*", "*", "*", "*", "*", "*"),
156 ("*", "*", "*", "*", True, "INTERNAL_TRUSTED_STORAGE", "*", "*", "*", "*", "*", "*"),
157 # PSA_ACK requires NS
158 ("*", "*", "*", "*", "*", "IPC", "*", "*", "*", False, "*", "*"),
159 ("*", "*", "*", "*", "*", "CRYPTO", "*", "*", "*", False, "*", "*"),
160 ("*", "*", "*", "*", "*", "PROTECTED_STORAGE", "*", "*", "*", False, "*", "*"),
161 ("*", "*", "*", "*", "*", "INITIAL_ATTESTATION", "*", "*", "*", False, "*", "*"),
162 ("*", "*", "*", "*", "*", "INTERNAL_TRUSTED_STORAGE", "*", "*", "*", False, "*", "*"),
163 # Musca requires BL2
164 ("musca_a", "*", "*", "*", "*", "*", "*", "*", False, "*", "*", "*"),
Mark Horvath8d281cd2020-12-07 15:20:26 +0100165 ("musca_b1/sse_200", "*", "*", "*", "*", "*", "*", "*", False, "*", "*", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800166 ("musca_s1", "*", "*", "*", "*", "*", "*", "*", False, "*", "*", "*"),
167 # psoc64 cannot use BL2
168 ("cypress/psoc64", "*", "*", "*", "*", "*", "*", "*", True, "*", "*", "*"),
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800169 # psoc64 does not support Debug build type
170 ("cypress/psoc64", "*", "*", "*", "*", "*", "Debug", "*", "*", "*", "*", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800171 # Musca b1 does not support Profile S
Mark Horvath8d281cd2020-12-07 15:20:26 +0100172 ("musca_b1/sse_200", "*", "*", "*", "*", "*", "*", "*", "*", "*", "profile_small", "*"),
173 # Musca B1 Secure Enclave requires PSA api, BL2, and supports only Isolation Level 1
174 ("musca_b1/secure_enclave", "*", False, "*", "*", "*", "*", "*", "*", "*", "*", "*"),
175 ("musca_b1/secure_enclave", "*", "*", "*", "*", "*", "*", "*", False, "*", "*", "*"),
176 ("musca_b1/secure_enclave", "*", "*", "2", "*", "*", "*", "*", "*", "*", "*", "*"),
177 # Musca B1 Secure Enclave does not support tests, profiles, NS side building
178 ("musca_b1/secure_enclave", "*", "*", "*", True, "*", "*", "*", "*", "*", "*", "*"),
179 ("musca_b1/secure_enclave", "*", "*", "*", "*", "IPC", "*", "*", "*", "*", "*", "*"),
180 ("musca_b1/secure_enclave", "*", "*", "*", "*", "CRYPTO", "*", "*", "*", "*", "*", "*"),
181 ("musca_b1/secure_enclave", "*", "*", "*", "*", "PROTECTED_STORAGE", "*", "*", "*", "*", "*", "*"),
182 ("musca_b1/secure_enclave", "*", "*", "*", "*", "INITIAL_ATTESTATION", "*", "*", "*", "*", "*", "*"),
183 ("musca_b1/secure_enclave", "*", "*", "*", "*", "INTERNAL_TRUSTED_STORAGE", "*", "*", "*", "*", "*", "*"),
184 ("musca_b1/secure_enclave", "*", "*", "*", "*", "*", "*", "*", "*", "*", "profile_small", "*"),
185 ("musca_b1/secure_enclave", "*", "*", "*", "*", "*", "*", "*", "*", "*", "profile_medium", "*"),
186 ("musca_b1/secure_enclave", "*", "*", "*", "*", "*", "*", "*", "*", True, "*", "*"),
Xinyu Zhang709c1542020-11-02 18:41:07 +0800187 # PARTITION_PS could be OFF only for Profile S and M
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800188 ("*", "*", "*", "*", "*", "*", "*", "*", "*", "*", "", "OFF"),
Xinyu Zhang709c1542020-11-02 18:41:07 +0800189 # PARTITION_PS should be OFF for Profile S
190 ("*", "*", "*", "*", "*", "*", "*", "*", "*", "*", "profile_small", "ON"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800191 # Proile M only support for PSA_API
192 ("*", "*", False, "*", "*", "*", "*", "*", "*", "*", "profile_medium", "*"),
193 # Profile M only support for Isolation Level 2
194 ("*", "*", "*", "1", "*", "*", "*", "*", "*", "*", "profile_medium", "*"),
Xinyu Zhange8de4512020-11-13 10:37:56 +0800195 ("*", "*", "*", "3", "*", "*", "*", "*", "*", "*", "profile_medium", "*"),
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800196 # Profile S does not support PSA_API
197 ("*", "*", True, "*", "*", "*", "*", "*", "*", "*", "profile_small", "*"),
198 # Profile S only supports Isolation Level 2
199 ("*", "*", "*", "2", "*", "*", "*", "*", "*", "*", "profile_small", "*"),
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800200 # Only AN521 and MUSCA_B1 support Isolation Level 3
201 ("mps2/an519", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800202 ("mps3/an524", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800203 ("musca_a", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
204 ("musca_s1", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
205 ("cypress/psoc64", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
Mark Horvath8d281cd2020-12-07 15:20:26 +0100206 ("musca_b1/secure_enclave", "*", "*", "3", "*", "*", "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800207 ]
208
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +0100209# Configure build manager to build several combinations
Karl Zhangaff558a2020-05-15 14:28:23 +0100210config_AN524 = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800211 "tfm_platform": ["mps3/an524"],
212 "toolchain_file": ["toolchain_GNUARM.cmake",
213 "toolchain_ARMCLANG.cmake"],
214 "psa_api": [True, False],
215 "isolation_level": ["1", "2"],
216 "test_regression": [True, False],
217 "test_psa_api": ["OFF"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100218 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800219 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800220 "with_bl2": [True, False],
221 "with_ns": [True, False],
222 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800223 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100224 },
225 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800226 "invalid": _common_tfm_invalid_configs + []
Karl Zhangaff558a2020-05-15 14:28:23 +0100227 }
228
Karl Zhangaff558a2020-05-15 14:28:23 +0100229config_AN521 = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800230 "tfm_platform": ["mps2/an521"],
231 "toolchain_file": ["toolchain_GNUARM.cmake",
232 "toolchain_ARMCLANG.cmake"],
233 "psa_api": [True, False],
234 "isolation_level": ["1", "2"],
235 "test_regression": [True, False],
236 "test_psa_api": ["OFF"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100237 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800238 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800239 "with_bl2": [True, False],
240 "with_ns": [True, False],
241 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800242 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100243 },
244 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800245 "invalid": _common_tfm_invalid_configs + []
Karl Zhangaff558a2020-05-15 14:28:23 +0100246 }
247
Karl Zhangaff558a2020-05-15 14:28:23 +0100248config_PSA_API = {"seed_params": {
Mark Horvath8d281cd2020-12-07 15:20:26 +0100249 "tfm_platform": ["mps2/an521", "musca_b1/sse_200", "musca_s1"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800250 "toolchain_file": ["toolchain_GNUARM.cmake",
251 "toolchain_ARMCLANG.cmake"],
252 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800253 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800254 "test_regression": [False],
255 "test_psa_api": ["CRYPTO",
256 "PROTECTED_STORAGE",
257 "INITIAL_ATTESTATION",
258 "INTERNAL_TRUSTED_STORAGE"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100259 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800260 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800261 "with_bl2": [True],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800262 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800263 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800264 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100265 },
266 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800267 "invalid": _common_tfm_invalid_configs + []
Karl Zhangaff558a2020-05-15 14:28:23 +0100268 }
269
Karl Zhangaff558a2020-05-15 14:28:23 +0100270config_PSA_FF = {"seed_params": {
Mark Horvath8d281cd2020-12-07 15:20:26 +0100271 "tfm_platform": ["mps2/an521", "musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800272 "toolchain_file": ["toolchain_GNUARM.cmake",
273 "toolchain_ARMCLANG.cmake"],
274 "psa_api": [True],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800275 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800276 "test_regression": [False],
277 "test_psa_api": ["IPC"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100278 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800279 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800280 "with_bl2": [True],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800281 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800282 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800283 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100284 },
285 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800286 "invalid": _common_tfm_invalid_configs + []
Karl Zhangaff558a2020-05-15 14:28:23 +0100287 }
288
Karl Zhangaff558a2020-05-15 14:28:23 +0100289config_PSA_API_OTP = {"seed_params": {
Mark Horvath8d281cd2020-12-07 15:20:26 +0100290 "tfm_platform": ["musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800291 "toolchain_file": ["toolchain_GNUARM.cmake",
292 "toolchain_ARMCLANG.cmake"],
293 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800294 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800295 "test_regression": [False],
296 "test_psa_api": ["CRYPTO",
297 "PROTECTED_STORAGE",
298 "INITIAL_ATTESTATION",
299 "INTERNAL_TRUSTED_STORAGE"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100300 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800301 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800302 "with_bl2": [True],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800303 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800304 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800305 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100306 },
307 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800308 "invalid": _common_tfm_invalid_configs + []
Karl Zhangaff558a2020-05-15 14:28:23 +0100309 }
Minos Galanakisea421232019-06-20 17:11:28 +0100310
Xinyu Zhangb708f572020-09-15 11:43:46 +0800311config_PSA_FF_OTP = {"seed_params": {
Mark Horvath8d281cd2020-12-07 15:20:26 +0100312 "tfm_platform": ["musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800313 "toolchain_file": ["toolchain_GNUARM.cmake",
314 "toolchain_ARMCLANG.cmake"],
315 "psa_api": [True],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800316 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800317 "test_regression": [False],
318 "test_psa_api": ["IPC"],
319 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800320 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800321 "with_bl2": [True],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800322 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800323 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800324 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800325 },
326 "common_params": _common_tfm_builder_cfg,
327 "invalid": _common_tfm_invalid_configs + []
328 }
329
Karl Zhang96dfe2d2020-05-11 11:31:40 +0800330config_PSOC64 = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800331 "tfm_platform": ["cypress/psoc64"],
332 "toolchain_file": ["toolchain_GNUARM.cmake",
333 "toolchain_ARMCLANG.cmake"],
334 "psa_api": [True],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800335 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800336 "test_regression": [True],
337 "test_psa_api": ["OFF"],
Karl Zhang96dfe2d2020-05-11 11:31:40 +0800338 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800339 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800340 "with_bl2": [False],
341 "with_ns": [True, False],
342 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800343 "partition_ps": ["ON"],
Karl Zhang96dfe2d2020-05-11 11:31:40 +0800344 },
345 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800346 "invalid": _common_tfm_invalid_configs + []
Karl Zhang96dfe2d2020-05-11 11:31:40 +0800347 }
348
Minos Galanakisea421232019-06-20 17:11:28 +0100349config_AN519 = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800350 "tfm_platform": ["mps2/an519"],
351 "toolchain_file": ["toolchain_GNUARM.cmake",
352 "toolchain_ARMCLANG.cmake"],
353 "psa_api": [True, False],
354 "isolation_level": ["1", "2"],
355 "test_regression": [True, False],
356 "test_psa_api": ["OFF"],
Minos Galanakisea421232019-06-20 17:11:28 +0100357 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800358 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800359 "with_bl2": [True, False],
360 "with_ns": [True, False],
361 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800362 "partition_ps": ["ON"],
Minos Galanakisea421232019-06-20 17:11:28 +0100363 },
364 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800365 "invalid": _common_tfm_invalid_configs + []
Minos Galanakisea421232019-06-20 17:11:28 +0100366 }
367
Xinyu Zhangb708f572020-09-15 11:43:46 +0800368config_IPC = {"seed_params": {
Mark Horvath8d281cd2020-12-07 15:20:26 +0100369 "tfm_platform": ["mps2/an521", "mps2/an519", "musca_a",
370 "musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800371 "toolchain_file": ["toolchain_GNUARM.cmake",
372 "toolchain_ARMCLANG.cmake"],
373 "psa_api": [True],
374 "isolation_level": ["1", "2"],
375 "test_regression": [True, False],
376 "test_psa_api": ["OFF"],
377 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800378 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800379 "with_bl2": [True, False],
380 "with_ns": [True, False],
381 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800382 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800383 },
Minos Galanakisea421232019-06-20 17:11:28 +0100384 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800385 "invalid": _common_tfm_invalid_configs + []
Minos Galanakisea421232019-06-20 17:11:28 +0100386 }
387
Minos Galanakisea421232019-06-20 17:11:28 +0100388config_full = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800389 "tfm_platform": ["mps2/an521", "mps2/an519",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100390 "musca_a", "musca_b1/sse_200",
Karl Zhang6919ff62021-01-05 14:17:44 +0800391 "mps3/an524", "cypress/psoc64",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100392 "musca_b1/secure_enclave"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800393 "toolchain_file": ["toolchain_GNUARM.cmake",
394 "toolchain_ARMCLANG.cmake"],
395 "psa_api": [True, False],
396 "isolation_level": ["1", "2"],
397 "test_regression": [True, False],
398 "test_psa_api": ["OFF"],
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800399 "cmake_build_type": ["Debug", "Release", "RelWithDebInfo"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800400 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800401 "with_bl2": [True, False],
402 "with_ns": [True, False],
403 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800404 "partition_ps": ["ON"],
Dean Birchd6ce2c82020-05-13 13:16:15 +0100405 },
406 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800407 "invalid": _common_tfm_invalid_configs + [
408 ("cypress/psoc64", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800409 "*", "*", "Debug", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800410 ("cypress/psoc64", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800411 "*", "*", "*", "*", True, True, "*", "*"),
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800412 ("mps2/an521", "*", "*", "*",
413 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
414 ("mps2/an519", "*", "*", "*",
415 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
416 ("musca_a", "*", "*", "*",
417 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Mark Horvath8d281cd2020-12-07 15:20:26 +0100418 ("musca_b1/sse_200", "*", "*", "*",
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800419 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800420 ("mps3/an524", "*", "*", "*",
421 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800422 ]
Karl Zhang81a76772020-05-11 18:28:52 +0800423 }
424
Karl Zhangaff558a2020-05-15 14:28:23 +0100425config_tfm_test = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800426 "tfm_platform": ["mps2/an521", "musca_a",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100427 "musca_b1/sse_200", "musca_s1"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800428 "toolchain_file": ["toolchain_ARMCLANG.cmake",
429 "toolchain_GNUARM.cmake"],
430 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800431 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800432 "test_regression": [True, False],
433 "test_psa_api": ["OFF"],
434 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800435 "with_otp": ["off"],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800436 "with_bl2": [True],
437 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800438 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800439 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800440 },
441 "common_params": _common_tfm_builder_cfg,
442 "invalid": _common_tfm_invalid_configs + []
443 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800444
Karl Zhangaff558a2020-05-15 14:28:23 +0100445config_tfm_test2 = {"seed_params": {
Karl Zhang6919ff62021-01-05 14:17:44 +0800446 "tfm_platform": ["mps2/an519", "mps3/an524"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800447 "toolchain_file": ["toolchain_ARMCLANG.cmake",
448 "toolchain_GNUARM.cmake"],
449 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800450 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800451 "test_regression": [True, False],
452 "test_psa_api": ["OFF"],
453 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800454 "with_otp": ["off"],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800455 "with_bl2": [True],
456 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800457 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800458 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800459 },
460 "common_params": _common_tfm_builder_cfg,
461 "invalid": _common_tfm_invalid_configs + [
462 ("mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800463 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800464 ]
465 }
Karl Zhangaff558a2020-05-15 14:28:23 +0100466
Karl Zhang14573bc2020-06-08 09:23:21 +0800467config_tfm_profile = {"seed_params": {
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800468 "tfm_platform": ["mps2/an519", "mps2/an521",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100469 "musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800470 "toolchain_file": ["toolchain_ARMCLANG.cmake",
471 "toolchain_GNUARM.cmake"],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800472 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800473 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800474 "test_regression": [True, False],
475 "test_psa_api": ["OFF"],
476 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800477 "with_otp": ["off"],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800478 "with_bl2": [True],
479 "with_ns": [True],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800480 "profile": ["profile_small", "profile_medium"],
481 "partition_ps": ["ON", "OFF"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800482 },
483 "common_params": _common_tfm_builder_cfg,
484 "invalid": _common_tfm_invalid_configs + [
485 ("mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800486 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800487 ]
488 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800489
Karl Zhangaff558a2020-05-15 14:28:23 +0100490config_tfm_test_OTP = {"seed_params": {
Mark Horvath8d281cd2020-12-07 15:20:26 +0100491 "tfm_platform": ["musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800492 "toolchain_file": ["toolchain_ARMCLANG.cmake",
493 "toolchain_GNUARM.cmake"],
494 "psa_api": [True, False],
Xinyu Zhang6922b7a2020-11-05 15:21:27 +0800495 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800496 "test_regression": [True, False],
497 "test_psa_api": ["OFF"],
498 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800499 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800500 "with_bl2": [True],
Xinyu Zhang5564d8b2020-11-13 10:22:27 +0800501 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800502 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800503 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800504 },
505 "common_params": _common_tfm_builder_cfg,
506 "invalid": _common_tfm_invalid_configs + []
507 }
Karl Zhangaff558a2020-05-15 14:28:23 +0100508
Minos Galanakisea421232019-06-20 17:11:28 +0100509config_MUSCA_A = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800510 "tfm_platform": ["musca_a"],
511 "toolchain_file": ["toolchain_ARMCLANG.cmake",
512 "toolchain_GNUARM.cmake"],
513 "psa_api": [True, False],
514 "isolation_level": ["1", "2"],
515 "test_regression": [True, False],
516 "test_psa_api": ["OFF"],
517 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800518 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800519 "with_bl2": [True],
520 "with_ns": [True, False],
521 "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 }
Minos Galanakisea421232019-06-20 17:11:28 +0100527
528config_MUSCA_B1 = {"seed_params": {
Mark Horvath8d281cd2020-12-07 15:20:26 +0100529 "tfm_platform": ["musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800530 "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
Mark Horvath8d281cd2020-12-07 15:20:26 +0100547config_MUSCA_B1_SE = {"seed_params": {
548 "tfm_platform": ["musca_b1/secure_enclave"],
549 "toolchain_file": ["toolchain_ARMCLANG.cmake",
550 "toolchain_GNUARM.cmake"],
551 "psa_api": [True],
552 "isolation_level": ["1"],
553 "test_regression": [False],
554 "test_psa_api": ["OFF"],
555 "cmake_build_type": ["Debug", "Release"],
556 "with_otp": ["off"],
557 "with_bl2": [True],
558 "with_ns": [False],
559 "profile": [""],
560 "partition_ps": ["ON"],
561 },
562 "common_params": _common_tfm_builder_cfg,
563 "invalid": _common_tfm_invalid_configs + []
564 }
565
Karl Zhangeffed972020-06-30 15:48:01 +0800566config_MUSCA_S1 = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800567 "tfm_platform": ["musca_s1"],
568 "toolchain_file": ["toolchain_ARMCLANG.cmake",
569 "toolchain_GNUARM.cmake"],
570 "psa_api": [True, False],
571 "isolation_level": ["1", "2"],
572 "test_regression": [True, False],
573 "test_psa_api": ["OFF"],
574 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800575 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800576 "with_bl2": [True],
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 + []
583 }
Karl Zhangeffed972020-06-30 15:48:01 +0800584
Karl Zhangaff558a2020-05-15 14:28:23 +0100585config_release = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800586 "tfm_platform": ["mps2/an521", "mps2/an519",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100587 "musca_a", "musca_b1/sse_200", "musca_s1",
Karl Zhang6919ff62021-01-05 14:17:44 +0800588 "mps3/an524"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800589 "toolchain_file": ["toolchain_ARMCLANG.cmake",
590 "toolchain_GNUARM.cmake"],
591 "psa_api": [True, False],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800592 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800593 "test_regression": [True, False],
594 "test_psa_api": ["OFF"],
595 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800596 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800597 "with_bl2": [True, False],
598 "with_ns": [True, False],
599 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800600 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800601 },
602 "common_params": _common_tfm_builder_cfg,
603 "invalid": _common_tfm_invalid_configs + [
604 ("mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800605 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800606 ]
607 }
Karl Zhangaff558a2020-05-15 14:28:23 +0100608
609# Configure build manager to build several combinations
610config_AN521_PSA_API = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800611 "tfm_platform": ["mps2/an521", "mps2/an519",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100612 "musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800613 "toolchain_file": ["toolchain_GNUARM.cmake",
614 "toolchain_ARMCLANG.cmake"],
615 "psa_api": [True, False],
616 "isolation_level": ["1", "2"],
617 "test_regression": [False],
618 "test_psa_api": ["IPC",
619 "CRYPTO",
620 "PROTECTED_STORAGE",
621 "INITIAL_ATTESTATION",
622 "INTERNAL_TRUSTED_STORAGE"],
623 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800624 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800625 "with_bl2": [True],
626 "with_ns": [True, False],
627 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800628 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100629 },
630 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800631 "invalid": _common_tfm_invalid_configs + [
632 ("mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800633 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800634 ]
Karl Zhangaff558a2020-05-15 14:28:23 +0100635 }
636
Karl Zhangaff558a2020-05-15 14:28:23 +0100637config_AN521_PSA_IPC = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800638 "tfm_platform": ["mps2/an521", "mps2/an519",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100639 "musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800640 "toolchain_file": ["toolchain_GNUARM.cmake",
641 "toolchain_ARMCLANG.cmake"],
642 "psa_api": [True],
643 "isolation_level": ["1", "2"],
644 "test_regression": [False],
645 "test_psa_api": ["IPC"],
646 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800647 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800648 "with_bl2": [True],
649 "with_ns": [True, False],
650 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800651 "partition_ps": ["ON"],
Karl Zhangaff558a2020-05-15 14:28:23 +0100652 },
653 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800654 "invalid": _common_tfm_invalid_configs + [
655 ("mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800656 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800657 ]
Karl Zhangaff558a2020-05-15 14:28:23 +0100658 }
659
Karl Zhang14573bc2020-06-08 09:23:21 +0800660config_nightly = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800661 "tfm_platform": ["mps2/an521", "mps2/an519",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100662 "musca_a", "musca_b1/sse_200", "musca_s1",
Karl Zhang6919ff62021-01-05 14:17:44 +0800663 "mps3/an524", "cypress/psoc64",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100664 "musca_b1/secure_enclave"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800665 "toolchain_file": ["toolchain_GNUARM.cmake",
666 "toolchain_ARMCLANG.cmake"],
667 "psa_api": [True, False],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800668 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800669 "test_regression": [True, False],
670 "test_psa_api": ["OFF"],
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800671 "cmake_build_type": ["Debug", "Release", "Minsizerel", "RelWithDebInfo"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800672 "with_otp": ["off"],
Xinyu Zhang55363aa2020-11-16 16:38:30 +0800673 "with_bl2": [True],
674 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800675 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800676 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800677 },
678 "common_params": _common_tfm_builder_cfg,
679 "invalid": _common_tfm_invalid_configs + [
680 ("mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800681 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800682 ("cypress/psoc64", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800683 "*", "*", "Debug", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800684 ("cypress/psoc64", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800685 "*", "*", "*", "*", True, True, "*", "*"),
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800686 ("mps2/an521", "*", "*", "*",
687 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
688 ("mps2/an519", "*", "*", "*",
689 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
690 ("musca_a", "*", "*", "*",
691 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Mark Horvath8d281cd2020-12-07 15:20:26 +0100692 ("musca_b1/sse_200", "*", "*", "*",
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800693 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
694 ("musca_s1", "*", "*", "*",
695 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Xinyu Zhangc61c87a2020-11-03 11:14:49 +0800696 ("mps3/an524", "*", "*", "*",
697 "*", "*", "RelWithDebInfo", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800698 ]
699 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800700
Karl Zhang14573bc2020-06-08 09:23:21 +0800701config_nightly_profile = {"seed_params": {
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800702 "tfm_platform": ["mps2/an519", "mps2/an521",
Mark Horvath8d281cd2020-12-07 15:20:26 +0100703 "musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800704 "toolchain_file": ["toolchain_ARMCLANG.cmake",
705 "toolchain_GNUARM.cmake"],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800706 "psa_api": [True, False],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800707 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800708 "test_regression": [True, False],
709 "test_psa_api": ["OFF"],
710 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800711 "with_otp": ["off"],
Xinyu Zhang55363aa2020-11-16 16:38:30 +0800712 "with_bl2": [True],
713 "with_ns": [True],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800714 "profile": ["profile_small", "profile_medium"],
715 "partition_ps": ["ON", "OFF"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800716 },
717 "common_params": _common_tfm_builder_cfg,
718 "invalid": _common_tfm_invalid_configs + [
719 ("mps2/an519", "toolchain_GNUARM.cmake", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800720 "*", "*", "*", "Minsizerel", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800721 ]
722 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800723
Karl Zhang14573bc2020-06-08 09:23:21 +0800724config_nightly_PSA_API = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800725 "tfm_platform": ["mps2/an521"],
726 "toolchain_file": ["toolchain_GNUARM.cmake",
727 "toolchain_ARMCLANG.cmake"],
728 "psa_api": [True, False],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800729 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800730 "test_regression": [False],
731 "test_psa_api": ["CRYPTO",
732 "PROTECTED_STORAGE",
733 "INITIAL_ATTESTATION",
734 "INTERNAL_TRUSTED_STORAGE"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800735 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800736 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800737 "with_bl2": [True],
Xinyu Zhang55363aa2020-11-16 16:38:30 +0800738 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800739 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800740 "partition_ps": ["ON"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800741 },
742 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800743 "invalid": _common_tfm_invalid_configs + []
Karl Zhang14573bc2020-06-08 09:23:21 +0800744 }
745
Karl Zhang14573bc2020-06-08 09:23:21 +0800746config_nightly_PSA_FF = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800747 "tfm_platform": ["mps2/an521"],
748 "toolchain_file": ["toolchain_GNUARM.cmake",
749 "toolchain_ARMCLANG.cmake"],
750 "psa_api": [True],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800751 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800752 "test_regression": [False],
753 "test_psa_api": ["IPC"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800754 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800755 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800756 "with_bl2": [True],
Xinyu Zhang55363aa2020-11-16 16:38:30 +0800757 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800758 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800759 "partition_ps": ["ON"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800760 },
761 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800762 "invalid": _common_tfm_invalid_configs + []
Karl Zhang14573bc2020-06-08 09:23:21 +0800763 }
764
Karl Zhang14573bc2020-06-08 09:23:21 +0800765config_nightly_OTP = {"seed_params": {
Mark Horvath8d281cd2020-12-07 15:20:26 +0100766 "tfm_platform": ["musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800767 "toolchain_file": ["toolchain_GNUARM.cmake",
768 "toolchain_ARMCLANG.cmake"],
769 "psa_api": [True, False],
Xinyu Zhangb1c550f2020-10-28 15:32:38 +0800770 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800771 "test_regression": [True],
772 "test_psa_api": ["OFF"],
773 "cmake_build_type": ["Debug", "Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800774 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800775 "with_bl2": [True],
Xinyu Zhang55363aa2020-11-16 16:38:30 +0800776 "with_ns": [True],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800777 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800778 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800779 },
780 "common_params": _common_tfm_builder_cfg,
781 "invalid": _common_tfm_invalid_configs + []
782 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800783
Karl Zhang14573bc2020-06-08 09:23:21 +0800784config_pp_test = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800785 "tfm_platform": ["mps2/an521", "mps2/an519",
Karl Zhang0d765af2021-01-05 11:32:29 +0800786 "musca_b1/sse_200", "musca_s1"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800787 "toolchain_file": ["toolchain_GNUARM.cmake",
788 "toolchain_ARMCLANG.cmake"],
789 "psa_api": [True, False],
Karl Zhangde36b772021-01-08 10:17:03 +0800790 "isolation_level": ["1", "2", "3"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800791 "test_regression": [True],
792 "test_psa_api": ["OFF"],
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800793 "cmake_build_type": ["Debug", "Release", "Minsizerel"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800794 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800795 "with_bl2": [True],
796 "with_ns": [True, False],
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800797 "profile": ["", "profile_small", "profile_medium"],
798 "partition_ps": ["ON", "OFF"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800799 },
800 "common_params": _common_tfm_builder_cfg,
801 "invalid": _common_tfm_invalid_configs + [
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800802 # invalid configs that are not supported by TF-M
803 ("musca_s1", "*", "*", "*", "*", "*",
804 "*", "*", "*", "*", "profile_medium", "*"),
805 # valid configs supported by TF-M but not needed in per-patch
806 ("*", "*", "*", "1", "*", "*", "Release",
807 "*", "*", "*", "*", "*"),
808 ("*", "*", "*", "1", "*", "*", "Minsizerel",
809 "*", "*", "*", "*", "*"),
810 ("*", "*", "*", "2", "*", "*", "Debug",
811 "*", "*", "*", "*", "*"),
812 ("*", "*", "*", "2", "*", "*", "Minsizerel",
813 "*", "*", "*", "*", "*"),
814 ("*", "*", "*", "3", "*", "*", "Debug",
815 "*", "*", "*", "*", "*"),
816 ("*", "*", "*", "3", "*", "*", "Release",
817 "*", "*", "*", "*", "*"),
818 ("mps2/an519", "*", "*", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800819 "*", "*", "*", "*", "profile_small", "*"),
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800820 ("musca_s1", "*", "*", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800821 "*", "*", "*", "*", "profile_small", "*"),
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800822 ("mps2/an519", "*", "*", "*", "*", "*",
823 "*", "*", "*", "*", "profile_medium", "*"),
824 ("mps2/an521", "*", "*", "*", "*", "*",
825 "*", "*", "*", "*", "profile_medium", "*"),
826 ("*", "toolchain_GNUARM.cmake", "*", "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800827 "*", "*", "*", "*", "profile_small", "*"),
Xinyu Zhangeb442a12021-02-01 15:16:19 +0800828 ("*", "toolchain_ARMCLANG.cmake", "*", "*", "*", "*",
829 "*", "*", "*", "*", "profile_medium", "*"),
830 ("*", "toolchain_ARMCLANG.cmake", "False", "*", "*", "*",
831 "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800832 ]
833 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800834
Karl Zhang14573bc2020-06-08 09:23:21 +0800835config_pp_OTP = {"seed_params": {
Mark Horvath8d281cd2020-12-07 15:20:26 +0100836 "tfm_platform": ["musca_b1/sse_200"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800837 "toolchain_file": ["toolchain_GNUARM.cmake"],
838 "psa_api": [True, False],
839 "isolation_level": ["1", "2"],
840 "test_regression": [True],
841 "test_psa_api": ["OFF"],
842 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800843 "with_otp": ["ENABLED"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800844 "with_bl2": [True],
845 "with_ns": [True, False],
846 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800847 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800848 },
849 "common_params": _common_tfm_builder_cfg,
850 "invalid": _common_tfm_invalid_configs + []
851 }
Karl Zhang14573bc2020-06-08 09:23:21 +0800852
853# Configure build manager to build several combinations
854config_pp_PSA_API = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800855 "tfm_platform": ["mps2/an521"],
856 "toolchain_file": ["toolchain_GNUARM.cmake"],
857 "psa_api": [True],
858 "isolation_level": ["2"],
859 "test_regression": [False],
860 "test_psa_api": ["IPC",
861 "CRYPTO",
862 "PROTECTED_STORAGE",
863 "INITIAL_ATTESTATION",
864 "INTERNAL_TRUSTED_STORAGE"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800865 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800866 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800867 "with_bl2": [True],
868 "with_ns": [True, False],
869 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800870 "partition_ps": ["ON"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800871 },
872 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800873 "invalid": _common_tfm_invalid_configs + []
Karl Zhang14573bc2020-06-08 09:23:21 +0800874 }
875
Karl Zhang14573bc2020-06-08 09:23:21 +0800876config_pp_PSoC64 = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800877 "tfm_platform": ["cypress/psoc64"],
878 "toolchain_file": ["toolchain_GNUARM.cmake"],
879 "psa_api": [True],
880 "isolation_level": ["1", "2"],
881 "test_regression": [True],
882 "test_psa_api": ["OFF"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800883 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800884 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800885 "with_bl2": [False],
886 "with_ns": [True, False],
887 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800888 "partition_ps": ["ON"],
Karl Zhang14573bc2020-06-08 09:23:21 +0800889 },
890 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800891 "invalid": _common_tfm_invalid_configs + []
Karl Zhang14573bc2020-06-08 09:23:21 +0800892 }
893
Minos Galanakisea421232019-06-20 17:11:28 +0100894# Configruation used for document building
895config_doxygen = {"common_params": {
896 "config_type": "tf-m_documents",
897 "codebase_root_dir": "tf-m",
Xinyu Zhangb708f572020-09-15 11:43:46 +0800898 "build_cmds": {"all": ["-DTFM_PLATFORM=mps2/an521 "
Fathi Boudra324fee72020-11-20 10:31:12 +0100899 "-DTFM_TOOLCHAIN_FILE=%(_tfm_code_dir_)s/toolchain_GNUARM.cmake"
Minos Galanakisea421232019-06-20 17:11:28 +0100900 "-DCMAKE_BUILD_TYPE=Debug "
Minos Galanakisea421232019-06-20 17:11:28 +0100901 "%(_tbm_code_dir_)s/",
Xinyu Zhangb708f572020-09-15 11:43:46 +0800902 "cmake --build ./ -- docs"]},
903 "artifact_capture_rex": r'%(_tbm_build_dir_)s/docs/'
904 r'reference_manual/(?:latex|html)'
Minos Galanakisea421232019-06-20 17:11:28 +0100905 r'/(\w+\.(?:html|md|pdf))$',
906 },
Xinyu Zhangb708f572020-09-15 11:43:46 +0800907 "invalid": _common_tfm_invalid_configs + []
Minos Galanakisea421232019-06-20 17:11:28 +0100908 }
909
Karl Zhangaff558a2020-05-15 14:28:23 +0100910# Configuration used in testing
Minos Galanakisea421232019-06-20 17:11:28 +0100911config_debug = {"seed_params": {
Xinyu Zhangb708f572020-09-15 11:43:46 +0800912 "tfm_platform": ["mps2/an521"],
913 "toolchain_file": ["toolchain_ARMCLANG.cmake"],
914 "psa_api": [False],
915 "isolation_level": ["1"],
916 "test_regression": [False],
917 "test_psa_api": ["OFF"],
Minos Galanakisea421232019-06-20 17:11:28 +0100918 "cmake_build_type": ["Debug"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800919 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800920 "with_bl2": [True],
921 "with_ns": [True],
922 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800923 "partition_ps": ["ON"],
Minos Galanakisea421232019-06-20 17:11:28 +0100924 },
925 "common_params": _common_tfm_builder_cfg,
Xinyu Zhangb708f572020-09-15 11:43:46 +0800926 "invalid": _common_tfm_invalid_configs + []
Minos Galanakisea421232019-06-20 17:11:28 +0100927 }
928
Dean Birch4c6ad622020-03-13 11:28:03 +0000929# Configuration used in CI
Xinyu Zhangb708f572020-09-15 11:43:46 +0800930config_ci = {"seed_params": {
931 "tfm_platform": ["mps2/an521"],
932 "toolchain_file": ["toolchain_ARMCLANG.cmake",
933 "toolchain_GNUARM.cmake"],
934 "psa_api": [True, False],
935 "isolation_level": ["1", "2"],
936 "test_regression": [True, False],
937 "test_psa_api": ["OFF"],
938 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800939 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800940 "with_bl2": [True, False],
941 "with_ns": [True],
942 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800943 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800944 },
945 "common_params": _common_tfm_builder_cfg,
946 "invalid": _common_tfm_invalid_configs + [
947 ("*", "toolchain_ARMCLANG.cmake", True, "*", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800948 "*", "*", "*", "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800949 ("*", "toolchain_ARMCLANG.cmake", False, "1", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800950 "*", "*", False, "*", "*", "*"),
Xinyu Zhangb708f572020-09-15 11:43:46 +0800951 ]
952 }
Matthew Hartfb6fd362020-03-04 21:03:59 +0000953
Xinyu Zhangb708f572020-09-15 11:43:46 +0800954config_lava_debug = {"seed_params": {
955 "tfm_platform": ["mps2/an521", "mps2/an519"],
956 "toolchain_file": ["toolchain_GNUARM.cmake"],
957 "psa_api": [True, False],
958 "isolation_level": ["1", "2"],
959 "test_regression": [True],
960 "test_psa_api": ["OFF"],
961 "cmake_build_type": ["Release"],
Xinyu Zhanga50432e2020-10-23 18:00:18 +0800962 "with_otp": ["off"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800963 "with_bl2": [True, False],
964 "with_ns": [True, False],
965 "profile": [""],
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800966 "partition_ps": ["ON"],
Xinyu Zhangb708f572020-09-15 11:43:46 +0800967 },
968 "common_params": _common_tfm_builder_cfg,
969 "invalid": _common_tfm_invalid_configs + [
970 ("mps2/an521", "toolchain_GNUARM.cmake", True, "2", "*", "*",
Xinyu Zhang9fd74242020-10-22 11:30:50 +0800971 "*", "*", True, "*", "*", "*")
Xinyu Zhangb708f572020-09-15 11:43:46 +0800972 ]
973 }
Dean Birch4c6ad622020-03-13 11:28:03 +0000974
Karl Zhangaff558a2020-05-15 14:28:23 +0100975_builtin_configs = {
Karl Zhang14573bc2020-06-08 09:23:21 +0800976 #release test group
Karl Zhangaff558a2020-05-15 14:28:23 +0100977 "tfm_test": config_tfm_test,
978 "tfm_test2": config_tfm_test2,
Karl Zhang14573bc2020-06-08 09:23:21 +0800979 "tfm_profile": config_tfm_profile,
Karl Zhangaff558a2020-05-15 14:28:23 +0100980 "tfm_test_otp": config_tfm_test_OTP,
981 "psa_api": config_PSA_API,
982 "psa_api_otp": config_PSA_API_OTP,
983 "psa_ff": config_PSA_FF,
984 "psa_ff_otp": config_PSA_FF_OTP,
Karl Zhang14573bc2020-06-08 09:23:21 +0800985 "tfm_psoc64": config_PSOC64,
986
987 #nightly test group
988 "nightly_test": config_nightly,
989 "nightly_profile": config_nightly_profile,
990 "nightly_psa_api": config_nightly_PSA_API,
991 "nightly_ff": config_nightly_PSA_FF,
992 "nightly_otp": config_nightly_OTP,
993
994 #per patch test group
995 "pp_test": config_pp_test,
996 "pp_OTP": config_pp_OTP,
997 "pp_PSA_API": config_pp_PSA_API,
998 "pp_psoc64": config_pp_PSoC64,
999
1000 #full test group in the old CI
Karl Zhangaff558a2020-05-15 14:28:23 +01001001 "full": config_full,
Karl Zhang14573bc2020-06-08 09:23:21 +08001002
1003 #specific test group
Karl Zhangaff558a2020-05-15 14:28:23 +01001004 "an524": config_AN524,
Minos Galanakisea421232019-06-20 17:11:28 +01001005 "an521": config_AN521,
Karl Zhang14573bc2020-06-08 09:23:21 +08001006 "an521_psa_api": config_AN521_PSA_API,
1007 "an521_psa_ipc": config_AN521_PSA_IPC,
Minos Galanakisea421232019-06-20 17:11:28 +01001008 "an519": config_AN519,
1009 "musca_a": config_MUSCA_A,
1010 "musca_b1": config_MUSCA_B1,
Mark Horvath8d281cd2020-12-07 15:20:26 +01001011 "musca_b1_se": config_MUSCA_B1_SE,
Karl Zhangeffed972020-06-30 15:48:01 +08001012 "musca_s1": config_MUSCA_S1,
Karl Zhang96dfe2d2020-05-11 11:31:40 +08001013 "psoc64": config_PSOC64,
Minos Galanakisea421232019-06-20 17:11:28 +01001014 "ipc": config_IPC,
1015 "doxygen": config_doxygen,
Dean Birch4c6ad622020-03-13 11:28:03 +00001016 "debug": config_debug,
Karl Zhangaff558a2020-05-15 14:28:23 +01001017 "release": config_release,
Matthew Hartfb6fd362020-03-04 21:03:59 +00001018 "debug": config_debug,
Karl Zhang14573bc2020-06-08 09:23:21 +08001019
1020 #DevOps team test group
Matthew Hartfb6fd362020-03-04 21:03:59 +00001021 "lava_debug": config_lava_debug,
Xinyu Zhanga1000582020-12-04 15:25:24 +08001022 "ci": config_ci}
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +01001023
1024if __name__ == '__main__':
1025 import os
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +01001026
Minos Galanakisea421232019-06-20 17:11:28 +01001027 # Default behavior is to export refference config when called
1028 _dir = os.getcwd()
1029 from utils import save_json
1030 for _cname, _cfg in _builtin_configs.items():
1031 _fname = os.path.join(_dir, _cname + ".json")
1032 print("Exporting config %s" % _fname)
1033 save_json(_fname, _cfg)