1# 2# Copyright (c) 2017, ARM Limited and Contributors. All rights reserved. 3# 4# SPDX-License-Identifier: BSD-3-Clause 5# 6 7# Enable version2 of image loading 8LOAD_IMAGE_V2 := 1 9 10# On Poplar, the TSP can execute from TZC secure area in DRAM. 11POPLAR_TSP_RAM_LOCATION := dram 12ifeq (${POPLAR_TSP_RAM_LOCATION}, dram) 13 POPLAR_TSP_RAM_LOCATION_ID = POPLAR_DRAM_ID 14else ifeq (${POPLAR_TSP_RAM_LOCATION}, sram) 15 POPLAR_TSP_RAM_LOCATION_ID := POPLAR_SRAM_ID 16else 17 $(error "Currently unsupported POPLAR_TSP_RAM_LOCATION value") 18endif 19$(eval $(call add_define,POPLAR_TSP_RAM_LOCATION_ID)) 20 21POPLAR_DRAM_SIZE ?= two_gig 22ifeq (${POPLAR_DRAM_SIZE}, two_gig) 23 POPLAR_DRAM_SIZE_ID = POPLAR_DRAM_SIZE_2G 24else ifeq (${POPLAR_DRAM_SIZE}, one_gig) 25 POPLAR_DRAM_SIZE_ID = POPLAR_DRAM_SIZE_1G 26else 27 $(error "Currently unsupported POPLAR_DRAM_SIZE value") 28endif 29$(eval $(call add_define,POPLAR_DRAM_SIZE_ID)) 30 31POPLAR_RECOVERY := 0 32$(eval $(call add_define,POPLAR_RECOVERY)) 33 34NEED_BL33 := yes 35 36COLD_BOOT_SINGLE_CPU := 1 37PROGRAMMABLE_RESET_ADDRESS := 1 38CTX_INCLUDE_FPREGS := 1 39ENABLE_PLAT_COMPAT := 0 40ERRATA_A53_855873 := 1 41ERRATA_A53_835769 := 1 42ERRATA_A53_843419 := 1 43ENABLE_SVE_FOR_NS := 0 44 45WORKAROUND_CVE_2017_5715 := 0 46 47ARM_GIC_ARCH := 2 48$(eval $(call add_define,ARM_GIC_ARCH)) 49 50PLAT_PL061_MAX_GPIOS := 104 51$(eval $(call add_define,PLAT_PL061_MAX_GPIOS)) 52 53PLAT_INCLUDES := -Iplat/hisilicon/poplar/include \ 54 -Iinclude/plat/arm/common/ \ 55 -Iplat/hisilicon/poplar \ 56 -Iinclude/common/tbbr \ 57 -Iinclude/drivers/synopsys \ 58 -Iinclude/drivers/io 59 60PLAT_BL_COMMON_SOURCES := \ 61 lib/aarch64/xlat_tables.c \ 62 drivers/delay_timer/generic_delay_timer.c \ 63 drivers/arm/gic/common/gic_common.c \ 64 drivers/arm/gic/v2/gicv2_helpers.c \ 65 drivers/delay_timer/delay_timer.c \ 66 drivers/arm/pl011/pl011_console.S \ 67 drivers/arm/gic/v2/gicv2_main.c \ 68 plat/arm/common/aarch64/arm_helpers.S \ 69 plat/arm/common/arm_gicv2.c \ 70 plat/common/plat_gicv2.c \ 71 plat/hisilicon/poplar/aarch64/platform_common.c 72 73BL1_SOURCES += \ 74 lib/cpus/aarch64/cortex_a53.S \ 75 drivers/arm/pl061/pl061_gpio.c \ 76 drivers/emmc/emmc.c \ 77 drivers/synopsys/emmc/dw_mmc.c \ 78 drivers/io/io_storage.c \ 79 drivers/io/io_block.c \ 80 drivers/gpio/gpio.c \ 81 drivers/io/io_fip.c \ 82 drivers/io/io_memmap.c \ 83 plat/hisilicon/poplar/bl1_plat_setup.c \ 84 plat/hisilicon/poplar/plat_storage.c 85 86BL2_SOURCES += \ 87 drivers/arm/pl061/pl061_gpio.c \ 88 drivers/emmc/emmc.c \ 89 drivers/synopsys/emmc/dw_mmc.c \ 90 drivers/io/io_storage.c \ 91 drivers/io/io_block.c \ 92 drivers/io/io_fip.c \ 93 drivers/gpio/gpio.c \ 94 drivers/io/io_memmap.c \ 95 plat/hisilicon/poplar/bl2_plat_setup.c \ 96 plat/hisilicon/poplar/plat_storage.c 97 98ifeq (${LOAD_IMAGE_V2},1) 99BL2_SOURCES += \ 100 plat/hisilicon/poplar/bl2_plat_mem_params_desc.c \ 101 plat/hisilicon/poplar/poplar_image_load.c \ 102 common/desc_image_load.c 103endif 104 105BL31_SOURCES += \ 106 lib/cpus/aarch64/aem_generic.S \ 107 lib/cpus/aarch64/cortex_a53.S \ 108 plat/common/aarch64/plat_psci_common.c \ 109 plat/hisilicon/poplar/bl31_plat_setup.c \ 110 plat/hisilicon/poplar/plat_topology.c \ 111 plat/hisilicon/poplar/plat_pm.c 112