xref: /rk3399_ARM-atf/services/std_svc/spmd/spmd.mk (revision ac58e574f189ecc1aaa38ba70d44a91e1e735b6d)
1#
2# Copyright (c) 2021-2023, ARM Limited and Contributors. All rights reserved.
3#
4# SPDX-License-Identifier: BSD-3-Clause
5#
6
7ifneq (${ARCH},aarch64)
8	$(error "Error: SPMD is only supported on aarch64.")
9endif
10
11ifneq (${ENABLE_SME_FOR_NS},0)
12	$(error "Error: SPMD is not compatible with ENABLE_SME_FOR_NS")
13endif
14
15SPMD_SOURCES	+=	$(addprefix services/std_svc/spmd/,	\
16			${ARCH}/spmd_helpers.S			\
17			spmd_pm.c				\
18			spmd_main.c				\
19			spmd_logical_sp.c)
20
21# Specify platform specific SPMD logical partition implementation.
22SPMD_LP_SOURCES  := $(wildcard $(addprefix ${PLAT_DIR}/, \
23					${PLAT}_spmd_logical_sp*.c))
24
25ifeq (${ENABLE_SPMD_LP}, 1)
26ifneq ($(wildcard $(SPMD_LP_SOURCES)),)
27SPMD_SOURCES += $(SPMD_LP_SOURCES)
28endif
29endif
30
31# Let the top-level Makefile know that we intend to include a BL32 image
32NEED_BL32		:=	yes
33
34# Enable dynamic memory mapping
35# The SPMD component maps the SPMC DTB within BL31 virtual space.
36PLAT_XLAT_TABLES_DYNAMIC :=	1
37$(eval $(call add_define,PLAT_XLAT_TABLES_DYNAMIC))
38