xref: /rk3399_ARM-atf/plat/mediatek/mt8186/platform.mk (revision 5aab27dc4294110a6c0b69bf5ec5343e7df883a7)
1#
2# Copyright (c) 2021, MediaTek Inc. All rights reserved.
3#
4# SPDX-License-Identifier: BSD-3-Clause
5#
6
7MTK_PLAT     := plat/mediatek
8MTK_PLAT_SOC := ${MTK_PLAT}/${PLAT}
9
10PLAT_INCLUDES := -I${MTK_PLAT}/common/                            \
11                 -I${MTK_PLAT}/common/drivers/timer/              \
12                 -I${MTK_PLAT_SOC}/drivers/emi_mpu/               \
13                 -I${MTK_PLAT_SOC}/drivers/pmic/                  \
14                 -I${MTK_PLAT_SOC}/include/
15
16include drivers/arm/gic/v3/gicv3.mk
17include lib/xlat_tables_v2/xlat_tables.mk
18
19PLAT_BL_COMMON_SOURCES := ${GICV3_SOURCES}                              \
20                          ${XLAT_TABLES_LIB_SRCS}                       \
21                          plat/common/aarch64/crash_console_helpers.S   \
22                          plat/common/plat_psci_common.c
23
24
25BL31_SOURCES += common/desc_image_load.c                              \
26                drivers/delay_timer/delay_timer.c                     \
27                drivers/delay_timer/generic_delay_timer.c             \
28                drivers/ti/uart/aarch64/16550_console.S               \
29                lib/bl_aux_params/bl_aux_params.c                     \
30                lib/cpus/aarch64/cortex_a55.S                         \
31                lib/cpus/aarch64/cortex_a76.S                         \
32                plat/common/plat_gicv3.c                              \
33                ${MTK_PLAT}/common/drivers/pmic_wrap/pmic_wrap_init.c \
34                ${MTK_PLAT}/common/mtk_plat_common.c                  \
35                ${MTK_PLAT}/common/mtk_sip_svc.c                      \
36                ${MTK_PLAT}/common/params_setup.c                     \
37                ${MTK_PLAT}/common/drivers/timer/mt_timer.c           \
38                ${MTK_PLAT_SOC}/aarch64/platform_common.c             \
39                ${MTK_PLAT_SOC}/aarch64/plat_helpers.S                \
40                ${MTK_PLAT_SOC}/bl31_plat_setup.c                     \
41                ${MTK_PLAT_SOC}/drivers/emi_mpu/emi_mpu.c             \
42                ${MTK_PLAT_SOC}/drivers/pmic/pmic.c                   \
43                ${MTK_PLAT_SOC}/plat_pm.c                             \
44                ${MTK_PLAT_SOC}/plat_sip_calls.c                      \
45                ${MTK_PLAT_SOC}/plat_topology.c
46
47# Configs for A76 and A55
48HW_ASSISTED_COHERENCY := 1
49USE_COHERENT_MEM := 0
50CTX_INCLUDE_AARCH32_REGS := 0
51ERRATA_A55_1530923 := 1
52ERRATA_A55_1221012 := 1
53
54# indicate the reset vector address can be programmed
55PROGRAMMABLE_RESET_ADDRESS := 1
56
57COLD_BOOT_SINGLE_CPU := 1
58
59MACH_MT8186 := 1
60$(eval $(call add_define,MACH_MT8186))
61
62include lib/coreboot/coreboot.mk
63