blob: 4a26fc383bb948e6d4e04584f56a87b0ba76c946 [file] [log] [blame]
Antonio Nino Diazf2218e72019-03-19 10:59:11 +00001#
AlexeiFedorov36ed0092024-09-10 10:37:54 +01002# Copyright (c) 2018-2024, Arm Limited. All rights reserved.
Antonio Nino Diazf2218e72019-03-19 10:59:11 +00003#
4# SPDX-License-Identifier: BSD-3-Clause
5#
6
Alexei Fedorov7fac1622020-06-19 14:25:43 +01007include branch_protection.mk
8
Antonio Nino Diazf2218e72019-03-19 10:59:11 +00009CACTUS_MM_INCLUDES := \
10 -Iinclude \
11 -Iinclude/common \
12 -Iinclude/common/${ARCH} \
13 -Iinclude/drivers \
14 -Iinclude/drivers/arm \
15 -Iinclude/lib \
16 -Iinclude/lib/${ARCH} \
17 -Iinclude/lib/utils \
18 -Iinclude/lib/xlat_tables \
AlexeiFedorov36ed0092024-09-10 10:37:54 +010019 -Iinclude/plat/common \
Antonio Nino Diazf2218e72019-03-19 10:59:11 +000020 -Iinclude/runtime_services \
21 -Iinclude/runtime_services/secure_el0_payloads \
22 -Ispm/cactus_mm \
23 -Ispm/common \
24
25CACTUS_MM_SOURCES := \
26 $(addprefix spm/cactus_mm/, \
27 aarch64/cactus_mm_entrypoint.S \
28 cactus_mm_main.c \
29 cactus_mm_service_loop.c \
30 cactus_mm_tests_memory_attributes.c \
31 cactus_mm_tests_misc.c \
32 cactus_mm_tests_system_setup.c \
33 ) \
34 $(addprefix spm/common/, \
35 aarch64/sp_arch_helpers.S \
36 sp_helpers.c \
37 ) \
38
39# TODO: Remove dependency on TFTF files.
40CACTUS_MM_SOURCES += \
41 tftf/framework/debug.c \
42
43CACTUS_MM_SOURCES += \
44 drivers/arm/pl011/${ARCH}/pl011_console.S \
Manish Pandeyf218ffe2020-04-09 15:16:40 +010045 drivers/console/console.c \
Antonio Nino Diazf2218e72019-03-19 10:59:11 +000046 lib/${ARCH}/cache_helpers.S \
47 lib/${ARCH}/misc_helpers.S \
Antonio Nino Diazf2218e72019-03-19 10:59:11 +000048
49CACTUS_MM_LINKERFILE := spm/cactus_mm/cactus_mm.ld.S
50
51CACTUS_MM_DEFINES :=
52
53# TODO: Assertions are disabled because they add several TFTF files as
54# dependencies. It is needed to break the dependencies and remove this line when
55# that is done.
56CACTUS_MM_DEFINES += -DENABLE_ASSERTIONS=0
57
Alexei Fedorov7fac1622020-06-19 14:25:43 +010058$(eval $(call add_define,CACTUS_MM_DEFINES,ARM_ARCH_MAJOR))
59$(eval $(call add_define,CACTUS_MM_DEFINES,ARM_ARCH_MINOR))
Antonio Nino Diazf2218e72019-03-19 10:59:11 +000060$(eval $(call add_define,CACTUS_MM_DEFINES,DEBUG))
Alexei Fedorov7fac1622020-06-19 14:25:43 +010061$(eval $(call add_define,CACTUS_MM_DEFINES,ENABLE_BTI))
62$(eval $(call add_define,CACTUS_MM_DEFINES,ENABLE_PAUTH))
Antonio Nino Diazf2218e72019-03-19 10:59:11 +000063$(eval $(call add_define,CACTUS_MM_DEFINES,LOG_LEVEL))
64$(eval $(call add_define,CACTUS_MM_DEFINES,PLAT_${PLAT}))
Deepika Bhavnanic249d5e2020-02-06 16:29:45 -060065