blob: 3c1c0fdb52cfa2ce0881b9f845a1b5c2e1a289c3 [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
Andrew Scull2d527c22018-11-27 14:21:08 +000010group("root") {
11 deps = [
12 "//src:hafnium(:aem_v8a_fvp_clang)",
David Brazdilc702a032020-01-31 15:44:11 +000013 "//src:hafnium(:android_aarch64_clang)",
Andrew Scull2d527c22018-11-27 14:21:08 +000014 "//src:hafnium(:qemu_aarch64_clang)",
David Brazdil3d7b88b2019-07-22 17:19:35 +010015 "//src:hafnium(:rpi4_clang)",
Andrew Walbran92627a82020-01-17 10:52:44 +000016 "//src/arch/aarch64/qemuloader:bl(:qemu_aarch64_clang)",
Andrew Scull2d527c22018-11-27 14:21:08 +000017 ]
18}
19
20group("test_root") {
21 testonly = true
22
23 deps = [
24 "//src:unit_tests(:host_fake_clang)",
Andrew Walbranfd379392019-03-14 17:45:04 +000025 "//test/arch(:aem_v8a_fvp_clang)",
Andrew Scull75da2d12018-12-09 21:25:45 +000026 "//test/arch(:qemu_aarch64_clang)",
David Brazdil3d7b88b2019-07-22 17:19:35 +010027 "//test/arch(:rpi4_clang)",
Andrew Walbranb1457602019-05-13 16:43:57 +010028 "//test/linux(:aem_v8a_fvp_vm_clang)",
29 "//test/linux(:qemu_aarch64_vm_clang)",
Andrew Walbran3eeaa402019-11-01 14:48:29 +000030 "//test/linux(:rpi4_vm_clang)",
Andrew Walbranb1457602019-05-13 16:43:57 +010031 "//test/vmapi(:aem_v8a_fvp_vm_clang)",
32 "//test/vmapi(:qemu_aarch64_vm_clang)",
Andrew Walbran3eeaa402019-11-01 14:48:29 +000033 "//test/vmapi(:rpi4_vm_clang)",
Andrew Scull3fe24082019-09-30 15:27:23 +010034 "//test/vmapi/arch/aarch64/gicv3:gicv3_test(:aem_v8a_fvp_vm_clang)",
35 "//test/vmapi/arch/aarch64/gicv3:gicv3_test(:qemu_aarch64_vm_clang)",
Andrew Scull2d527c22018-11-27 14:21:08 +000036 ]
37}
38
39# Describe each of the platforms used in this project.
40
41host_toolchain("host_fake") {
42 use_platform = true
Andrew Walbranbc737c42018-12-07 14:24:16 +000043 heap_pages = 60
Andrew Scull2d527c22018-11-27 14:21:08 +000044 max_cpus = 4
45 max_vms = 6
46}
47
Andrew Walbranb1457602019-05-13 16:43:57 +010048aarch64_toolchains("aem_v8a_fvp") {
49 cpu = "cortex-a57"
Andrew Walbran65821982019-04-16 14:34:03 +010050 origin_address = "0x80000000"
David Brazdil653261a2019-09-09 18:04:33 +010051 boot_flow = "//src/boot_flow:linux"
Andrew Walbran808531e2019-05-20 14:52:45 +010052 console = "//src/arch/aarch64/pl011"
Andrew Sculle2a525d2019-12-02 12:56:06 +000053 iommu = "//src/iommu:absent"
Andrew Walbranf1aa19e2018-12-10 13:42:40 +000054 gic_version = 3
55 gicd_base_address = "0x2f000000"
56 gicr_base_address = "0x2f100000"
Andrew Walbranbc737c42018-12-07 14:24:16 +000057 heap_pages = 60
Andrew Scull2d527c22018-11-27 14:21:08 +000058 max_cpus = 8
59 max_vms = 16
Andrew Walbran808531e2019-05-20 14:52:45 +010060 toolchain_args = {
61 pl011_base_address = "0x1c090000"
62 }
Andrew Scull2d527c22018-11-27 14:21:08 +000063}
64
Andrew Walbranb1457602019-05-13 16:43:57 +010065aarch64_toolchains("qemu_aarch64") {
66 cpu = "cortex-a57"
Andrew Scull2d527c22018-11-27 14:21:08 +000067 origin_address = "0x40001000"
David Brazdil653261a2019-09-09 18:04:33 +010068 boot_flow = "//src/boot_flow:linux"
Andrew Walbran808531e2019-05-20 14:52:45 +010069 console = "//src/arch/aarch64/pl011"
Andrew Sculle2a525d2019-12-02 12:56:06 +000070 iommu = "//src/iommu:absent"
Andrew Walbranf1aa19e2018-12-10 13:42:40 +000071 gic_version = 3
72 gicd_base_address = "0x08000000"
73 gicr_base_address = "0x080A0000"
Andrew Walbranbc737c42018-12-07 14:24:16 +000074 heap_pages = 60
Andrew Scull2d527c22018-11-27 14:21:08 +000075 max_cpus = 8
76 max_vms = 16
Andrew Walbran808531e2019-05-20 14:52:45 +010077 toolchain_args = {
78 pl011_base_address = "0x09000000"
79 }
Andrew Scull2d527c22018-11-27 14:21:08 +000080}
81
David Brazdil3d7b88b2019-07-22 17:19:35 +010082aarch64_toolchains("rpi4") {
83 cpu = "cortex-a72"
84 origin_address = "0x80000"
85 boot_flow = "//src/boot_flow:linux"
86 console = "//project/reference/rpi:mini_uart"
Andrew Sculle2a525d2019-12-02 12:56:06 +000087 iommu = "//src/iommu:absent"
David Brazdil3d7b88b2019-07-22 17:19:35 +010088 gic_version = 2
89 heap_pages = 60
90 max_cpus = 4
91 max_vms = 16
92 toolchain_args = {
93 gpio_base_address = "0xfe200000"
94 aux_base_address = "0xfe215000"
95 core_freq_mhz = 500
David Brazdilb38816f2020-01-31 16:31:10 +000096 hftest_ctrl = "//test/hftest:ctrl_uart"
David Brazdil3d7b88b2019-07-22 17:19:35 +010097 }
98}
David Brazdilc702a032020-01-31 15:44:11 +000099
100# Generic target which uses the Android boot flow. It is not intended to run on
101# any Android platform. It exists only to test building Android-specific code.
102aarch64_toolchains("android_aarch64") {
103 cpu = "cortex-a57"
104 origin_address = "0x0"
105 boot_flow = "//src/boot_flow:android"
106 console = "//src/arch/aarch64/pl011"
107 iommu = "//src/iommu:absent"
108 gic_version = 2
109 heap_pages = 60
110 max_cpus = 8
111 max_vms = 16
112 toolchain_args = {
113 pl011_base_address = "0x09000000"
114 }
115}