blob: 6e700b9b1b93ac74d4f92e5c56758a76f6983851 [file] [log] [blame]
Antonio Nino Diaz493bf332016-12-14 14:31:32 +00001#
Venkatesh Yadav Abbarapu35a8be92019-04-04 14:23:32 +05302# Copyright (c) 2013-2020, ARM Limited and Contributors. All rights reserved.
Soren Brinkmann76fcae32016-03-06 20:16:27 -08003#
dp-armfa3cf0b2017-05-03 09:38:09 +01004# SPDX-License-Identifier: BSD-3-Clause
Soren Brinkmann76fcae32016-03-06 20:16:27 -08005
Soren Brinkmannba8309d2017-04-06 11:44:27 -07006override ERRATA_A53_855873 := 1
Masahiro Yamada8cf895c2016-12-19 17:41:47 +09007override PROGRAMMABLE_RESET_ADDRESS := 1
Soren Brinkmann76fcae32016-03-06 20:16:27 -08008PSCI_EXTENDED_STATE_ID := 1
9A53_DISABLE_NON_TEMPORAL_HINT := 0
Soren Brinkmann6d1ba582016-07-08 14:45:14 -070010SEPARATE_CODE_AND_RODATA := 1
Siva Durga Prasad Paladuguefd431b2018-04-30 20:12:12 +053011ZYNQMP_WDT_RESTART := 0
Venkatesh Yadav Abbarapu35a8be92019-04-04 14:23:32 +053012ZYNQMP_IPI_CRC_CHECK := 0
Masahiro Yamada8cf895c2016-12-19 17:41:47 +090013override RESET_TO_BL31 := 1
Siva Durga Prasad Paladugu60bfbc92018-09-24 22:51:49 -070014override GICV2_G0_FOR_EL3 := 1
15override WARMBOOT_ENABLE_DCACHE_EARLY := 1
Soren Brinkmann76fcae32016-03-06 20:16:27 -080016
David Cunadoc5b0c0f2017-10-31 23:19:21 +000017# Do not enable SVE
18ENABLE_SVE_FOR_NS := 0
19
Dimitris Papastamos8e5bd5e2018-01-24 16:41:14 +000020WORKAROUND_CVE_2017_5715 := 0
21
Soren Brinkmann4a9ca042016-04-14 10:27:00 -070022ifdef ZYNQMP_ATF_MEM_BASE
23 $(eval $(call add_define,ZYNQMP_ATF_MEM_BASE))
24
25 ifndef ZYNQMP_ATF_MEM_SIZE
26 $(error "ZYNQMP_ATF_BASE defined without ZYNQMP_ATF_SIZE")
27 endif
28 $(eval $(call add_define,ZYNQMP_ATF_MEM_SIZE))
Soren Brinkmann76fcae32016-03-06 20:16:27 -080029
Soren Brinkmann4a9ca042016-04-14 10:27:00 -070030 ifdef ZYNQMP_ATF_MEM_PROGBITS_SIZE
31 $(eval $(call add_define,ZYNQMP_ATF_MEM_PROGBITS_SIZE))
32 endif
Soren Brinkmann76fcae32016-03-06 20:16:27 -080033endif
34
Soren Brinkmann4a9ca042016-04-14 10:27:00 -070035ifdef ZYNQMP_BL32_MEM_BASE
36 $(eval $(call add_define,ZYNQMP_BL32_MEM_BASE))
37
38 ifndef ZYNQMP_BL32_MEM_SIZE
39 $(error "ZYNQMP_BL32_BASE defined without ZYNQMP_BL32_SIZE")
40 endif
41 $(eval $(call add_define,ZYNQMP_BL32_MEM_SIZE))
42endif
Soren Brinkmann76fcae32016-03-06 20:16:27 -080043
Soren Brinkmann99c0d7b2016-06-10 09:57:14 -070044ZYNQMP_CONSOLE ?= cadence
45$(eval $(call add_define_val,ZYNQMP_CONSOLE,ZYNQMP_CONSOLE_ID_${ZYNQMP_CONSOLE}))
46
Siva Durga Prasad Paladuguefd431b2018-04-30 20:12:12 +053047ifdef ZYNQMP_WDT_RESTART
48$(eval $(call add_define,ZYNQMP_WDT_RESTART))
49endif
50
Venkatesh Yadav Abbarapu35a8be92019-04-04 14:23:32 +053051ifdef ZYNQMP_IPI_CRC_CHECK
52 $(eval $(call add_define,ZYNQMP_IPI_CRC_CHECK))
53endif
54
55PLAT_INCLUDES := -Iinclude/plat/arm/common/ \
56 -Iinclude/plat/arm/common/aarch64/ \
Jolly Shahb07fd0c2019-01-08 11:25:28 -080057 -Iplat/xilinx/common/include/ \
Wendy Liangc31c48b2019-01-21 13:45:48 +053058 -Iplat/xilinx/common/ipi_mailbox_service/ \
Soren Brinkmann76fcae32016-03-06 20:16:27 -080059 -Iplat/xilinx/zynqmp/include/ \
Wendy Liangf8fec362017-09-06 09:39:55 -070060 -Iplat/xilinx/zynqmp/pm_service/ \
Soren Brinkmann76fcae32016-03-06 20:16:27 -080061
Venkatesh Yadav Abbarapu1ad5f662020-12-03 20:27:18 -070062# Include GICv2 driver files
63include drivers/arm/gic/v2/gicv2.mk
64
Soby Mathewcc037c12016-04-08 16:42:58 +010065PLAT_BL_COMMON_SOURCES := lib/xlat_tables/xlat_tables_common.c \
66 lib/xlat_tables/aarch64/xlat_tables.c \
Soren Brinkmanne5bdcaa2016-06-22 09:02:56 -070067 drivers/delay_timer/delay_timer.c \
68 drivers/delay_timer/generic_delay_timer.c \
Venkatesh Yadav Abbarapu1ad5f662020-12-03 20:27:18 -070069 ${GICV2_SOURCES} \
Soby Mathew17231132016-08-08 12:33:06 +010070 drivers/cadence/uart/aarch64/cdns_console.S \
Soren Brinkmann76fcae32016-03-06 20:16:27 -080071 plat/arm/common/arm_cci.c \
Soby Mathew0eb965b2016-07-07 08:45:56 +010072 plat/arm/common/arm_common.c \
Soren Brinkmann76fcae32016-03-06 20:16:27 -080073 plat/arm/common/arm_gicv2.c \
74 plat/common/plat_gicv2.c \
Jolly Shahc2583ab2019-01-08 11:31:49 -080075 plat/xilinx/common/ipi.c \
Venkatesh Yadav Abbarapu44e563a2021-01-23 22:16:47 -070076 plat/xilinx/zynqmp/zynqmp_ipi.c \
77 plat/common/aarch64/crash_console_helpers.S \
Soren Brinkmann76fcae32016-03-06 20:16:27 -080078 plat/xilinx/zynqmp/aarch64/zynqmp_helpers.S \
79 plat/xilinx/zynqmp/aarch64/zynqmp_common.c
80
81BL31_SOURCES += drivers/arm/cci/cci.c \
82 lib/cpus/aarch64/aem_generic.S \
83 lib/cpus/aarch64/cortex_a53.S \
Soby Mathewf6c41082016-05-03 12:31:18 +010084 plat/common/plat_psci_common.c \
Wendy Liangc31c48b2019-01-21 13:45:48 +053085 plat/xilinx/common/ipi_mailbox_service/ipi_mailbox_svc.c \
Jolly Shah259afe52019-01-09 12:37:57 -080086 plat/xilinx/common/pm_service/pm_ipi.c \
Venkatesh Yadav Abbarapu1463dd52020-01-07 03:25:16 -070087 plat/xilinx/common/plat_startup.c \
Soren Brinkmann76fcae32016-03-06 20:16:27 -080088 plat/xilinx/zynqmp/bl31_zynqmp_setup.c \
89 plat/xilinx/zynqmp/plat_psci.c \
90 plat/xilinx/zynqmp/plat_zynqmp.c \
Soren Brinkmann76fcae32016-03-06 20:16:27 -080091 plat/xilinx/zynqmp/plat_topology.c \
92 plat/xilinx/zynqmp/sip_svc_setup.c \
93 plat/xilinx/zynqmp/pm_service/pm_svc_main.c \
94 plat/xilinx/zynqmp/pm_service/pm_api_sys.c \
Rajan Vaja0ac2be12018-01-17 02:39:21 -080095 plat/xilinx/zynqmp/pm_service/pm_api_pinctrl.c \
Rajan Vaja5529a012018-01-17 02:39:23 -080096 plat/xilinx/zynqmp/pm_service/pm_api_ioctl.c \
Rajan Vaja35116132018-01-17 02:39:25 -080097 plat/xilinx/zynqmp/pm_service/pm_api_clock.c \
Wendy Liangc31c48b2019-01-21 13:45:48 +053098 plat/xilinx/zynqmp/pm_service/pm_client.c
99
Venkatesh Yadav Abbarapu2dfbba42020-07-13 21:18:01 -0600100BL31_CPPFLAGS += -fno-jump-tables
101
Wendy Liangc31c48b2019-01-21 13:45:48 +0530102ifneq (${RESET_TO_BL31},1)
103 $(error "Using BL31 as the reset vector is only one option supported on ZynqMP. Please set RESET_TO_BL31 to 1.")
104endif