blob: a9024424f59590c8648670d9cbe7b62ba21f8650 [file] [log] [blame]
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +01001#!/usr/bin/env python3
2
3""" lava_job_generator_configs.py:
4
5 Default configurations for lava job generator """
6
7from __future__ import print_function
8
9__copyright__ = """
10/*
11 * Copyright (c) 2018-2019, Arm Limited. All rights reserved.
12 *
13 * SPDX-License-Identifier: BSD-3-Clause
14 *
15 */
16 """
17__author__ = "Minos Galanakis"
18__email__ = "minos.galanakis@linaro.org"
19__project__ = "Trusted Firmware-M Open CI"
20__status__ = "stable"
Minos Galanakisea421232019-06-20 17:11:28 +010021__version__ = "1.1"
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +010022
23
24def lava_gen_get_config_subset(config,
25 default=True,
26 core=True,
27 regression=True):
28 """ Allow dynamic generation of configuration combinations by subtracking
29 undesired ones """
30
31 from copy import deepcopy
32 cfg = deepcopy(config)
33 tests = deepcopy(config["tests"])
34
35 # Remove all configs not requests by the caller
36 if not default:
37 tests.pop("Default")
Minos Galanakisea421232019-06-20 17:11:28 +010038 if not core:
39 tests.pop("CoreIPC")
40 tests.pop("CoreIPCTfmLevel2")
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +010041 if not regression:
42 tests.pop("Regression")
43
44 cfg["tests"] = tests
45 return cfg
46
47
48tfm_mps2_sse_200 = {
Matthew Hart2c2688f2020-05-26 13:09:20 +010049 "templ": "mps2.jinja2",
50 "job_name": "mps2_an521_bl2",
Minos Galanakisafb43152019-09-25 14:17:39 +010051 "device_type": "mps",
Matthew Hart2c2688f2020-05-26 13:09:20 +010052 "job_timeout": 15,
53 "action_timeout": 10,
54 "monitor_timeout": 10,
55 "poweroff_timeout": 1,
56 "recovery_store_url": "https://ci.trustedfirmware.org/userContent/",
57 "platforms": {"AN521": "mps2_sse200_an512.tar.gz"},
58 "compilers": ["GNUARM", "ARMCLANG"],
59 "build_types": ["Debug", "Release", "Minsizerel"],
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +010060 "boot_types": ["BL2"],
61 "tests": {
62 'Default': {
63 "binaries": {
Minos Galanakisea421232019-06-20 17:11:28 +010064 "firmware": "tfm_sign.bin",
65 "bootloader": "mcuboot.bin"
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +010066 },
67 "monitors": [
68 {
69 'name': 'Secure_Test_Suites_Summary',
Minos Galanakis8da148a2019-10-18 17:26:40 +010070 'start': '[Sec Thread]',
Matthew Hartfb6fd362020-03-04 21:03:59 +000071 'end': 'system starting',
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +010072 'pattern': r'\x1b\\[1;34m\\[Sec Thread\\] '
73 r'(?P<test_case_id>Secure image '
74 r'initializing)(?P<result>!)',
75 'fixup': {"pass": "!", "fail": ""},
76 'required': ["secure_image_initializing"]
77 } # Monitors
78 ]
79 }, # Default
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +010080 'Regression': {
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +010081 "binaries": {
Minos Galanakisea421232019-06-20 17:11:28 +010082 "firmware": "tfm_sign.bin",
83 "bootloader": "mcuboot.bin"
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +010084 },
85 "monitors": [
86 {
87 'name': 'Secure_Test_Suites_Summary',
88 'start': 'Secure test suites summary',
89 'end': 'End of Secure test suites',
Matthew Hart2c2688f2020-05-26 13:09:20 +010090 'pattern': r"Test suite '(?P<"
91 r"test_case_id>[^\n]+)' has (.*) "
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +010092 r"(?P<result>PASSED|FAILED)",
93 'fixup': {"pass": "PASSED", "fail": "FAILED"},
94 'required': [
Minos Galanakis8305a6e2019-04-04 15:55:40 +010095 ("psa_protected_storage_"
96 "s_interface_tests_tfm_sst_test_2xxx_"),
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +010097 "sst_reliability_tests_tfm_sst_test_3xxx_",
Minos Galanakis8305a6e2019-04-04 15:55:40 +010098 "sst_rollback_protection_tests_tfm_sst_test_4xxx_",
TudorCretu8b138472019-08-30 10:51:05 +010099 ("psa_internal_trusted_storage_"
100 "s_interface_tests_tfm_its_test_2xxx_"),
101 "its_reliability_tests_tfm_its_test_3xxx_",
Minos Galanakis8305a6e2019-04-04 15:55:40 +0100102 ("audit_"
103 "logging_secure_interface_test_tfm_audit_test_1xxx_"),
104 "crypto_secure_interface_tests_tfm_crypto_test_5xxx_",
105 ("initial_attestation_service_"
106 "secure_interface_tests_tfm_attest_test_1xxx_"),
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +0100107 ]
108 },
109 {
110 'name': 'Non_Secure_Test_Suites_Summary',
111 'start': 'Non-secure test suites summary',
112 'end': r'End of Non-secure test suites',
Matthew Hart2c2688f2020-05-26 13:09:20 +0100113 'pattern': r"Test suite '(?P<"
114 r"test_case_id>[^\n]+)' has (.*) "
115 r"(?P<result>PASSED|FAILED)",
116 'fixup': {"pass": "PASSED", "fail": "FAILED"},
117 'required': [
118 ("psa_protected_storage"
119 "_ns_interface_tests_tfm_sst_test_1xxx_"),
120 ("psa_internal_trusted_storage"
121 "_ns_interface_tests_tfm_its_test_1xxx_"),
122 ("auditlog_"
123 "non_secure_interface_test_tfm_audit_test_1xxx_"),
124 ("crypto_"
125 "non_secure_interface_test_tfm_crypto_test_6xxx_"),
126 ("initial_attestation_service_"
127 "non_secure_interface_tests_tfm_attest_test_2xxx_"),
128 "core_non_secure_positive_tests_tfm_core_test_1xxx_"
129 ]
130 }
131 ] # Monitors
132 }, # Regression
133 'RegressionIPC': {
134 "binaries": {
135 "firmware": "tfm_sign.bin",
136 "bootloader": "mcuboot.bin"
137 },
138 "monitors": [
139 {
140 'name': 'Secure_Test_Suites_Summary',
141 'start': 'Secure test suites summary',
142 'end': 'End of Secure test suites',
143 'pattern': r"Test suite '(?P<"
144 r"test_case_id>[^\n]+)' has (.*) "
145 r"(?P<result>PASSED|FAILED)",
146 'fixup': {"pass": "PASSED", "fail": "FAILED"},
147 'required': [
148 ("psa_protected_storage_"
149 "s_interface_tests_tfm_sst_test_2xxx_"),
150 "sst_reliability_tests_tfm_sst_test_3xxx_",
151 "sst_rollback_protection_tests_tfm_sst_test_4xxx_",
152 ("psa_internal_trusted_storage_"
153 "s_interface_tests_tfm_its_test_2xxx_"),
154 "its_reliability_tests_tfm_its_test_3xxx_",
155 ("audit_"
156 "logging_secure_interface_test_tfm_audit_test_1xxx_"),
157 "crypto_secure_interface_tests_tfm_crypto_test_5xxx_",
158 ("initial_attestation_service_"
159 "secure_interface_tests_tfm_attest_test_1xxx_"),
160 ]
161 },
162 {
163 'name': 'Non_Secure_Test_Suites_Summary',
164 'start': 'Non-secure test suites summary',
165 'end': r'End of Non-secure test suites',
166 'pattern': r"Test suite '(?P<"
167 r"test_case_id>[^\n]+)' has (.*) "
168 r"(?P<result>PASSED|FAILED)",
169 'fixup': {"pass": "PASSED", "fail": "FAILED"},
170 'required': [
171 ("psa_protected_storage"
172 "_ns_interface_tests_tfm_sst_test_1xxx_"),
173 ("psa_internal_trusted_storage"
174 "_ns_interface_tests_tfm_its_test_1xxx_"),
175 ("auditlog_"
176 "non_secure_interface_test_tfm_audit_test_1xxx_"),
177 ("crypto_"
178 "non_secure_interface_test_tfm_crypto_test_6xxx_"),
179 ("initial_attestation_service_"
180 "non_secure_interface_tests_tfm_attest_test_2xxx_"),
181 "core_non_secure_positive_tests_tfm_core_test_1xxx_"
182 ]
183 }
184 ] # Monitors
185 }, # Regression
186 'RegressionIPCTfmLevel2': {
187 "binaries": {
188 "firmware": "tfm_sign.bin",
189 "bootloader": "mcuboot.bin"
190 },
191 "monitors": [
192 {
193 'name': 'Secure_Test_Suites_Summary',
194 'start': 'Secure test suites summary',
195 'end': 'End of Secure test suites',
196 'pattern': r"Test suite '(?P<"
197 r"test_case_id>[^\n]+)' has (.*) "
198 r"(?P<result>PASSED|FAILED)",
199 'fixup': {"pass": "PASSED", "fail": "FAILED"},
200 'required': [
201 ("psa_protected_storage_"
202 "s_interface_tests_tfm_sst_test_2xxx_"),
203 "sst_reliability_tests_tfm_sst_test_3xxx_",
204 "sst_rollback_protection_tests_tfm_sst_test_4xxx_",
205 ("psa_internal_trusted_storage_"
206 "s_interface_tests_tfm_its_test_2xxx_"),
207 "its_reliability_tests_tfm_its_test_3xxx_",
208 ("audit_"
209 "logging_secure_interface_test_tfm_audit_test_1xxx_"),
210 "crypto_secure_interface_tests_tfm_crypto_test_5xxx_",
211 ("initial_attestation_service_"
212 "secure_interface_tests_tfm_attest_test_1xxx_"),
213 ]
214 },
215 {
216 'name': 'Non_Secure_Test_Suites_Summary',
217 'start': 'Non-secure test suites summary',
218 'end': r'End of Non-secure test suites',
219 'pattern': r"Test suite '(?P<"
220 r"test_case_id>[^\n]+)' has (.*) "
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +0100221 r"(?P<result>PASSED|FAILED)",
222 'fixup': {"pass": "PASSED", "fail": "FAILED"},
223 'required': [
Minos Galanakis8305a6e2019-04-04 15:55:40 +0100224 ("psa_protected_storage"
225 "_ns_interface_tests_tfm_sst_test_1xxx_"),
TudorCretu8b138472019-08-30 10:51:05 +0100226 ("psa_internal_trusted_storage"
227 "_ns_interface_tests_tfm_its_test_1xxx_"),
Minos Galanakis8305a6e2019-04-04 15:55:40 +0100228 ("auditlog_"
229 "non_secure_interface_test_tfm_audit_test_1xxx_"),
230 ("crypto_"
231 "non_secure_interface_test_tfm_crypto_test_6xxx_"),
232 ("initial_attestation_service_"
Minos Galanakisf0dae4e2019-05-20 10:56:57 +0100233 "non_secure_interface_tests_tfm_attest_test_2xxx_"),
Minos Galanakis8305a6e2019-04-04 15:55:40 +0100234 "core_non_secure_positive_tests_tfm_core_test_1xxx_"
235 ]
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +0100236 }
237 ] # Monitors
238 }, # Regression
Minos Galanakisea421232019-06-20 17:11:28 +0100239 'CoreIPC': {
240 "binaries": {
241 "firmware": "tfm_sign.bin",
242 "bootloader": "mcuboot.bin"
243 },
244 "monitors": [
245 {
246 'name': 'Secure_Test_Suites_Summary',
Minos Galanakis8da148a2019-10-18 17:26:40 +0100247 'start': '[Sec Thread]',
Matthew Hartfb6fd362020-03-04 21:03:59 +0000248 'end': 'system starting',
Minos Galanakisea421232019-06-20 17:11:28 +0100249 'pattern': r'\x1b\\[1;34m\\[Sec Thread\\] '
250 r'(?P<test_case_id>Secure image '
251 r'initializing)(?P<result>!)',
252 'fixup': {"pass": "!", "fail": ""},
253 'required': ["secure_image_initializing"]
254 } # Monitors
255 ]
256 }, # CoreIPC
257 'CoreIPCTfmLevel2': {
258 "binaries": {
259 "firmware": "tfm_sign.bin",
260 "bootloader": "mcuboot.bin"
261 },
262 "monitors": [
263 {
264 'name': 'Secure_Test_Suites_Summary',
Minos Galanakis8da148a2019-10-18 17:26:40 +0100265 'start': '[Sec Thread]',
Minos Galanakisea421232019-06-20 17:11:28 +0100266 'end': '\\x1b\\\[0m',
267 'pattern': r'\x1b\\[1;34m\\[Sec Thread\\] '
268 r'(?P<test_case_id>Secure image '
269 r'initializing)(?P<result>!)',
270 'fixup': {"pass": "!", "fail": ""},
271 'required': ["secure_image_initializing"]
272 } # Monitors
273 ]
274 }, # CoreIPCTfmLevel2
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +0100275 } # Tests
276}
277
Dean Bircha6ede7e2020-03-13 14:00:33 +0000278
Matthew Hart2c2688f2020-05-26 13:09:20 +0100279fvp_mps2_an521_bl2 = {
280 "templ": "fvp_mps2.jinja2",
281 "job_name": "fvp_mps2_an521_bl2",
Dean Bircha6ede7e2020-03-13 14:00:33 +0000282 "device_type": "fvp",
Matthew Hart2c2688f2020-05-26 13:09:20 +0100283 "job_timeout": 15,
284 "action_timeout": 10,
285 "monitor_timeout": 10,
Matthew Hartfb6fd362020-03-04 21:03:59 +0000286 "poweroff_timeout": 1,
Dean Birch1d545c02020-05-29 14:09:21 +0100287 "platforms": {"AN521": ""},
Matthew Hartfb6fd362020-03-04 21:03:59 +0000288 "compilers": ["GNUARM", "ARMCLANG"],
Matthew Hart2c2688f2020-05-26 13:09:20 +0100289 "build_types": ["Debug", "Release", "Minsizerel"],
Dean Bircha6ede7e2020-03-13 14:00:33 +0000290 "boot_types": ["BL2"],
Matthew Hartfb6fd362020-03-04 21:03:59 +0000291 "data_bin_offset": "0x10080000",
292 "tests": {
293 'Default': {
294 "binaries": {
295 "firmware": "mcuboot.axf",
296 "bootloader": "tfm_s_ns_signed.bin"
297 },
298 "monitors": [
299 {
300 'name': 'Secure_Test_Suites_Summary',
301 'start': r'[Sec Thread]',
302 'end': r'system starting',
303 'pattern': r'\x1b\\[1;34m\\[Sec Thread\\] '
304 r'(?P<test_case_id>Secure image '
305 r'initializing)(?P<result>!)',
306 'fixup': {"pass": "!", "fail": ""},
307 'required': ["secure_image_initializing"]
308 } # Monitors
309 ]
310 }, # Default
311 'Regression': {
312 "binaries": {
313 "firmware": "mcuboot.axf",
314 "bootloader": "tfm_s_ns_signed.bin"
315 },
316 "monitors": [
317 {
318 'name': 'Secure_Test_Suites_Summary',
319 'start': 'Secure test suites summary',
320 'end': 'End of Secure test suites',
Matthew Hart2c2688f2020-05-26 13:09:20 +0100321 'pattern': r"Test suite '(?P<"
322 r"test_case_id>[^\n]+)' has (.*) "
Matthew Hartfb6fd362020-03-04 21:03:59 +0000323 r"(?P<result>PASSED|FAILED)",
324 'fixup': {"pass": "PASSED", "fail": "FAILED"},
325 'required': [
326 ("psa_protected_storage_"
327 "s_interface_tests_tfm_sst_test_2xxx_"),
328 "sst_reliability_tests_tfm_sst_test_3xxx_",
329 "sst_rollback_protection_tests_tfm_sst_test_4xxx_",
330 ("psa_internal_trusted_storage_"
331 "s_interface_tests_tfm_its_test_2xxx_"),
332 "its_reliability_tests_tfm_its_test_3xxx_",
333 ("audit_"
334 "logging_secure_interface_test_tfm_audit_test_1xxx_"),
335 "crypto_secure_interface_tests_tfm_crypto_test_5xxx_",
336 ("initial_attestation_service_"
337 "secure_interface_tests_tfm_attest_test_1xxx_"),
338 ]
339 },
340 {
341 'name': 'Non_Secure_Test_Suites_Summary',
342 'start': 'Non-secure test suites summary',
343 'end': r'End of Non-secure test suites',
Matthew Hart2c2688f2020-05-26 13:09:20 +0100344 'pattern': r"Test suite '(?P<"
345 r"test_case_id>[^\n]+)' has (.*) "
346 r"(?P<result>PASSED|FAILED)",
347 'fixup': {"pass": "PASSED", "fail": "FAILED"},
348 'required': [
349 ("psa_protected_storage"
350 "_ns_interface_tests_tfm_sst_test_1xxx_"),
351 ("psa_internal_trusted_storage"
352 "_ns_interface_tests_tfm_its_test_1xxx_"),
353 ("auditlog_"
354 "non_secure_interface_test_tfm_audit_test_1xxx_"),
355 ("crypto_"
356 "non_secure_interface_test_tfm_crypto_test_6xxx_"),
357 ("initial_attestation_service_"
358 "non_secure_interface_tests_tfm_attest_test_2xxx_"),
359 "core_non_secure_positive_tests_tfm_core_test_1xxx_"
360 ]
361 }
362 ] # Monitors
363 }, # Regression
364 'RegressionIPC': {
365 "binaries": {
366 "firmware": "mcuboot.axf",
367 "bootloader": "tfm_s_ns_signed.bin"
368 },
369 "monitors": [
370 {
371 'name': 'Secure_Test_Suites_Summary',
372 'start': 'Secure test suites summary',
373 'end': 'End of Secure test suites',
374 'pattern': r"Test suite '(?P<"
375 r"test_case_id>[^\n]+)' has (.*) "
376 r"(?P<result>PASSED|FAILED)",
377 'fixup': {"pass": "PASSED", "fail": "FAILED"},
378 'required': [
379 ("psa_protected_storage_"
380 "s_interface_tests_tfm_sst_test_2xxx_"),
381 "sst_reliability_tests_tfm_sst_test_3xxx_",
382 "sst_rollback_protection_tests_tfm_sst_test_4xxx_",
383 ("psa_internal_trusted_storage_"
384 "s_interface_tests_tfm_its_test_2xxx_"),
385 "its_reliability_tests_tfm_its_test_3xxx_",
386 ("audit_"
387 "logging_secure_interface_test_tfm_audit_test_1xxx_"),
388 "crypto_secure_interface_tests_tfm_crypto_test_5xxx_",
389 ("initial_attestation_service_"
390 "secure_interface_tests_tfm_attest_test_1xxx_"),
391 ]
392 },
393 {
394 'name': 'Non_Secure_Test_Suites_Summary',
395 'start': 'Non-secure test suites summary',
396 'end': r'End of Non-secure test suites',
397 'pattern': r"Test suite '(?P<"
398 r"test_case_id>[^\n]+)' has (.*) "
399 r"(?P<result>PASSED|FAILED)",
400 'fixup': {"pass": "PASSED", "fail": "FAILED"},
401 'required': [
402 ("psa_protected_storage"
403 "_ns_interface_tests_tfm_sst_test_1xxx_"),
404 ("psa_internal_trusted_storage"
405 "_ns_interface_tests_tfm_its_test_1xxx_"),
406 ("auditlog_"
407 "non_secure_interface_test_tfm_audit_test_1xxx_"),
408 ("crypto_"
409 "non_secure_interface_test_tfm_crypto_test_6xxx_"),
410 ("initial_attestation_service_"
411 "non_secure_interface_tests_tfm_attest_test_2xxx_"),
412 "core_non_secure_positive_tests_tfm_core_test_1xxx_"
413 ]
414 }
415 ] # Monitors
416 }, # Regression
417 'RegressionIPCTfmLevel2': {
418 "binaries": {
419 "firmware": "mcuboot.axf",
420 "bootloader": "tfm_s_ns_signed.bin"
421 },
422 "monitors": [
423 {
424 'name': 'Secure_Test_Suites_Summary',
425 'start': 'Secure test suites summary',
426 'end': 'End of Secure test suites',
427 'pattern': r"Test suite '(?P<"
428 r"test_case_id>[^\n]+)' has (.*) "
429 r"(?P<result>PASSED|FAILED)",
430 'fixup': {"pass": "PASSED", "fail": "FAILED"},
431 'required': [
432 ("psa_protected_storage_"
433 "s_interface_tests_tfm_sst_test_2xxx_"),
434 "sst_reliability_tests_tfm_sst_test_3xxx_",
435 "sst_rollback_protection_tests_tfm_sst_test_4xxx_",
436 ("psa_internal_trusted_storage_"
437 "s_interface_tests_tfm_its_test_2xxx_"),
438 "its_reliability_tests_tfm_its_test_3xxx_",
439 ("audit_"
440 "logging_secure_interface_test_tfm_audit_test_1xxx_"),
441 "crypto_secure_interface_tests_tfm_crypto_test_5xxx_",
442 ("initial_attestation_service_"
443 "secure_interface_tests_tfm_attest_test_1xxx_"),
444 ]
445 },
446 {
447 'name': 'Non_Secure_Test_Suites_Summary',
448 'start': 'Non-secure test suites summary',
449 'end': r'End of Non-secure test suites',
450 'pattern': r"Test suite '(?P<"
451 r"test_case_id>[^\n]+)' has (.*) "
Matthew Hartfb6fd362020-03-04 21:03:59 +0000452 r"(?P<result>PASSED|FAILED)",
453 'fixup': {"pass": "PASSED", "fail": "FAILED"},
454 'required': [
455 ("psa_protected_storage"
456 "_ns_interface_tests_tfm_sst_test_1xxx_"),
457 ("psa_internal_trusted_storage"
458 "_ns_interface_tests_tfm_its_test_1xxx_"),
459 ("auditlog_"
460 "non_secure_interface_test_tfm_audit_test_1xxx_"),
461 ("crypto_"
462 "non_secure_interface_test_tfm_crypto_test_6xxx_"),
463 ("initial_attestation_service_"
464 "non_secure_interface_tests_tfm_attest_test_2xxx_"),
465 "core_non_secure_positive_tests_tfm_core_test_1xxx_"
466 ]
467 }
468 ] # Monitors
469 }, # Regression
470 'CoreIPC': {
471 "binaries": {
472 "firmware": "mcuboot.axf",
473 "bootloader": "tfm_s_ns_signed.bin"
474 },
475 "monitors": [
476 {
477 'name': 'Secure_Test_Suites_Summary',
478 'start': r'[Sec Thread]',
479 'end': r'system starting',
480 'pattern': r'\x1b\\[1;34m\\[Sec Thread\\] '
481 r'(?P<test_case_id>Secure image '
482 r'initializing)(?P<result>!)',
483 'fixup': {"pass": "!", "fail": ""},
484 'required': ["secure_image_initializing"]
485 } # Monitors
486 ]
487 }, # CoreIPC
488 'CoreIPCTfmLevel2': {
489 "binaries": {
490 "firmware": "mcuboot.axf",
491 "bootloader": "tfm_s_ns_signed.bin"
492 },
493 "monitors": [
494 {
495 'name': 'Secure_Test_Suites_Summary',
496 'start': r'[Sec Thread]',
497 'end': r'system starting',
498 'pattern': r'\x1b\\[1;34m\\[Sec Thread\\] '
499 r'(?P<test_case_id>Secure image '
500 r'initializing)(?P<result>!)',
501 'fixup': {"pass": "!", "fail": ""},
502 'required': ["secure_image_initializing"]
503 } # Monitors
504 ]
505 }, # CoreIPCTfmLevel2
506 } # Tests
507}
508
509
Matthew Hart2c2688f2020-05-26 13:09:20 +0100510fvp_mps2_an521_nobl2 = {
511 "templ": "fvp_mps2.jinja2",
512 "job_name": "fvp_mps2_an521_nobl2",
Matthew Hartfb6fd362020-03-04 21:03:59 +0000513 "device_type": "fvp",
Matthew Hart2c2688f2020-05-26 13:09:20 +0100514 "job_timeout": 15,
515 "action_timeout": 10,
516 "monitor_timeout": 10,
Matthew Hartfb6fd362020-03-04 21:03:59 +0000517 "poweroff_timeout": 1,
Dean Birch1d545c02020-05-29 14:09:21 +0100518 "platforms": {"AN521": ""},
Matthew Hartfb6fd362020-03-04 21:03:59 +0000519 "compilers": ["GNUARM", "ARMCLANG"],
Matthew Hart2c2688f2020-05-26 13:09:20 +0100520 "build_types": ["Debug", "Release", "Minsizerel"],
Matthew Hartfb6fd362020-03-04 21:03:59 +0000521 "boot_types": ["NOBL2"],
522 "data_bin_offset": "0x00100000",
Dean Birch1d545c02020-05-29 14:09:21 +0100523 "cpu_baseline": 1,
Dean Bircha6ede7e2020-03-13 14:00:33 +0000524 "tests": {
525 'Default': {
526 "binaries": {
527 "firmware": "tfm_s.axf",
528 "bootloader": "tfm_ns.bin"
529 },
530 "monitors": [
531 {
532 'name': 'Secure_Test_Suites_Summary',
Matthew Hartfb6fd362020-03-04 21:03:59 +0000533 'start': r'[Sec Thread]',
534 'end': r'system starting',
Dean Bircha6ede7e2020-03-13 14:00:33 +0000535 'pattern': r'\x1b\\[1;34m\\[Sec Thread\\] '
536 r'(?P<test_case_id>Secure image '
537 r'initializing)(?P<result>!)',
538 'fixup': {"pass": "!", "fail": ""},
539 'required': ["secure_image_initializing"]
Matthew Hartfb6fd362020-03-04 21:03:59 +0000540 }
Dean Bircha6ede7e2020-03-13 14:00:33 +0000541 ]
542 }, # Default
543 'Regression': {
544 "binaries": {
545 "firmware": "tfm_s.axf",
546 "bootloader": "tfm_ns.bin"
547 },
548 "monitors": [
549 {
550 'name': 'Secure_Test_Suites_Summary',
551 'start': 'Secure test suites summary',
552 'end': 'End of Secure test suites',
Matthew Hart2c2688f2020-05-26 13:09:20 +0100553 'pattern': r"Test suite '(?P<"
554 r"test_case_id>[^\n]+)' has (.*) "
Dean Bircha6ede7e2020-03-13 14:00:33 +0000555 r"(?P<result>PASSED|FAILED)",
556 'fixup': {"pass": "PASSED", "fail": "FAILED"},
557 'required': [
558 ("psa_protected_storage_"
559 "s_interface_tests_tfm_sst_test_2xxx_"),
560 "sst_reliability_tests_tfm_sst_test_3xxx_",
561 "sst_rollback_protection_tests_tfm_sst_test_4xxx_",
562 ("psa_internal_trusted_storage_"
563 "s_interface_tests_tfm_its_test_2xxx_"),
564 "its_reliability_tests_tfm_its_test_3xxx_",
565 ("audit_"
566 "logging_secure_interface_test_tfm_audit_test_1xxx_"),
567 "crypto_secure_interface_tests_tfm_crypto_test_5xxx_",
568 ("initial_attestation_service_"
569 "secure_interface_tests_tfm_attest_test_1xxx_"),
570 ]
571 },
572 {
573 'name': 'Non_Secure_Test_Suites_Summary',
574 'start': 'Non-secure test suites summary',
575 'end': r'End of Non-secure test suites',
Matthew Hart2c2688f2020-05-26 13:09:20 +0100576 'pattern': r"Test suite '(?P<"
577 r"test_case_id>[^\n]+)' has (.*) "
Dean Bircha6ede7e2020-03-13 14:00:33 +0000578 r"(?P<result>PASSED|FAILED)",
579 'fixup': {"pass": "PASSED", "fail": "FAILED"},
580 'required': [
581 ("psa_protected_storage"
582 "_ns_interface_tests_tfm_sst_test_1xxx_"),
583 ("psa_internal_trusted_storage"
584 "_ns_interface_tests_tfm_its_test_1xxx_"),
585 ("auditlog_"
586 "non_secure_interface_test_tfm_audit_test_1xxx_"),
587 ("crypto_"
588 "non_secure_interface_test_tfm_crypto_test_6xxx_"),
589 ("initial_attestation_service_"
590 "non_secure_interface_tests_tfm_attest_test_2xxx_"),
591 "core_non_secure_positive_tests_tfm_core_test_1xxx_"
592 ]
593 }
594 ] # Monitors
595 }, # Regression
Matthew Hart2c2688f2020-05-26 13:09:20 +0100596 'RegressionIPC': {
597 "binaries": {
598 "firmware": "tfm_s.axf",
599 "bootloader": "tfm_ns.bin"
600 },
601 "monitors": [
602 {
603 'name': 'Secure_Test_Suites_Summary',
604 'start': 'Secure test suites summary',
605 'end': 'End of Secure test suites',
606 'pattern': r"Test suite '(?P<"
607 r"test_case_id>[^\n]+)' has (.*) "
608 r"(?P<result>PASSED|FAILED)",
609 'fixup': {"pass": "PASSED", "fail": "FAILED"},
610 'required': [
611 ("psa_protected_storage_"
612 "s_interface_tests_tfm_sst_test_2xxx_"),
613 "sst_reliability_tests_tfm_sst_test_3xxx_",
614 "sst_rollback_protection_tests_tfm_sst_test_4xxx_",
615 ("psa_internal_trusted_storage_"
616 "s_interface_tests_tfm_its_test_2xxx_"),
617 "its_reliability_tests_tfm_its_test_3xxx_",
618 ("audit_"
619 "logging_secure_interface_test_tfm_audit_test_1xxx_"),
620 "crypto_secure_interface_tests_tfm_crypto_test_5xxx_",
621 ("initial_attestation_service_"
622 "secure_interface_tests_tfm_attest_test_1xxx_"),
623 ]
624 },
625 {
626 'name': 'Non_Secure_Test_Suites_Summary',
627 'start': 'Non-secure test suites summary',
628 'end': r'End of Non-secure test suites',
629 'pattern': r"Test suite '(?P<"
630 r"test_case_id>[^\n]+)' has (.*) "
631 r"(?P<result>PASSED|FAILED)",
632 'fixup': {"pass": "PASSED", "fail": "FAILED"},
633 'required': [
634 ("psa_protected_storage"
635 "_ns_interface_tests_tfm_sst_test_1xxx_"),
636 ("psa_internal_trusted_storage"
637 "_ns_interface_tests_tfm_its_test_1xxx_"),
638 ("auditlog_"
639 "non_secure_interface_test_tfm_audit_test_1xxx_"),
640 ("crypto_"
641 "non_secure_interface_test_tfm_crypto_test_6xxx_"),
642 ("initial_attestation_service_"
643 "non_secure_interface_tests_tfm_attest_test_2xxx_"),
644 "core_non_secure_positive_tests_tfm_core_test_1xxx_"
645 ]
646 }
647 ] # Monitors
648 }, # RegressionIPC
649 'RegressionIPCTfmLevel2': {
650 "binaries": {
651 "firmware": "tfm_s.axf",
652 "bootloader": "tfm_ns.bin"
653 },
654 "monitors": [
655 {
656 'name': 'Secure_Test_Suites_Summary',
657 'start': 'Secure test suites summary',
658 'end': 'End of Secure test suites',
659 'pattern': r"Test suite '(?P<"
660 r"test_case_id>[^\n]+)' has (.*) "
661 r"(?P<result>PASSED|FAILED)",
662 'fixup': {"pass": "PASSED", "fail": "FAILED"},
663 'required': [
664 ("psa_protected_storage_"
665 "s_interface_tests_tfm_sst_test_2xxx_"),
666 "sst_reliability_tests_tfm_sst_test_3xxx_",
667 "sst_rollback_protection_tests_tfm_sst_test_4xxx_",
668 ("psa_internal_trusted_storage_"
669 "s_interface_tests_tfm_its_test_2xxx_"),
670 "its_reliability_tests_tfm_its_test_3xxx_",
671 ("audit_"
672 "logging_secure_interface_test_tfm_audit_test_1xxx_"),
673 "crypto_secure_interface_tests_tfm_crypto_test_5xxx_",
674 ("initial_attestation_service_"
675 "secure_interface_tests_tfm_attest_test_1xxx_"),
676 ]
677 },
678 {
679 'name': 'Non_Secure_Test_Suites_Summary',
680 'start': 'Non-secure test suites summary',
681 'end': r'End of Non-secure test suites',
682 'pattern': r"Test suite '(?P<"
683 r"test_case_id>[^\n]+)' has (.*) "
684 r"(?P<result>PASSED|FAILED)",
685 'fixup': {"pass": "PASSED", "fail": "FAILED"},
686 'required': [
687 ("psa_protected_storage"
688 "_ns_interface_tests_tfm_sst_test_1xxx_"),
689 ("psa_internal_trusted_storage"
690 "_ns_interface_tests_tfm_its_test_1xxx_"),
691 ("auditlog_"
692 "non_secure_interface_test_tfm_audit_test_1xxx_"),
693 ("crypto_"
694 "non_secure_interface_test_tfm_crypto_test_6xxx_"),
695 ("initial_attestation_service_"
696 "non_secure_interface_tests_tfm_attest_test_2xxx_"),
697 "core_non_secure_positive_tests_tfm_core_test_1xxx_"
698 ]
699 }
700 ] # Monitors
701 }, # RegressionIPCTfmLevel2
Dean Bircha6ede7e2020-03-13 14:00:33 +0000702 'CoreIPC': {
703 "binaries": {
704 "firmware": "tfm_s.axf",
705 "bootloader": "tfm_ns.bin"
706 },
707 "monitors": [
708 {
709 'name': 'Secure_Test_Suites_Summary',
Matthew Hartfb6fd362020-03-04 21:03:59 +0000710 'start': r'[Sec Thread]',
711 'end': r'system starting',
Dean Bircha6ede7e2020-03-13 14:00:33 +0000712 'pattern': r'\x1b\\[1;34m\\[Sec Thread\\] '
713 r'(?P<test_case_id>Secure image '
714 r'initializing)(?P<result>!)',
715 'fixup': {"pass": "!", "fail": ""},
716 'required': ["secure_image_initializing"]
717 } # Monitors
718 ]
719 }, # CoreIPC
720 'CoreIPCTfmLevel2': {
721 "binaries": {
722 "firmware": "tfm_s.axf",
723 "bootloader": "tfm_ns.bin"
724 },
725 "monitors": [
726 {
727 'name': 'Secure_Test_Suites_Summary',
Matthew Hartfb6fd362020-03-04 21:03:59 +0000728 'start': r'[Sec Thread]',
729 'end': r'system starting',
Dean Bircha6ede7e2020-03-13 14:00:33 +0000730 'pattern': r'\x1b\\[1;34m\\[Sec Thread\\] '
731 r'(?P<test_case_id>Secure image '
732 r'initializing)(?P<result>!)',
733 'fixup': {"pass": "!", "fail": ""},
734 'required': ["secure_image_initializing"]
735 } # Monitors
736 ]
737 }, # CoreIPCTfmLevel2
738 } # Tests
739}
740
Matthew Hart2c2688f2020-05-26 13:09:20 +0100741
742fvp_mps2_an519_bl2 = {
743 "templ": "fvp_mps2.jinja2",
744 "job_name": "fvp_mps2_an519_bl2",
745 "device_type": "fvp",
746 "job_timeout": 15,
747 "action_timeout": 10,
748 "monitor_timeout": 10,
749 "poweroff_timeout": 1,
750 "platforms": {"AN519": ""},
751 "compilers": ["GNUARM", "ARMCLANG"],
752 "build_types": ["Debug", "Release", "Minsizerel"],
753 "boot_types": ["BL2"],
754 "data_bin_offset": "0x10080000",
755 "cpu0_baseline": 1,
756 "tests": {
757 'Default': {
758 "binaries": {
759 "firmware": "mcuboot.axf",
760 "bootloader": "tfm_s_ns_signed.bin"
761 },
762 "monitors": [
763 {
764 'name': 'Secure_Test_Suites_Summary',
765 'start': r'[Sec Thread]',
766 'end': r'system starting',
767 'pattern': r'\x1b\\[1;34m\\[Sec Thread\\] '
768 r'(?P<test_case_id>Secure image '
769 r'initializing)(?P<result>!)',
770 'fixup': {"pass": "!", "fail": ""},
771 'required': ["secure_image_initializing"]
772 } # Monitors
773 ]
774 }, # Default
775 'Regression': {
776 "binaries": {
777 "firmware": "mcuboot.axf",
778 "bootloader": "tfm_s_ns_signed.bin"
779 },
780 "monitors": [
781 {
782 'name': 'Secure_Test_Suites_Summary',
783 'start': 'Secure test suites summary',
784 'end': 'End of Secure test suites',
785 'pattern': r"Test suite '(?P<"
786 r"test_case_id>[^\n]+)' has (.*) "
787 r"(?P<result>PASSED|FAILED)",
788 'fixup': {"pass": "PASSED", "fail": "FAILED"},
789 'required': [
790 ("psa_protected_storage_"
791 "s_interface_tests_tfm_sst_test_2xxx_"),
792 "sst_reliability_tests_tfm_sst_test_3xxx_",
793 "sst_rollback_protection_tests_tfm_sst_test_4xxx_",
794 ("psa_internal_trusted_storage_"
795 "s_interface_tests_tfm_its_test_2xxx_"),
796 "its_reliability_tests_tfm_its_test_3xxx_",
797 ("audit_"
798 "logging_secure_interface_test_tfm_audit_test_1xxx_"),
799 "crypto_secure_interface_tests_tfm_crypto_test_5xxx_",
800 ("initial_attestation_service_"
801 "secure_interface_tests_tfm_attest_test_1xxx_"),
802 ]
803 },
804 {
805 'name': 'Non_Secure_Test_Suites_Summary',
806 'start': 'Non-secure test suites summary',
807 'end': r'End of Non-secure test suites',
808 'pattern': r"Test suite '(?P<"
809 r"test_case_id>[^\n]+)' has (.*) "
810 r"(?P<result>PASSED|FAILED)",
811 'fixup': {"pass": "PASSED", "fail": "FAILED"},
812 'required': [
813 ("psa_protected_storage"
814 "_ns_interface_tests_tfm_sst_test_1xxx_"),
815 ("psa_internal_trusted_storage"
816 "_ns_interface_tests_tfm_its_test_1xxx_"),
817 ("auditlog_"
818 "non_secure_interface_test_tfm_audit_test_1xxx_"),
819 ("crypto_"
820 "non_secure_interface_test_tfm_crypto_test_6xxx_"),
821 ("initial_attestation_service_"
822 "non_secure_interface_tests_tfm_attest_test_2xxx_"),
823 "core_non_secure_positive_tests_tfm_core_test_1xxx_"
824 ]
825 }
826 ] # Monitors
827 }, # Regression
828 'RegressionIPC': {
829 "binaries": {
830 "firmware": "mcuboot.axf",
831 "bootloader": "tfm_s_ns_signed.bin"
832 },
833 "monitors": [
834 {
835 'name': 'Secure_Test_Suites_Summary',
836 'start': 'Secure test suites summary',
837 'end': 'End of Secure test suites',
838 'pattern': r"Test suite '(?P<"
839 r"test_case_id>[^\n]+)' has (.*) "
840 r"(?P<result>PASSED|FAILED)",
841 'fixup': {"pass": "PASSED", "fail": "FAILED"},
842 'required': [
843 ("psa_protected_storage_"
844 "s_interface_tests_tfm_sst_test_2xxx_"),
845 "sst_reliability_tests_tfm_sst_test_3xxx_",
846 "sst_rollback_protection_tests_tfm_sst_test_4xxx_",
847 ("psa_internal_trusted_storage_"
848 "s_interface_tests_tfm_its_test_2xxx_"),
849 "its_reliability_tests_tfm_its_test_3xxx_",
850 ("audit_"
851 "logging_secure_interface_test_tfm_audit_test_1xxx_"),
852 "crypto_secure_interface_tests_tfm_crypto_test_5xxx_",
853 ("initial_attestation_service_"
854 "secure_interface_tests_tfm_attest_test_1xxx_"),
855 ]
856 },
857 {
858 'name': 'Non_Secure_Test_Suites_Summary',
859 'start': 'Non-secure test suites summary',
860 'end': r'End of Non-secure test suites',
861 'pattern': r"Test suite '(?P<"
862 r"test_case_id>[^\n]+)' has (.*) "
863 r"(?P<result>PASSED|FAILED)",
864 'fixup': {"pass": "PASSED", "fail": "FAILED"},
865 'required': [
866 ("psa_protected_storage"
867 "_ns_interface_tests_tfm_sst_test_1xxx_"),
868 ("psa_internal_trusted_storage"
869 "_ns_interface_tests_tfm_its_test_1xxx_"),
870 ("auditlog_"
871 "non_secure_interface_test_tfm_audit_test_1xxx_"),
872 ("crypto_"
873 "non_secure_interface_test_tfm_crypto_test_6xxx_"),
874 ("initial_attestation_service_"
875 "non_secure_interface_tests_tfm_attest_test_2xxx_"),
876 "core_non_secure_positive_tests_tfm_core_test_1xxx_"
877 ]
878 }
879 ] # Monitors
880 }, # Regression
881 'RegressionIPCTfmLevel2': {
882 "binaries": {
883 "firmware": "mcuboot.axf",
884 "bootloader": "tfm_s_ns_signed.bin"
885 },
886 "monitors": [
887 {
888 'name': 'Secure_Test_Suites_Summary',
889 'start': 'Secure test suites summary',
890 'end': 'End of Secure test suites',
891 'pattern': r"Test suite '(?P<"
892 r"test_case_id>[^\n]+)' has (.*) "
893 r"(?P<result>PASSED|FAILED)",
894 'fixup': {"pass": "PASSED", "fail": "FAILED"},
895 'required': [
896 ("psa_protected_storage_"
897 "s_interface_tests_tfm_sst_test_2xxx_"),
898 "sst_reliability_tests_tfm_sst_test_3xxx_",
899 "sst_rollback_protection_tests_tfm_sst_test_4xxx_",
900 ("psa_internal_trusted_storage_"
901 "s_interface_tests_tfm_its_test_2xxx_"),
902 "its_reliability_tests_tfm_its_test_3xxx_",
903 ("audit_"
904 "logging_secure_interface_test_tfm_audit_test_1xxx_"),
905 "crypto_secure_interface_tests_tfm_crypto_test_5xxx_",
906 ("initial_attestation_service_"
907 "secure_interface_tests_tfm_attest_test_1xxx_"),
908 ]
909 },
910 {
911 'name': 'Non_Secure_Test_Suites_Summary',
912 'start': 'Non-secure test suites summary',
913 'end': r'End of Non-secure test suites',
914 'pattern': r"Test suite '(?P<"
915 r"test_case_id>[^\n]+)' has (.*) "
916 r"(?P<result>PASSED|FAILED)",
917 'fixup': {"pass": "PASSED", "fail": "FAILED"},
918 'required': [
919 ("psa_protected_storage"
920 "_ns_interface_tests_tfm_sst_test_1xxx_"),
921 ("psa_internal_trusted_storage"
922 "_ns_interface_tests_tfm_its_test_1xxx_"),
923 ("auditlog_"
924 "non_secure_interface_test_tfm_audit_test_1xxx_"),
925 ("crypto_"
926 "non_secure_interface_test_tfm_crypto_test_6xxx_"),
927 ("initial_attestation_service_"
928 "non_secure_interface_tests_tfm_attest_test_2xxx_"),
929 "core_non_secure_positive_tests_tfm_core_test_1xxx_"
930 ]
931 }
932 ] # Monitors
933 }, # Regression
934 'CoreIPC': {
935 "binaries": {
936 "firmware": "mcuboot.axf",
937 "bootloader": "tfm_s_ns_signed.bin"
938 },
939 "monitors": [
940 {
941 'name': 'Secure_Test_Suites_Summary',
942 'start': r'[Sec Thread]',
943 'end': r'system starting',
944 'pattern': r'\x1b\\[1;34m\\[Sec Thread\\] '
945 r'(?P<test_case_id>Secure image '
946 r'initializing)(?P<result>!)',
947 'fixup': {"pass": "!", "fail": ""},
948 'required': ["secure_image_initializing"]
949 } # Monitors
950 ]
951 }, # CoreIPC
952 'CoreIPCTfmLevel2': {
953 "binaries": {
954 "firmware": "mcuboot.axf",
955 "bootloader": "tfm_s_ns_signed.bin"
956 },
957 "monitors": [
958 {
959 'name': 'Secure_Test_Suites_Summary',
960 'start': r'[Sec Thread]',
961 'end': r'system starting',
962 'pattern': r'\x1b\\[1;34m\\[Sec Thread\\] '
963 r'(?P<test_case_id>Secure image '
964 r'initializing)(?P<result>!)',
965 'fixup': {"pass": "!", "fail": ""},
966 'required': ["secure_image_initializing"]
967 } # Monitors
968 ]
969 }, # CoreIPCTfmLevel2
970 } # Tests
971}
972
973
974fvp_mps2_an519_nobl2 = {
975 "templ": "fvp_mps2.jinja2",
976 "job_name": "fvp_mps2_an519_nobl2",
977 "device_type": "fvp",
978 "job_timeout": 15,
979 "action_timeout": 10,
980 "monitor_timeout": 10,
981 "poweroff_timeout": 1,
982 "platforms": {"AN519": ""},
983 "compilers": ["GNUARM", "ARMCLANG"],
984 "build_types": ["Debug", "Release", "Minsizerel"],
985 "boot_types": ["NOBL2"],
986 "data_bin_offset": "0x00100000",
987 "cpu0_baseline": 1,
988 "tests": {
989 'Default': {
990 "binaries": {
991 "firmware": "tfm_s.axf",
992 "bootloader": "tfm_ns.bin"
993 },
994 "monitors": [
995 {
996 'name': 'Secure_Test_Suites_Summary',
997 'start': r'[Sec Thread]',
998 'end': r'system starting',
999 'pattern': r'\x1b\\[1;34m\\[Sec Thread\\] '
1000 r'(?P<test_case_id>Secure image '
1001 r'initializing)(?P<result>!)',
1002 'fixup': {"pass": "!", "fail": ""},
1003 'required': ["secure_image_initializing"]
1004 }
1005 ]
1006 }, # Default
1007 'Regression': {
1008 "binaries": {
1009 "firmware": "tfm_s.axf",
1010 "bootloader": "tfm_ns.bin"
1011 },
1012 "monitors": [
1013 {
1014 'name': 'Secure_Test_Suites_Summary',
1015 'start': 'Secure test suites summary',
1016 'end': 'End of Secure test suites',
1017 'pattern': r"Test suite '(?P<"
1018 r"test_case_id>[^\n]+)' has (.*) "
1019 r"(?P<result>PASSED|FAILED)",
1020 'fixup': {"pass": "PASSED", "fail": "FAILED"},
1021 'required': [
1022 ("psa_protected_storage_"
1023 "s_interface_tests_tfm_sst_test_2xxx_"),
1024 "sst_reliability_tests_tfm_sst_test_3xxx_",
1025 "sst_rollback_protection_tests_tfm_sst_test_4xxx_",
1026 ("psa_internal_trusted_storage_"
1027 "s_interface_tests_tfm_its_test_2xxx_"),
1028 "its_reliability_tests_tfm_its_test_3xxx_",
1029 ("audit_"
1030 "logging_secure_interface_test_tfm_audit_test_1xxx_"),
1031 "crypto_secure_interface_tests_tfm_crypto_test_5xxx_",
1032 ("initial_attestation_service_"
1033 "secure_interface_tests_tfm_attest_test_1xxx_"),
1034 ]
1035 },
1036 {
1037 'name': 'Non_Secure_Test_Suites_Summary',
1038 'start': 'Non-secure test suites summary',
1039 'end': r'End of Non-secure test suites',
1040 'pattern': r"Test suite '(?P<"
1041 r"test_case_id>[^\n]+)' has (.*) "
1042 r"(?P<result>PASSED|FAILED)",
1043 'fixup': {"pass": "PASSED", "fail": "FAILED"},
1044 'required': [
1045 ("psa_protected_storage"
1046 "_ns_interface_tests_tfm_sst_test_1xxx_"),
1047 ("psa_internal_trusted_storage"
1048 "_ns_interface_tests_tfm_its_test_1xxx_"),
1049 ("auditlog_"
1050 "non_secure_interface_test_tfm_audit_test_1xxx_"),
1051 ("crypto_"
1052 "non_secure_interface_test_tfm_crypto_test_6xxx_"),
1053 ("initial_attestation_service_"
1054 "non_secure_interface_tests_tfm_attest_test_2xxx_"),
1055 "core_non_secure_positive_tests_tfm_core_test_1xxx_"
1056 ]
1057 }
1058 ] # Monitors
1059 }, # Regression
1060 'RegressionIPC': {
1061 "binaries": {
1062 "firmware": "tfm_s.axf",
1063 "bootloader": "tfm_ns.bin"
1064 },
1065 "monitors": [
1066 {
1067 'name': 'Secure_Test_Suites_Summary',
1068 'start': 'Secure test suites summary',
1069 'end': 'End of Secure test suites',
1070 'pattern': r"Test suite '(?P<"
1071 r"test_case_id>[^\n]+)' has (.*) "
1072 r"(?P<result>PASSED|FAILED)",
1073 'fixup': {"pass": "PASSED", "fail": "FAILED"},
1074 'required': [
1075 ("psa_protected_storage_"
1076 "s_interface_tests_tfm_sst_test_2xxx_"),
1077 "sst_reliability_tests_tfm_sst_test_3xxx_",
1078 "sst_rollback_protection_tests_tfm_sst_test_4xxx_",
1079 ("psa_internal_trusted_storage_"
1080 "s_interface_tests_tfm_its_test_2xxx_"),
1081 "its_reliability_tests_tfm_its_test_3xxx_",
1082 ("audit_"
1083 "logging_secure_interface_test_tfm_audit_test_1xxx_"),
1084 "crypto_secure_interface_tests_tfm_crypto_test_5xxx_",
1085 ("initial_attestation_service_"
1086 "secure_interface_tests_tfm_attest_test_1xxx_"),
1087 ]
1088 },
1089 {
1090 'name': 'Non_Secure_Test_Suites_Summary',
1091 'start': 'Non-secure test suites summary',
1092 'end': r'End of Non-secure test suites',
1093 'pattern': r"Test suite '(?P<"
1094 r"test_case_id>[^\n]+)' has (.*) "
1095 r"(?P<result>PASSED|FAILED)",
1096 'fixup': {"pass": "PASSED", "fail": "FAILED"},
1097 'required': [
1098 ("psa_protected_storage"
1099 "_ns_interface_tests_tfm_sst_test_1xxx_"),
1100 ("psa_internal_trusted_storage"
1101 "_ns_interface_tests_tfm_its_test_1xxx_"),
1102 ("auditlog_"
1103 "non_secure_interface_test_tfm_audit_test_1xxx_"),
1104 ("crypto_"
1105 "non_secure_interface_test_tfm_crypto_test_6xxx_"),
1106 ("initial_attestation_service_"
1107 "non_secure_interface_tests_tfm_attest_test_2xxx_"),
1108 "core_non_secure_positive_tests_tfm_core_test_1xxx_"
1109 ]
1110 }
1111 ] # Monitors
1112 }, # RegressionIPC
1113 'RegressionIPCTfmLevel2': {
1114 "binaries": {
1115 "firmware": "tfm_s.axf",
1116 "bootloader": "tfm_ns.bin"
1117 },
1118 "monitors": [
1119 {
1120 'name': 'Secure_Test_Suites_Summary',
1121 'start': 'Secure test suites summary',
1122 'end': 'End of Secure test suites',
1123 'pattern': r"Test suite '(?P<"
1124 r"test_case_id>[^\n]+)' has (.*) "
1125 r"(?P<result>PASSED|FAILED)",
1126 'fixup': {"pass": "PASSED", "fail": "FAILED"},
1127 'required': [
1128 ("psa_protected_storage_"
1129 "s_interface_tests_tfm_sst_test_2xxx_"),
1130 "sst_reliability_tests_tfm_sst_test_3xxx_",
1131 "sst_rollback_protection_tests_tfm_sst_test_4xxx_",
1132 ("psa_internal_trusted_storage_"
1133 "s_interface_tests_tfm_its_test_2xxx_"),
1134 "its_reliability_tests_tfm_its_test_3xxx_",
1135 ("audit_"
1136 "logging_secure_interface_test_tfm_audit_test_1xxx_"),
1137 "crypto_secure_interface_tests_tfm_crypto_test_5xxx_",
1138 ("initial_attestation_service_"
1139 "secure_interface_tests_tfm_attest_test_1xxx_"),
1140 ]
1141 },
1142 {
1143 'name': 'Non_Secure_Test_Suites_Summary',
1144 'start': 'Non-secure test suites summary',
1145 'end': r'End of Non-secure test suites',
1146 'pattern': r"Test suite '(?P<"
1147 r"test_case_id>[^\n]+)' has (.*) "
1148 r"(?P<result>PASSED|FAILED)",
1149 'fixup': {"pass": "PASSED", "fail": "FAILED"},
1150 'required': [
1151 ("psa_protected_storage"
1152 "_ns_interface_tests_tfm_sst_test_1xxx_"),
1153 ("psa_internal_trusted_storage"
1154 "_ns_interface_tests_tfm_its_test_1xxx_"),
1155 ("auditlog_"
1156 "non_secure_interface_test_tfm_audit_test_1xxx_"),
1157 ("crypto_"
1158 "non_secure_interface_test_tfm_crypto_test_6xxx_"),
1159 ("initial_attestation_service_"
1160 "non_secure_interface_tests_tfm_attest_test_2xxx_"),
1161 "core_non_secure_positive_tests_tfm_core_test_1xxx_"
1162 ]
1163 }
1164 ] # Monitors
1165 }, # RegressionIPCTfmLevel2
1166 'CoreIPC': {
1167 "binaries": {
1168 "firmware": "tfm_s.axf",
1169 "bootloader": "tfm_ns.bin"
1170 },
1171 "monitors": [
1172 {
1173 'name': 'Secure_Test_Suites_Summary',
1174 'start': r'[Sec Thread]',
1175 'end': r'system starting',
1176 'pattern': r'\x1b\\[1;34m\\[Sec Thread\\] '
1177 r'(?P<test_case_id>Secure image '
1178 r'initializing)(?P<result>!)',
1179 'fixup': {"pass": "!", "fail": ""},
1180 'required': ["secure_image_initializing"]
1181 } # Monitors
1182 ]
1183 }, # CoreIPC
1184 'CoreIPCTfmLevel2': {
1185 "binaries": {
1186 "firmware": "tfm_s.axf",
1187 "bootloader": "tfm_ns.bin"
1188 },
1189 "monitors": [
1190 {
1191 'name': 'Secure_Test_Suites_Summary',
1192 'start': r'[Sec Thread]',
1193 'end': r'system starting',
1194 'pattern': r'\x1b\\[1;34m\\[Sec Thread\\] '
1195 r'(?P<test_case_id>Secure image '
1196 r'initializing)(?P<result>!)',
1197 'fixup': {"pass": "!", "fail": ""},
1198 'required': ["secure_image_initializing"]
1199 } # Monitors
1200 ]
1201 }, # CoreIPCTfmLevel2
1202 } # Tests
1203}
1204
1205
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +01001206# All configurations should be mapped here
Matthew Hart2c2688f2020-05-26 13:09:20 +01001207lava_gen_config_map = {"mps2_an521_bl2": tfm_mps2_sse_200,
1208 "fvp_mps2_an521_bl2": fvp_mps2_an521_bl2,
1209 "fvp_mps2_an521_nobl2": fvp_mps2_an521_nobl2,
1210 "fvp_mps2_an519_bl2": fvp_mps2_an519_bl2,
1211 "fvp_mps2_an519_nobl2": fvp_mps2_an519_nobl2}
1212
Minos Galanakisf4ca6ac2017-12-11 02:39:21 +01001213lavagen_config_sort_order = [
1214 "templ",
1215 "job_name",
1216 "device_type",
1217 "job_timeout",
1218 "action_timeout",
1219 "monitor_timeout",
1220 "recovery_store_url",
1221 "artifact_store_url",
1222 "platforms",
1223 "compilers",
1224 "build_types",
1225 "boot_types",
1226 "tests"
1227]
1228
1229lava_gen_monitor_sort_order = [
1230 'name',
1231 'start',
1232 'end',
1233 'pattern',
1234 'fixup',
1235]
1236
1237if __name__ == "__main__":
1238 import os
1239 import sys
1240 from lava_helper import sort_lavagen_config
1241 try:
1242 from tfm_ci_pylib.utils import export_config_map
1243 except ImportError:
1244 dir_path = os.path.dirname(os.path.realpath(__file__))
1245 sys.path.append(os.path.join(dir_path, "../"))
1246 from tfm_ci_pylib.utils import export_config_map
1247
1248 if len(sys.argv) == 2:
1249 if sys.argv[1] == "--export":
1250 export_config_map(lava_gen_config_map)
1251 if len(sys.argv) == 3:
1252 if sys.argv[1] == "--export":
1253 export_config_map(sort_lavagen_config(lava_gen_config_map),
1254 sys.argv[2])