Deepak Pandey | 9cbacf6 | 2018-08-08 10:32:51 +0530 | [diff] [blame] | 1 | # |
Govindraj Raja | a8200ed | 2023-09-20 13:37:40 -0500 | [diff] [blame] | 2 | # Copyright (c) 2018-2023, Arm Limited. All rights reserved. |
Deepak Pandey | 9cbacf6 | 2018-08-08 10:32:51 +0530 | [diff] [blame] | 3 | # |
| 4 | # SPDX-License-Identifier: BSD-3-Clause |
| 5 | # |
| 6 | |
| 7 | |
| 8 | N1SDP_BASE := plat/arm/board/n1sdp |
| 9 | |
| 10 | INTERCONNECT_SOURCES := ${N1SDP_BASE}/n1sdp_interconnect.c |
| 11 | |
| 12 | PLAT_INCLUDES := -I${N1SDP_BASE}/include |
| 13 | |
| 14 | |
John Tsichritzis | 56369c1 | 2019-02-19 13:49:06 +0000 | [diff] [blame] | 15 | N1SDP_CPU_SOURCES := lib/cpus/aarch64/neoverse_n1.S |
Deepak Pandey | 9cbacf6 | 2018-08-08 10:32:51 +0530 | [diff] [blame] | 16 | |
Govindraj Raja | a8200ed | 2023-09-20 13:37:40 -0500 | [diff] [blame] | 17 | # Neoverse N1 cores support Armv8.2 extensions |
| 18 | ARM_ARCH_MAJOR := 8 |
| 19 | ARM_ARCH_MINOR := 2 |
| 20 | |
Alexei Fedorov | 84f1b5d | 2020-03-23 18:45:17 +0000 | [diff] [blame] | 21 | # GIC-600 configuration |
Andre Przywara | e1cc130 | 2020-03-25 15:50:38 +0000 | [diff] [blame] | 22 | GICV3_SUPPORT_GIC600 := 1 |
Alexei Fedorov | 84f1b5d | 2020-03-23 18:45:17 +0000 | [diff] [blame] | 23 | GICV3_IMPL_GIC600_MULTICHIP := 1 |
Deepak Pandey | 9cbacf6 | 2018-08-08 10:32:51 +0530 | [diff] [blame] | 24 | |
Alexei Fedorov | 84f1b5d | 2020-03-23 18:45:17 +0000 | [diff] [blame] | 25 | # Include GICv3 driver files |
| 26 | include drivers/arm/gic/v3/gicv3.mk |
| 27 | |
| 28 | N1SDP_GIC_SOURCES := ${GICV3_SOURCES} \ |
Deepak Pandey | 9cbacf6 | 2018-08-08 10:32:51 +0530 | [diff] [blame] | 29 | plat/common/plat_gicv3.c \ |
| 30 | plat/arm/common/arm_gicv3.c \ |
Deepak Pandey | 9cbacf6 | 2018-08-08 10:32:51 +0530 | [diff] [blame] | 31 | |
| 32 | PLAT_BL_COMMON_SOURCES := ${N1SDP_BASE}/n1sdp_plat.c \ |
| 33 | ${N1SDP_BASE}/aarch64/n1sdp_helper.S |
| 34 | |
sah01 | 6ec01e8 | 2021-06-06 14:38:01 +0530 | [diff] [blame] | 35 | BL1_SOURCES := ${N1SDP_CPU_SOURCES} \ |
| 36 | ${INTERCONNECT_SOURCES} \ |
| 37 | ${N1SDP_BASE}/n1sdp_err.c \ |
| 38 | ${N1SDP_BASE}/n1sdp_trusted_boot.c \ |
| 39 | ${N1SDP_BASE}/n1sdp_bl1_setup.c \ |
| 40 | drivers/arm/sbsa/sbsa.c |
| 41 | |
| 42 | BL2_SOURCES := ${N1SDP_BASE}/n1sdp_security.c \ |
| 43 | ${N1SDP_BASE}/n1sdp_err.c \ |
| 44 | ${N1SDP_BASE}/n1sdp_trusted_boot.c \ |
| 45 | lib/utils/mem_region.c \ |
| 46 | ${N1SDP_BASE}/n1sdp_bl2_setup.c \ |
sahil | f1c8861 | 2022-03-15 14:11:43 +0530 | [diff] [blame] | 47 | ${N1SDP_BASE}/n1sdp_image_load.c \ |
sah01 | 6ec01e8 | 2021-06-06 14:38:01 +0530 | [diff] [blame] | 48 | drivers/arm/css/sds/sds.c |
Deepak Pandey | 9cbacf6 | 2018-08-08 10:32:51 +0530 | [diff] [blame] | 49 | |
| 50 | BL31_SOURCES := ${N1SDP_CPU_SOURCES} \ |
| 51 | ${INTERCONNECT_SOURCES} \ |
| 52 | ${N1SDP_GIC_SOURCES} \ |
sah01 | 6ec01e8 | 2021-06-06 14:38:01 +0530 | [diff] [blame] | 53 | ${N1SDP_BASE}/n1sdp_bl31_setup.c \ |
Werner Lewis | f32d2ad | 2023-02-21 14:40:12 +0000 | [diff] [blame] | 54 | ${N1SDP_BASE}/n1sdp_pm.c \ |
Deepak Pandey | 9cbacf6 | 2018-08-08 10:32:51 +0530 | [diff] [blame] | 55 | ${N1SDP_BASE}/n1sdp_topology.c \ |
Manoj Kumar | 69bebd8 | 2019-06-21 17:07:13 +0100 | [diff] [blame] | 56 | ${N1SDP_BASE}/n1sdp_security.c \ |
| 57 | drivers/arm/css/sds/sds.c |
Deepak Pandey | 9cbacf6 | 2018-08-08 10:32:51 +0530 | [diff] [blame] | 58 | |
Andre Przywara | c2db651 | 2020-07-06 11:19:41 +0530 | [diff] [blame] | 59 | FDT_SOURCES += fdts/${PLAT}-single-chip.dts \ |
sah01 | 6ec01e8 | 2021-06-06 14:38:01 +0530 | [diff] [blame] | 60 | fdts/${PLAT}-multi-chip.dts \ |
sahil | f1c8861 | 2022-03-15 14:11:43 +0530 | [diff] [blame] | 61 | ${N1SDP_BASE}/fdts/n1sdp_fw_config.dts \ |
| 62 | ${N1SDP_BASE}/fdts/n1sdp_tb_fw_config.dts \ |
| 63 | ${N1SDP_BASE}/fdts/n1sdp_nt_fw_config.dts |
sah01 | 6ec01e8 | 2021-06-06 14:38:01 +0530 | [diff] [blame] | 64 | |
| 65 | FW_CONFIG := ${BUILD_PLAT}/fdts/n1sdp_fw_config.dtb |
| 66 | TB_FW_CONFIG := ${BUILD_PLAT}/fdts/n1sdp_tb_fw_config.dtb |
sahil | f1c8861 | 2022-03-15 14:11:43 +0530 | [diff] [blame] | 67 | NT_FW_CONFIG := ${BUILD_PLAT}/fdts/n1sdp_nt_fw_config.dtb |
sah01 | 6ec01e8 | 2021-06-06 14:38:01 +0530 | [diff] [blame] | 68 | |
| 69 | # Add the FW_CONFIG to FIP and specify the same to certtool |
| 70 | $(eval $(call TOOL_ADD_PAYLOAD,${FW_CONFIG},--fw-config,${FW_CONFIG})) |
| 71 | # Add the TB_FW_CONFIG to FIP and specify the same to certtool |
| 72 | $(eval $(call TOOL_ADD_PAYLOAD,${TB_FW_CONFIG},--tb-fw-config,${TB_FW_CONFIG})) |
sahil | f1c8861 | 2022-03-15 14:11:43 +0530 | [diff] [blame] | 73 | # Add the NT_FW_CONFIG to FIP and specify the same to certtool |
| 74 | $(eval $(call TOOL_ADD_PAYLOAD,${NT_FW_CONFIG},--nt-fw-config,${NT_FW_CONFIG})) |
sah01 | 6ec01e8 | 2021-06-06 14:38:01 +0530 | [diff] [blame] | 75 | |
Vishnu Banavath | 7cac3de | 2022-06-20 18:20:21 +0100 | [diff] [blame] | 76 | N1SDP_SPMC_MANIFEST_DTS := ${N1SDP_BASE}/fdts/${PLAT}_optee_spmc_manifest.dts |
| 77 | FDT_SOURCES += ${N1SDP_SPMC_MANIFEST_DTS} |
| 78 | N1SDP_TOS_FW_CONFIG := ${BUILD_PLAT}/fdts/${PLAT}_optee_spmc_manifest.dtb |
| 79 | |
| 80 | # Add the TOS_FW_CONFIG to FIP and specify the same to certtool |
| 81 | $(eval $(call TOOL_ADD_PAYLOAD,${N1SDP_TOS_FW_CONFIG},--tos-fw-config,${N1SDP_TOS_FW_CONFIG})) |
| 82 | |
sah01 | 6ec01e8 | 2021-06-06 14:38:01 +0530 | [diff] [blame] | 83 | # Setting to 0 as no NVCTR in N1SDP |
| 84 | N1SDP_FW_NVCTR_VAL := 0 |
| 85 | TFW_NVCTR_VAL := ${N1SDP_FW_NVCTR_VAL} |
| 86 | NTFW_NVCTR_VAL := ${N1SDP_FW_NVCTR_VAL} |
| 87 | |
| 88 | # Add N1SDP_FW_NVCTR_VAL |
| 89 | $(eval $(call add_define,N1SDP_FW_NVCTR_VAL)) |
Deepak Pandey | 9cbacf6 | 2018-08-08 10:32:51 +0530 | [diff] [blame] | 90 | |
| 91 | # TF-A not required to load the SCP Images |
| 92 | override CSS_LOAD_SCP_IMAGES := 0 |
| 93 | |
Deepak Pandey | 9cbacf6 | 2018-08-08 10:32:51 +0530 | [diff] [blame] | 94 | override NEED_BL2U := no |
| 95 | |
Deepak Pandey | 9cbacf6 | 2018-08-08 10:32:51 +0530 | [diff] [blame] | 96 | # 32 bit mode not supported |
| 97 | override CTX_INCLUDE_AARCH32_REGS := 0 |
| 98 | |
| 99 | override ARM_PLAT_MT := 1 |
| 100 | |
| 101 | # Select SCMI/SDS drivers instead of SCPI/BOM driver for communicating with the |
| 102 | # SCP during power management operations and for SCP RAM Firmware transfer. |
| 103 | CSS_USE_SCMI_SDS_DRIVER := 1 |
| 104 | |
| 105 | # System coherency is managed in hardware |
| 106 | HW_ASSISTED_COHERENCY := 1 |
| 107 | |
| 108 | # When building for systems with hardware-assisted coherency, there's no need to |
| 109 | # use USE_COHERENT_MEM. Require that USE_COHERENT_MEM must be set to 0 too. |
| 110 | USE_COHERENT_MEM := 0 |
Chandni Cherukuri | b912087 | 2020-03-05 11:49:57 +0530 | [diff] [blame] | 111 | |
| 112 | # Enable the flag since N1SDP has a system level cache |
Javier Almansa Sobrino | 9faad3c | 2020-10-23 13:22:07 +0100 | [diff] [blame] | 113 | NEOVERSE_Nx_EXTERNAL_LLC := 1 |
Deepak Pandey | 9cbacf6 | 2018-08-08 10:32:51 +0530 | [diff] [blame] | 114 | include plat/arm/common/arm_common.mk |
| 115 | include plat/arm/css/common/css_common.mk |
Deepak Pandey | 9cbacf6 | 2018-08-08 10:32:51 +0530 | [diff] [blame] | 116 | include plat/arm/board/common/board_common.mk |