xref: /arm-trusted-firmware/plat/arm/board/tc/rss_ap_testsuites.c (revision 91f16700b400a8c0651d24a598fc48ee2997a0d7)
1*91f16700Schasinglulu /*
2*91f16700Schasinglulu  * Copyright (c) 2022, Arm Ltd. All rights reserved.
3*91f16700Schasinglulu  *
4*91f16700Schasinglulu  * SPDX-License-Identifier: BSD-3-Clause
5*91f16700Schasinglulu  */
6*91f16700Schasinglulu 
7*91f16700Schasinglulu /*
8*91f16700Schasinglulu  * `delegated_attest_ns_interface_testsuite.c` and
9*91f16700Schasinglulu  * `measured_boot_ns_interface_testsuite.c` are not added to the build directly.
10*91f16700Schasinglulu  * but are included in this file, and this file is added to the build. This is
11*91f16700Schasinglulu  * necessary because both files define the function `extra_tests_init`, so a
12*91f16700Schasinglulu  * linker error occurs when both are linked to BL31. This file defines a macro
13*91f16700Schasinglulu  * that renames the colliding function names to something unique.
14*91f16700Schasinglulu  * `plat/arm/board/tc/rss_ap_tests.c` can call the test init functions with
15*91f16700Schasinglulu  * their new name.
16*91f16700Schasinglulu  */
17*91f16700Schasinglulu 
18*91f16700Schasinglulu #define register_testsuite_extra_ns_interface \
19*91f16700Schasinglulu 	register_testsuite_delegated_attest
20*91f16700Schasinglulu #include <delegated_attest_ns_interface_testsuite.c>
21*91f16700Schasinglulu 
22*91f16700Schasinglulu #undef register_testsuite_extra_ns_interface
23*91f16700Schasinglulu #define register_testsuite_extra_ns_interface \
24*91f16700Schasinglulu 	register_testsuite_measured_boot
25*91f16700Schasinglulu #include <measured_boot_ns_interface_testsuite.c>