blob: 301eb46ee76f4ba9e68de180942f1ed2a6152573 [file] [log] [blame]
Andrew Walbrandc8ad202019-03-07 15:49:28 +00001# Copyright 2018 The Hafnium Authors.
Andrew Scull2d527c22018-11-27 14:21:08 +00002#
Andrew Walbran23417d82020-06-17 14:44:22 +01003# Use of this source code is governed by a BSD-style
4# license that can be found in the LICENSE file or at
5# https://opensource.org/licenses/BSD-3-Clause.
Andrew Scull2d527c22018-11-27 14:21:08 +00006
7import("//build/toolchain/embedded.gni")
8import("//build/toolchain/host.gni")
9
Olivier Deprez7e645932023-11-06 09:49:05 +010010group("aem_v8a_fvp_vhe") {
11 deps = [ "//src:hafnium(:aem_v8a_fvp_vhe_clang)" ]
12}
13
14group("qemu_aarch64_vhe") {
15 deps = [ "//src:hafnium(:qemu_aarch64_vhe_clang)" ]
16}
17
18group("rpi4") {
19 deps = [ "//src:hafnium(:rpi4_clang)" ]
20}
21
22group("secure_aem_v8a_fvp_vhe") {
23 deps = [ "//src:hafnium(:secure_aem_v8a_fvp_vhe_clang)" ]
24}
25
26group("secure_qemu_aarch64") {
27 deps = [ "//src:hafnium(:secure_qemu_aarch64_clang)" ]
28}
29
30group("secure_tc") {
31 deps = [ "//src:hafnium(:secure_tc_clang)" ]
32}
33
34group("secure_rd_fremont") {
35 deps = [ "//src:hafnium(:secure_rd_fremont_clang)" ]
36}
37
Jerry Wang49371572023-11-30 09:42:36 +000038group("secure_rd_fremont_cfg1") {
39 deps = [ "//src:hafnium(:secure_rd_fremont_cfg1_clang)" ]
40}
41
Andrew Scull2d527c22018-11-27 14:21:08 +000042group("root") {
43 deps = [
Olivier Deprez7e645932023-11-06 09:49:05 +010044 ":aem_v8a_fvp_vhe",
45 ":qemu_aarch64_vhe",
46 ":rpi4",
47 ":secure_aem_v8a_fvp_vhe",
48 ":secure_qemu_aarch64",
49 ":secure_rd_fremont",
Jerry Wang49371572023-11-30 09:42:36 +000050 ":secure_rd_fremont_cfg1",
Olivier Deprez7e645932023-11-06 09:49:05 +010051 ":secure_tc",
Raghu Krishnamurthye0ede852021-12-04 14:29:57 -080052 "//src/arch/aarch64/qemuloader:bl(:qemu_aarch64_vhe_clang)",
Andrew Scull2d527c22018-11-27 14:21:08 +000053 ]
54}
55
56group("test_root") {
57 testonly = true
58
59 deps = [
60 "//src:unit_tests(:host_fake_clang)",
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -070061 "//test/arch(:aem_v8a_fvp_vhe_clang)",
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -070062 "//test/arch(:qemu_aarch64_vhe_clang)",
David Brazdil3d7b88b2019-07-22 17:19:35 +010063 "//test/arch(:rpi4_clang)",
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -070064 "//test/linux(:aem_v8a_fvp_vhe_vm_clang)",
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -070065 "//test/linux(:qemu_aarch64_vhe_vm_clang)",
Andrew Walbran3eeaa402019-11-01 14:48:29 +000066 "//test/linux(:rpi4_vm_clang)",
Olivier Deprezacd0a4e2022-02-23 09:31:21 +010067 "//test/vmapi:partitions(:secure_aem_v8a_fvp_vhe_vm_clang)",
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -070068 "//test/vmapi(:aem_v8a_fvp_vhe_vm_clang)",
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -070069 "//test/vmapi(:qemu_aarch64_vhe_vm_clang)",
Andrew Walbran3eeaa402019-11-01 14:48:29 +000070 "//test/vmapi(:rpi4_vm_clang)",
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -070071 "//test/vmapi/arch/aarch64/gicv3:gicv3_test(:aem_v8a_fvp_vhe_vm_clang)",
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -070072 "//test/vmapi/arch/aarch64/gicv3:gicv3_test(:qemu_aarch64_vhe_vm_clang)",
Andrew Scull2d527c22018-11-27 14:21:08 +000073 ]
74}
75
76# Describe each of the platforms used in this project.
77
78host_toolchain("host_fake") {
79 use_platform = true
Andrew Walbranbc737c42018-12-07 14:24:16 +000080 heap_pages = 60
Andrew Scull2d527c22018-11-27 14:21:08 +000081 max_cpus = 4
82 max_vms = 6
83}
84
Nishant Sharma74e645a2023-08-10 18:37:51 +010085# RD (Reference Design) is a collection of resources to provide a representative
86# view of typical compute subsystems that can be designed and implemented using
87# specific generations of Arm IP. RD-Fremont is the first RD platform with Realm
88# Management Extension (RME) support.
89# For more information please refer:
90# https://neoverse-reference-design.docs.arm.com/en/latest/platforms/rdfremont/readme.html
91aarch64_toolchains("secure_rd_fremont") {
92 cpu = "cortex-a57"
93 origin_address = "0xF9000000"
94 boot_flow = "//src/boot_flow:spmc"
95 console = "//src/arch/aarch64/pl011"
96 iommu = "//src/iommu:absent"
97 gic_version = 4
98 gicd_base_address = "0x30000000"
99 gicr_base_address = "0x301C0000"
100 gicr_frames = 16
101 heap_pages = 180
102 max_cpus = 16
103 max_vms = 16
104 toolchain_args = {
105 plat_ffa = "//src/arch/aarch64/plat/ffa:spmc"
106 plat_psci = "//src/arch/aarch64/plat/psci:spmc"
107 plat_interrupts = "//src/arch/aarch64/plat/interrupts:gicv3"
108 secure_world = "1"
109 pl011_base_address = "0x2A410000"
110 enable_mte = "1"
111 plat_log_level = "LOG_LEVEL_INFO"
112 plat_num_virtual_interrupts_ids = 1024
113 }
114}
115
Jerry Wang49371572023-11-30 09:42:36 +0000116aarch64_toolchains("secure_rd_fremont_cfg1") {
117 cpu = "cortex-a57"
118 origin_address = "0xF9000000"
119 boot_flow = "//src/boot_flow:spmc"
120 console = "//src/arch/aarch64/pl011"
121 iommu = "//src/iommu:absent"
122 gic_version = 4
123 gicd_base_address = "0x30000000"
124 gicr_base_address = "0x30100000"
125 gicr_frames = 8
126 heap_pages = 180
127 max_cpus = 8
128 max_vms = 8
129 toolchain_args = {
130 plat_ffa = "//src/arch/aarch64/plat/ffa:spmc"
131 plat_psci = "//src/arch/aarch64/plat/psci:spmc"
132 plat_interrupts = "//src/arch/aarch64/plat/interrupts:gicv3"
133 secure_world = "1"
134 pl011_base_address = "0x2A410000"
135 enable_mte = "1"
136 plat_log_level = "LOG_LEVEL_INFO"
137 plat_num_virtual_interrupts_ids = 1024
138 }
139}
140
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -0700141aarch64_toolchains("secure_aem_v8a_fvp_vhe") {
142 cpu = "cortex-a57"
143 origin_address = "0x06000000"
144 boot_flow = "//src/boot_flow:spmc"
145 console = "//src/arch/aarch64/pl011"
146 iommu = "//src/arch/aarch64/arm_smmuv3"
147 gic_version = 3
Madhukar Pappireddy48050f52023-08-29 13:52:33 -0500148 gic_enable_espi = 1
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -0700149 gicd_base_address = "0x2f000000"
150 gicr_base_address = "0x2f100000"
Varun Wadekarfa4b3ac2022-02-14 17:19:18 +0000151 gicr_frames = 8
Raghu Krishnamurthyf8956392022-09-20 09:51:05 -0700152 heap_pages = 180
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -0700153 max_cpus = 8
154 max_vms = 16
Raghu Krishnamurthy510aa3e2021-11-28 07:20:45 -0800155 branch_protection = "standard"
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -0700156 toolchain_args = {
157 plat_ffa = "//src/arch/aarch64/plat/ffa:spmc"
158 plat_psci = "//src/arch/aarch64/plat/psci:spmc"
159 plat_interrupts = "//src/arch/aarch64/plat/interrupts:gicv3"
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -0700160 secure_world = "1"
161 pl011_base_address = "0x1c090000"
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -0700162 smmu_base_address = "0x2b400000"
163 smmu_memory_size = "0x100000"
Maksims Svecovsc3cda252021-09-30 12:20:11 +0100164 enable_mte = "1"
Varun Wadekar4cba5e42022-09-29 17:39:14 +0100165 plat_log_level = "LOG_LEVEL_INFO"
Madhukar Pappireddy48050f52023-08-29 13:52:33 -0500166 plat_num_virtual_interrupts_ids = 5120
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -0700167 }
168}
169
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -0700170aarch64_toolchains("aem_v8a_fvp_vhe") {
171 cpu = "cortex-a57"
172 origin_address = "0x80000000"
173 boot_flow = "//src/boot_flow:linux"
174 console = "//src/arch/aarch64/pl011"
175 iommu = "//src/arch/aarch64/arm_smmuv3"
176 gic_version = 3
177 gicd_base_address = "0x2f000000"
178 gicr_base_address = "0x2f100000"
Varun Wadekarfa4b3ac2022-02-14 17:19:18 +0000179 gicr_frames = 8
Raghu Krishnamurthyf8956392022-09-20 09:51:05 -0700180 heap_pages = 180
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -0700181 max_cpus = 8
182 max_vms = 16
Raghu Krishnamurthy510aa3e2021-11-28 07:20:45 -0800183 branch_protection = "standard"
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -0700184 toolchain_args = {
185 plat_ffa = "//src/arch/aarch64/plat/ffa:hypervisor"
186 pl011_base_address = "0x1c090000"
187 smmu_base_address = "0x2b400000"
188 smmu_memory_size = "0x100000"
Varun Wadekar4cba5e42022-09-29 17:39:14 +0100189 plat_log_level = "LOG_LEVEL_INFO"
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -0700190 }
191}
192
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -0700193aarch64_toolchains("qemu_aarch64_vhe") {
194 cpu = "cortex-a57"
195 origin_address = "0x40001000"
196 boot_flow = "//src/boot_flow:linux"
197 console = "//src/arch/aarch64/pl011"
198 iommu = "//src/iommu:absent"
199 gic_version = 3
200 gicd_base_address = "0x08000000"
201 gicr_base_address = "0x080A0000"
Varun Wadekarfa4b3ac2022-02-14 17:19:18 +0000202 gicr_frames = 8
Raghu Krishnamurthyf8956392022-09-20 09:51:05 -0700203 heap_pages = 180
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -0700204 max_cpus = 8
205 max_vms = 16
206 toolchain_args = {
Olivier Deprezd82b5e02021-07-05 11:16:16 +0200207 plat_ffa = "//src/arch/aarch64/plat/ffa:hypervisor"
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -0700208 pl011_base_address = "0x09000000"
Varun Wadekar4cba5e42022-09-29 17:39:14 +0100209 plat_log_level = "LOG_LEVEL_INFO"
Raghu Krishnamurthy8e680992021-06-15 20:19:47 -0700210 }
211}
212
Olivier Deprezf17c61e2023-01-30 13:50:25 +0100213aarch64_toolchains("secure_qemu_aarch64") {
214 cpu = "cortex-a57"
215 origin_address = "0xe100000"
216 boot_flow = "//src/boot_flow:spmc"
217 console = "//src/arch/aarch64/pl011"
218 iommu = "//src/iommu:absent"
219 gic_version = 3
220 gicd_base_address = "0x08000000"
221 gicr_base_address = "0x080A0000"
222 gicr_frames = 8
223 heap_pages = 180
224 max_cpus = 8
225 max_vms = 16
226 branch_protection = "standard"
227 toolchain_args = {
228 plat_ffa = "//src/arch/aarch64/plat/ffa:spmc"
229 plat_psci = "//src/arch/aarch64/plat/psci:spmc"
230 plat_interrupts = "//src/arch/aarch64/plat/interrupts:gicv3"
231 secure_world = "1"
232 pl011_base_address = "0x09000000"
233 hftest_ctrl = "//test/hftest:ctrl_uart"
Olivier Deprezf17c61e2023-01-30 13:50:25 +0100234 enable_mte = "1"
235 plat_log_level = "LOG_LEVEL_INFO"
Madhukar Pappireddyffbe2e22023-02-02 17:45:30 -0600236 plat_num_virtual_interrupts_ids = 1024
Olivier Deprezf17c61e2023-01-30 13:50:25 +0100237 }
238}
239
David Brazdil3d7b88b2019-07-22 17:19:35 +0100240aarch64_toolchains("rpi4") {
241 cpu = "cortex-a72"
242 origin_address = "0x80000"
243 boot_flow = "//src/boot_flow:linux"
Olivier Depreza7015472023-10-16 20:17:50 +0200244 console = "//project/reference/rpi4:mini_uart"
Andrew Sculle2a525d2019-12-02 12:56:06 +0000245 iommu = "//src/iommu:absent"
David Brazdil3d7b88b2019-07-22 17:19:35 +0100246 gic_version = 2
Raghu Krishnamurthyf8956392022-09-20 09:51:05 -0700247 heap_pages = 180
David Brazdil3d7b88b2019-07-22 17:19:35 +0100248 max_cpus = 4
249 max_vms = 16
250 toolchain_args = {
Daniel Boulby0029f482021-03-25 14:19:21 +0000251 plat_ffa = "//src/arch/aarch64/plat/ffa:hypervisor"
David Brazdil3d7b88b2019-07-22 17:19:35 +0100252 gpio_base_address = "0xfe200000"
253 aux_base_address = "0xfe215000"
254 core_freq_mhz = 500
David Brazdilb38816f2020-01-31 16:31:10 +0000255 hftest_ctrl = "//test/hftest:ctrl_uart"
Varun Wadekar4cba5e42022-09-29 17:39:14 +0100256 plat_log_level = "LOG_LEVEL_INFO"
David Brazdil3d7b88b2019-07-22 17:19:35 +0100257 }
258}
David Brazdilc702a032020-01-31 15:44:11 +0000259
Olivier Deprezb5ebdd72023-11-08 12:48:20 +0100260# The Total Compute platform provides an envelope for Arm's latest client IPs.
261# Release notes and user manual for the open source software stack targeting
262# the Total Compute Fixed Virtual Platform (FVP) are found here:
263# https://totalcompute.docs.arm.com/en/latest/
Usama Ariff0996a52021-08-09 14:28:30 +0100264aarch64_toolchains("secure_tc") {
Arunachalam Ganapathyf20727f2020-04-28 20:23:13 +0100265 cpu = "cortex-a57"
266 origin_address = "0xfd000000"
Olivier Deprez59e35f72020-11-10 17:15:18 +0100267 boot_flow = "//src/boot_flow:spmc"
Arunachalam Ganapathyf20727f2020-04-28 20:23:13 +0100268 console = "//src/arch/aarch64/pl011"
269 iommu = "//src/iommu:absent"
Madhukar Pappireddy89ee8cc2021-10-29 10:03:18 -0500270 gic_version = 4
Arunachalam Ganapathyf20727f2020-04-28 20:23:13 +0100271 gicd_base_address = "0x30000000"
Usama Arif2c636ff2021-04-01 11:09:25 +0100272 gicr_base_address = "0x30080000"
Varun Wadekarfa4b3ac2022-02-14 17:19:18 +0000273 gicr_frames = 8
Raghu Krishnamurthyf8956392022-09-20 09:51:05 -0700274 heap_pages = 180
Arunachalam Ganapathy51e81572021-01-20 14:57:41 +0000275 max_cpus = 8
Arunachalam Ganapathyf20727f2020-04-28 20:23:13 +0100276 max_vms = 16
277 toolchain_args = {
Daniel Boulby0029f482021-03-25 14:19:21 +0000278 plat_ffa = "//src/arch/aarch64/plat/ffa:spmc"
Olivier Deprezcf039902021-01-25 15:32:39 +0100279 plat_psci = "//src/arch/aarch64/plat/psci:spmc"
Olivier Deprezcc0eb842021-04-07 14:03:59 +0200280 plat_interrupts = "//src/arch/aarch64/plat/interrupts:gicv3"
Arunachalam Ganapathyf20727f2020-04-28 20:23:13 +0100281 secure_world = "1"
282 pl011_base_address = "0x7ff80000"
Maksims Svecovsc3cda252021-09-30 12:20:11 +0100283 enable_mte = "1"
Varun Wadekar4cba5e42022-09-29 17:39:14 +0100284 plat_log_level = "LOG_LEVEL_INFO"
Madhukar Pappireddyffbe2e22023-02-02 17:45:30 -0600285 plat_num_virtual_interrupts_ids = 1024
Arunachalam Ganapathyf20727f2020-04-28 20:23:13 +0100286 }
287}