blob: 9d98d62653a28e6a652c19272667fc4730c2b8a5 [file] [log] [blame]
Antonio Nino Diazf2218e72019-03-19 10:59:11 +00001#
Alexei Fedorov7cc25872020-06-02 16:35:36 +01002# Copyright (c) 2018-2020, 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 \
19 -Iinclude/runtime_services \
20 -Iinclude/runtime_services/secure_el0_payloads \
21 -Ispm/cactus_mm \
22 -Ispm/common \
23
24CACTUS_MM_SOURCES := \
25 $(addprefix spm/cactus_mm/, \
26 aarch64/cactus_mm_entrypoint.S \
27 cactus_mm_main.c \
28 cactus_mm_service_loop.c \
29 cactus_mm_tests_memory_attributes.c \
30 cactus_mm_tests_misc.c \
31 cactus_mm_tests_system_setup.c \
32 ) \
33 $(addprefix spm/common/, \
34 aarch64/sp_arch_helpers.S \
35 sp_helpers.c \
36 ) \
37
38# TODO: Remove dependency on TFTF files.
39CACTUS_MM_SOURCES += \
40 tftf/framework/debug.c \
41
42CACTUS_MM_SOURCES += \
43 drivers/arm/pl011/${ARCH}/pl011_console.S \
Manish Pandeyf218ffe2020-04-09 15:16:40 +010044 drivers/console/console.c \
Antonio Nino Diazf2218e72019-03-19 10:59:11 +000045 lib/${ARCH}/cache_helpers.S \
46 lib/${ARCH}/misc_helpers.S \
Antonio Nino Diazf2218e72019-03-19 10:59:11 +000047
48CACTUS_MM_LINKERFILE := spm/cactus_mm/cactus_mm.ld.S
49
50CACTUS_MM_DEFINES :=
51
52# TODO: Assertions are disabled because they add several TFTF files as
53# dependencies. It is needed to break the dependencies and remove this line when
54# that is done.
55CACTUS_MM_DEFINES += -DENABLE_ASSERTIONS=0
56
Alexei Fedorov7fac1622020-06-19 14:25:43 +010057$(eval $(call add_define,CACTUS_MM_DEFINES,ARM_ARCH_MAJOR))
58$(eval $(call add_define,CACTUS_MM_DEFINES,ARM_ARCH_MINOR))
Antonio Nino Diazf2218e72019-03-19 10:59:11 +000059$(eval $(call add_define,CACTUS_MM_DEFINES,DEBUG))
Alexei Fedorov7fac1622020-06-19 14:25:43 +010060$(eval $(call add_define,CACTUS_MM_DEFINES,ENABLE_BTI))
61$(eval $(call add_define,CACTUS_MM_DEFINES,ENABLE_PAUTH))
Antonio Nino Diazf2218e72019-03-19 10:59:11 +000062$(eval $(call add_define,CACTUS_MM_DEFINES,LOG_LEVEL))
63$(eval $(call add_define,CACTUS_MM_DEFINES,PLAT_${PLAT}))
Deepika Bhavnanic249d5e2020-02-06 16:29:45 -060064