blob: fa931da87038c266f4e1cf66961acb8cf27adb7a [file] [log] [blame]
Brad Bishopbec4ebc2022-08-03 09:55:16 -04001# Configuration for gem5 running on ARM64
2
3#@TYPE: Machine
4#@NAME: Gem5 arm64 machine
5#@DESCRIPTION: Machine configuration for Gem5 arm64
6
7TUNE_FEATURES = "aarch64"
8
9require conf/machine/include/arm/arch-armv8a.inc
10
11MACHINE_FEATURES = "optee pci"
12
13KERNEL_IMAGETYPES = "Image vmlinux"
14KERNEL_IMAGETYPE = "Image"
15
16IMAGE_FSTYPES += "tar.bz2 ext4"
17
18SERIAL_CONSOLES = "115200;ttyAMA0"
19
20EXTRA_IMAGEDEPENDS += "virtual/gem5-bootloader"
21
22PREFERRED_PROVIDER_virtual/kernel ?= "linux-yocto"
23PREFERRED_VERSION_linux-yocto ?= "5.4%"
24
25
26# Uncomment the following if you need to build gem5 provided bootloader, else
27# using standard bootloader by Linux aarch64
28# Use gem5 provided bootloader
29# PREFERRED_PROVIDER_virtual/gem5-bootloader = "gem5-aarch64-bootloader"
30
31# use the dtb stored in the kernel recipe
32# KERNEL_DEVICETREE ?= "gem5-arm64/armv8_gem5_v2_4cpu.dtb"
33
34# Use Linux aarch64 boot wrapper with FDT support and generated
35# dtb (gem5-aarch64-dtb.bb)
36PREFERRED_PROVIDER_virtual/gem5-bootloader = "boot-wrapper-aarch64"
37
38BOOT_WRAPPER_AARCH64_CMDLINE ?= "\
39 earlyprintk=pl011,0x1c090000 console=ttyAMA0 root=/dev/vda rw mem=1G \
40 "
41# Use baremetal profile and axf file so dtb is in axf file
42GEM5_RUN_PROFILE = "configs/example/arm/baremetal.py"
43GEM5_RUN_KERNEL = "linux-system.axf"
44GEM5_RUN_EXTRA = ""
45GEM5_RUN_DTB = ""
46GEM5_RUN_CMDLINE = ""
47
48EXTRA_IMAGEDEPENDS += "gem5-aarch64-native"
49
50# As this is a virtual target that will not be used in the real world there is
51# no need for real SSH keys. Disable rng-tools (which takes too long to
52# initialise) and install the pre-generated keys.
53PACKAGECONFIG:remove:pn-openssh = "rng-tools"
54MACHINE_EXTRA_RRECOMMENDS += "ssh-pregen-hostkeys"