Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 1 | # |
Jayanth Dodderi Chidanand | 95d5d27 | 2023-01-16 17:58:47 +0000 | [diff] [blame] | 2 | # Copyright (c) 2018-2023, Arm Limited. All rights reserved. |
Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 3 | # |
| 4 | # SPDX-License-Identifier: BSD-3-Clause |
| 5 | # |
| 6 | |
| 7 | AUTOGEN_DIR := $(BUILD_PLAT)/autogen |
| 8 | |
| 9 | include lib/xlat_tables_v2/xlat_tables.mk |
| 10 | include lib/compiler-rt/compiler-rt.mk |
Mark Dykes | e7810b5 | 2020-06-03 15:46:55 -0500 | [diff] [blame] | 11 | include lib/libfdt/libfdt.mk |
Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 12 | |
| 13 | TFTF_INCLUDES := \ |
| 14 | -I${AUTOGEN_DIR} \ |
| 15 | -Itftf/framework/include \ |
Antonio Nino Diaz | 09a00ef | 2019-01-11 13:12:58 +0000 | [diff] [blame] | 16 | -Iinclude \ |
Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 17 | -Iinclude/common \ |
| 18 | -Iinclude/common/${ARCH} \ |
Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 19 | -Iinclude/lib \ |
| 20 | -Iinclude/lib/${ARCH} \ |
| 21 | -Iinclude/lib/extensions \ |
Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 22 | -Iinclude/lib/utils \ |
| 23 | -Iinclude/lib/xlat_tables \ |
| 24 | -Iinclude/plat/common \ |
| 25 | -Iinclude/runtime_services \ |
| 26 | -Iinclude/runtime_services/secure_el0_payloads \ |
Antonio Nino Diaz | 652d20a | 2018-12-10 17:17:33 +0000 | [diff] [blame] | 27 | -Iinclude/runtime_services/secure_el1_payloads \ |
nabkah01 | cd66846 | 2022-11-06 15:29:44 +0000 | [diff] [blame] | 28 | -Iinclude/runtime_services/host_realm_managment \ |
Antonio Nino Diaz | a1497e3 | 2018-11-08 11:45:13 +0000 | [diff] [blame] | 29 | -Ispm/cactus \ |
Antonio Nino Diaz | 26b3864 | 2019-03-28 13:16:04 +0000 | [diff] [blame] | 30 | -Ispm/ivy \ |
nabkah01 | 002e569 | 2022-10-10 12:36:46 +0100 | [diff] [blame] | 31 | -Irealm \ |
Mark Dykes | e7810b5 | 2020-06-03 15:46:55 -0500 | [diff] [blame] | 32 | -Ismc_fuzz/include |
Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 33 | |
Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 34 | FRAMEWORK_SOURCES := ${AUTOGEN_DIR}/tests_list.c |
| 35 | |
| 36 | FRAMEWORK_SOURCES += $(addprefix tftf/, \ |
| 37 | framework/${ARCH}/arch.c \ |
| 38 | framework/${ARCH}/asm_debug.S \ |
| 39 | framework/${ARCH}/entrypoint.S \ |
| 40 | framework/${ARCH}/exceptions.S \ |
Sandrine Bailleux | a43b003 | 2019-01-14 14:04:32 +0100 | [diff] [blame] | 41 | framework/${ARCH}/exception_report.c \ |
Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 42 | framework/debug.c \ |
| 43 | framework/main.c \ |
| 44 | framework/nvm_results_helpers.c \ |
| 45 | framework/report.c \ |
| 46 | framework/timer/timer_framework.c \ |
| 47 | tests/common/test_helpers.c \ |
| 48 | ) |
| 49 | |
| 50 | FRAMEWORK_SOURCES += \ |
| 51 | lib/${ARCH}/cache_helpers.S \ |
| 52 | lib/${ARCH}/misc_helpers.S \ |
| 53 | lib/delay/delay.c \ |
| 54 | lib/events/events.c \ |
| 55 | lib/extensions/amu/${ARCH}/amu.c \ |
| 56 | lib/extensions/amu/${ARCH}/amu_helpers.S \ |
Olivier Deprez | c8f6a67 | 2022-01-13 13:44:53 +0000 | [diff] [blame] | 57 | lib/exceptions/irq.c \ |
Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 58 | lib/locks/${ARCH}/spinlock.S \ |
| 59 | lib/power_management/hotplug/hotplug.c \ |
| 60 | lib/power_management/suspend/${ARCH}/asm_tftf_suspend.S \ |
| 61 | lib/power_management/suspend/tftf_suspend.c \ |
| 62 | lib/psci/psci.c \ |
| 63 | lib/sdei/sdei.c \ |
| 64 | lib/smc/${ARCH}/asm_smc.S \ |
| 65 | lib/smc/${ARCH}/smc.c \ |
Jimmy Brisson | c4f3eee | 2020-06-23 15:25:05 -0500 | [diff] [blame] | 66 | lib/trng/trng.c \ |
Sona Mathew | 0738421 | 2022-11-28 13:19:11 -0600 | [diff] [blame] | 67 | lib/errata_abi/errata_abi.c \ |
Harrison Mutai | 6e01164 | 2023-09-22 17:17:35 +0100 | [diff] [blame^] | 68 | lib/transfer_list/transfer_list.c \ |
Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 69 | lib/trusted_os/trusted_os.c \ |
| 70 | lib/utils/mp_printf.c \ |
| 71 | lib/utils/uuid.c \ |
| 72 | ${XLAT_TABLES_LIB_SRCS} \ |
Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 73 | plat/common/${ARCH}/platform_mp_stack.S \ |
| 74 | plat/common/plat_common.c \ |
| 75 | plat/common/plat_state_id.c \ |
| 76 | plat/common/plat_topology.c \ |
| 77 | plat/common/tftf_nvm_accessors.c |
| 78 | |
| 79 | |
| 80 | FRAMEWORK_SOURCES += ${COMPILER_RT_SRCS} |
| 81 | |
Alexei Fedorov | fb00338 | 2019-10-04 16:13:47 +0100 | [diff] [blame] | 82 | ifeq (${ARCH},aarch64) |
| 83 | # ARMv8.3 Pointer Authentication support files |
| 84 | FRAMEWORK_SOURCES += \ |
Olivier Deprez | c8f6a67 | 2022-01-13 13:44:53 +0000 | [diff] [blame] | 85 | lib/exceptions/aarch64/sync.c \ |
Manish Pandey | d648077 | 2023-02-27 13:23:06 +0000 | [diff] [blame] | 86 | lib/exceptions/aarch64/serror.c \ |
Alexei Fedorov | fb00338 | 2019-10-04 16:13:47 +0100 | [diff] [blame] | 87 | lib/extensions/pauth/aarch64/pauth.c \ |
johpow01 | 50ccb55 | 2020-11-10 19:22:13 -0600 | [diff] [blame] | 88 | lib/extensions/pauth/aarch64/pauth_helpers.S \ |
| 89 | lib/extensions/sme/aarch64/sme.c \ |
Jayanth Dodderi Chidanand | 95d5d27 | 2023-01-16 17:58:47 +0000 | [diff] [blame] | 90 | lib/extensions/sme/aarch64/sme2.c \ |
| 91 | lib/extensions/sme/aarch64/sme_helpers.S \ |
Arunachalam Ganapathy | 0bbdc2d | 2023-04-05 15:30:18 +0100 | [diff] [blame] | 92 | lib/extensions/sme/aarch64/sme2_helpers.S \ |
Arunachalam Ganapathy | d179ddc | 2023-04-12 10:41:42 +0100 | [diff] [blame] | 93 | lib/extensions/sve/aarch64/sve.c \ |
| 94 | lib/extensions/sve/aarch64/sve_helpers.S |
Alexei Fedorov | fb00338 | 2019-10-04 16:13:47 +0100 | [diff] [blame] | 95 | endif |
| 96 | |
Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 97 | TFTF_LINKERFILE := tftf/framework/tftf.ld.S |
| 98 | |
| 99 | |
| 100 | TFTF_DEFINES := |
| 101 | |
Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 102 | # Enable dynamic translation tables |
| 103 | PLAT_XLAT_TABLES_DYNAMIC := 1 |
| 104 | $(eval $(call add_define,TFTF_DEFINES,PLAT_XLAT_TABLES_DYNAMIC)) |