1# 2# Copyright (c) 2019-2023, ARM Limited and Contributors. All rights reserved. 3# Copyright (c) 2019-2023, Intel Corporation. All rights reserved. 4# Copyright (c) 2024, Altera Corporation. All rights reserved. 5# 6# SPDX-License-Identifier: BSD-3-Clause 7# 8 9PLAT_INCLUDES := \ 10 -Iplat/intel/soc/stratix10/include/ \ 11 -Iplat/intel/soc/common/drivers/ \ 12 -Iplat/intel/soc/common/include/ 13 14# Include GICv2 driver files 15include drivers/arm/gic/v2/gicv2.mk 16AGX_GICv2_SOURCES := \ 17 ${GICV2_SOURCES} \ 18 plat/common/plat_gicv2.c 19 20 21PLAT_BL_COMMON_SOURCES := \ 22 ${AGX_GICv2_SOURCES} \ 23 drivers/delay_timer/delay_timer.c \ 24 drivers/delay_timer/generic_delay_timer.c \ 25 drivers/ti/uart/aarch64/16550_console.S \ 26 lib/xlat_tables/aarch64/xlat_tables.c \ 27 lib/xlat_tables/xlat_tables_common.c \ 28 plat/intel/soc/common/aarch64/platform_common.c \ 29 plat/intel/soc/common/aarch64/plat_helpers.S \ 30 plat/intel/soc/common/drivers/ccu/ncore_ccu.c \ 31 plat/intel/soc/common/socfpga_delay_timer.c \ 32 plat/intel/soc/common/soc/socfpga_firewall.c 33 34BL2_SOURCES += \ 35 common/desc_image_load.c \ 36 drivers/mmc/mmc.c \ 37 drivers/intel/soc/stratix10/io/s10_memmap_qspi.c \ 38 drivers/io/io_storage.c \ 39 drivers/io/io_block.c \ 40 drivers/io/io_fip.c \ 41 drivers/partition/partition.c \ 42 drivers/partition/gpt.c \ 43 drivers/synopsys/emmc/dw_mmc.c \ 44 lib/cpus/aarch64/cortex_a53.S \ 45 plat/intel/soc/stratix10/bl2_plat_setup.c \ 46 plat/intel/soc/stratix10/soc/s10_clock_manager.c \ 47 plat/intel/soc/stratix10/soc/s10_memory_controller.c \ 48 plat/intel/soc/stratix10/soc/s10_mmc.c \ 49 plat/intel/soc/stratix10/soc/s10_pinmux.c \ 50 plat/intel/soc/common/bl2_plat_mem_params_desc.c \ 51 plat/intel/soc/common/socfpga_image_load.c \ 52 plat/intel/soc/common/socfpga_storage.c \ 53 plat/intel/soc/common/soc/socfpga_emac.c \ 54 plat/intel/soc/common/soc/socfpga_handoff.c \ 55 plat/intel/soc/common/soc/socfpga_mailbox.c \ 56 plat/intel/soc/common/soc/socfpga_reset_manager.c \ 57 plat/intel/soc/common/drivers/qspi/cadence_qspi.c \ 58 plat/intel/soc/common/drivers/ddr/ddr.c \ 59 plat/intel/soc/common/drivers/wdt/watchdog.c 60 61include lib/zlib/zlib.mk 62PLAT_INCLUDES += -Ilib/zlib 63BL2_SOURCES += $(ZLIB_SOURCES) 64 65BL31_SOURCES += \ 66 drivers/arm/cci/cci.c \ 67 lib/cpus/aarch64/aem_generic.S \ 68 lib/cpus/aarch64/cortex_a53.S \ 69 plat/common/plat_psci_common.c \ 70 plat/intel/soc/stratix10/soc/s10_clock_manager.c \ 71 plat/intel/soc/stratix10/bl31_plat_setup.c \ 72 plat/intel/soc/common/socfpga_psci.c \ 73 plat/intel/soc/common/socfpga_sip_svc.c \ 74 plat/intel/soc/common/socfpga_sip_svc_v2.c \ 75 plat/intel/soc/common/socfpga_topology.c \ 76 plat/intel/soc/common/sip/socfpga_sip_ecc.c \ 77 plat/intel/soc/common/sip/socfpga_sip_fcs.c \ 78 plat/intel/soc/common/soc/socfpga_mailbox.c \ 79 plat/intel/soc/common/soc/socfpga_reset_manager.c 80 81# Don't have the Linux kernel as a BL33 image by default 82ARM_LINUX_KERNEL_AS_BL33 := 0 83$(eval $(call assert_boolean,ARM_LINUX_KERNEL_AS_BL33)) 84$(eval $(call add_define,ARM_LINUX_KERNEL_AS_BL33)) 85$(eval $(call add_define,ARM_PRELOADED_DTB_BASE)) 86 87# Configs for Boot Source 88SOCFPGA_BOOT_SOURCE_SDMMC ?= 0 89SOCFPGA_BOOT_SOURCE_QSPI ?= 0 90SOCFPGA_BOOT_SOURCE_NAND ?= 0 91 92$(eval $(call assert_booleans,\ 93 $(sort \ 94 SOCFPGA_BOOT_SOURCE_SDMMC \ 95 SOCFPGA_BOOT_SOURCE_QSPI \ 96 SOCFPGA_BOOT_SOURCE_NAND \ 97))) 98$(eval $(call add_defines,\ 99 $(sort \ 100 SOCFPGA_BOOT_SOURCE_SDMMC \ 101 SOCFPGA_BOOT_SOURCE_QSPI \ 102 SOCFPGA_BOOT_SOURCE_NAND \ 103))) 104 105PROGRAMMABLE_RESET_ADDRESS := 0 106RESET_TO_BL2 := 1 107USE_COHERENT_MEM := 1 108