mirror of
https://git.yoctoproject.org/meta-arm
synced 2026-07-17 16:17:09 +00:00
Compare commits
57 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 81ed80b573 | |||
| d7bd5a0518 | |||
| 8961c3e10a | |||
| 1f815d6e9a | |||
| b1e01a2ced | |||
| 878fabbfc7 | |||
| d2d7bfa38f | |||
| fe35ff5ba8 | |||
| 71686ac05c | |||
| e9d695f132 | |||
| f86bf75a6e | |||
| 2d7af5f9d7 | |||
| ee1b109e36 | |||
| ba82ea920a | |||
| e82b83c92e | |||
| 30077d988f | |||
| 85f2a93c0a | |||
| e4520e2a63 | |||
| 328c85778b | |||
| 4e14a1c5ee | |||
| 3d9cf26be1 | |||
| afd9bf7ee6 | |||
| e82d9fdd49 | |||
| eec8640c16 | |||
| 4e3f2de11d | |||
| 04d9436f9d | |||
| b8e69c8bb3 | |||
| 1de9c1ffb8 | |||
| ae5fed3951 | |||
| e0c855cc24 | |||
| 8f2dcc25f0 | |||
| 646239278a | |||
| 6873363ede | |||
| b36052691e | |||
| 8fe982f8d0 | |||
| 77f4023c82 | |||
| c5ebdb44d2 | |||
| 6c622ca3da | |||
| de18bcf3d2 | |||
| c9eda152b0 | |||
| 9851e5714a | |||
| 318b47ae05 | |||
| 4482136c29 | |||
| 65d41185b0 | |||
| 10e5981995 | |||
| 48ffd24725 | |||
| a727cfe74b | |||
| 12af38f31b | |||
| 7ca13b4f15 | |||
| 33e88e8a3a | |||
| 301bf3b5fd | |||
| f3227b7a8e | |||
| bd2e25959f | |||
| 6c08dd6c76 | |||
| a637fa88f2 | |||
| ef9b9c8e70 | |||
| 235f2a8ca7 |
+47
-27
@@ -1,5 +1,4 @@
|
||||
# Use our custom Crops-derived image
|
||||
image: $CI_REGISTRY/$CI_PROJECT_NAMESPACE/yocto-builder:master
|
||||
image: ghcr.io/siemens/kas/kas:3.2
|
||||
|
||||
# First do a common bootstrap, and then build all the targets
|
||||
stages:
|
||||
@@ -10,27 +9,33 @@ stages:
|
||||
# Common job fragment to get a worker ready
|
||||
.setup:
|
||||
stage: build
|
||||
interruptible: true
|
||||
variables:
|
||||
KAS_WORK_DIR: $CI_PROJECT_DIR/work
|
||||
KAS_REPO_REF_DIR: $CI_BUILDS_DIR/persist/repos
|
||||
SSTATE_DIR: $CI_BUILDS_DIR/persist/sstate
|
||||
DL_DIR: $CI_BUILDS_DIR/persist/downloads
|
||||
BB_LOGCONFIG: $CI_PROJECT_DIR/ci/logging.yml
|
||||
TOOLCHAIN_DIR: $CI_BUILDS_DIR/persist/toolchains
|
||||
IMAGE_DIR: $CI_PROJECT_DIR/work/build/tmp/deploy/images
|
||||
TOOLCHAIN_LINK_DIR: $CI_PROJECT_DIR/work/build/toolchains
|
||||
before_script:
|
||||
- echo KAS_WORK_DIR = $KAS_WORK_DIR
|
||||
- echo SSTATE_DIR = $SSTATE_DIR
|
||||
- echo DL_DIR = $DL_DIR
|
||||
- mkdir --verbose --parents $KAS_WORK_DIR $KAS_REPO_REF_DIR $SSTATE_DIR $DL_DIR
|
||||
- rm -rf $KAS_WORK_DIR
|
||||
- mkdir --verbose --parents $KAS_WORK_DIR $KAS_REPO_REF_DIR $SSTATE_DIR $DL_DIR $TOOLCHAIN_DIR $TOOLCHAIN_LINK_DIR
|
||||
# Must do this here, as it's the only way to make sure the toolchain is installed on the same builder
|
||||
- ./ci/get-binary-toolchains $DL_DIR $TOOLCHAIN_DIR $TOOLCHAIN_LINK_DIR
|
||||
|
||||
# Generalised fragment to do a Kas build
|
||||
.build:
|
||||
extends: .setup
|
||||
script:
|
||||
- KASFILES=$(./ci/jobs-to-kas $CI_JOB_NAME)
|
||||
- kas shell --update --force-checkout $KASFILES -c 'cat conf/*.conf'
|
||||
- kas build $KASFILES
|
||||
- ./ci/check-warnings $KAS_WORK_DIR/build/warnings.log
|
||||
|
||||
- KASFILES=$(./ci/jobs-to-kas $CI_JOB_NAME)
|
||||
- kas shell --update --force-checkout $KASFILES -c 'cat conf/*.conf'
|
||||
- kas build $KASFILES
|
||||
- ./ci/check-warnings $KAS_WORK_DIR/build/warnings.log
|
||||
|
||||
#
|
||||
# Prep stage, update repositories once
|
||||
@@ -41,7 +46,6 @@ update-repos:
|
||||
script:
|
||||
- flock --verbose --timeout 60 $KAS_REPO_REF_DIR ./ci/update-repos
|
||||
|
||||
|
||||
#
|
||||
# Bootstrap stage, bootstrap and machine coverage
|
||||
#
|
||||
@@ -55,6 +59,7 @@ n1sdp/bootstrap:
|
||||
# What percentage of machines in the layer do we build
|
||||
machine-coverage:
|
||||
stage: bootstrap
|
||||
interruptible: true
|
||||
script:
|
||||
- ./ci/check-machine-coverage
|
||||
coverage: '/Coverage: \d+/'
|
||||
@@ -64,6 +69,14 @@ machine-coverage:
|
||||
# Build stage, the actual build jobs
|
||||
#
|
||||
|
||||
# Validate layers are Yocto Project Compatible
|
||||
check-layers:
|
||||
extends: .setup
|
||||
coverage: '/Coverage: \d+/'
|
||||
script:
|
||||
- kas shell --update --force-checkout ci/base.yml:ci/meta-python.yml --command \
|
||||
"$CI_PROJECT_DIR/ci/check-layers.py $CI_PROJECT_DIR/ci/check-layers.yml $CI_PROJECT_DIR $KAS_WORK_DIR"
|
||||
|
||||
corstone500:
|
||||
extends: .build
|
||||
|
||||
@@ -79,7 +92,7 @@ fvp-base:
|
||||
fvp-base-arm32:
|
||||
extends: .build
|
||||
|
||||
fvp-base-arm32/external-gcc-arm32:
|
||||
fvp-base-arm32/external-gccarm:
|
||||
extends: .build
|
||||
|
||||
fvp-baser-aemv8r64:
|
||||
@@ -121,25 +134,25 @@ n1sdp/armgcc:
|
||||
qemu-cortex-a53:
|
||||
extends: .build
|
||||
|
||||
qemuarm:
|
||||
qemuarm/testimage:
|
||||
extends: .build
|
||||
|
||||
qemuarm64-sbsa:
|
||||
extends: .build
|
||||
|
||||
qemuarm64-secureboot:
|
||||
qemuarm64-secureboot/testimage:
|
||||
extends: .build
|
||||
|
||||
qemuarm64-secureboot/clang:
|
||||
qemuarm64-secureboot/clang/testimage:
|
||||
extends: .build
|
||||
|
||||
qemuarm64-secureboot/clang/musl:
|
||||
qemuarm64-secureboot/clang/musl/testimage:
|
||||
extends: .build
|
||||
|
||||
qemuarm64-secureboot/musl:
|
||||
qemuarm64-secureboot/musl/testimage:
|
||||
extends: .build
|
||||
|
||||
qemuarmv5:
|
||||
qemuarmv5/testimage:
|
||||
extends: .build
|
||||
|
||||
sgi575:
|
||||
@@ -153,14 +166,6 @@ tc0:
|
||||
# Utility tasks, not executed automatically
|
||||
#
|
||||
|
||||
# Report on disk usage
|
||||
usage:
|
||||
extends: .setup
|
||||
stage: prep
|
||||
when: manual
|
||||
script:
|
||||
- du -h -s $DL_DIR $SSTATE_DIR $KAS_REPO_REF_DIR
|
||||
|
||||
delete-dl-dir:
|
||||
extends: .setup
|
||||
stage: prep
|
||||
@@ -175,6 +180,21 @@ delete-repo-dir:
|
||||
script:
|
||||
- rm -rf $KAS_REPO_REF_DIR/*
|
||||
|
||||
# Delete all sstate
|
||||
delete-sstate:
|
||||
extends: .setup
|
||||
stage: prep
|
||||
when: manual
|
||||
script:
|
||||
- rm -rf $SSTATE_DIR/*
|
||||
|
||||
delete-toolchains:
|
||||
extends: .setup
|
||||
stage: prep
|
||||
when: manual
|
||||
script:
|
||||
- rm -rf $TOOLCHAIN_DIR/*
|
||||
|
||||
# Wipe out old sstate
|
||||
prune-sstate:
|
||||
extends: .setup
|
||||
@@ -183,10 +203,10 @@ prune-sstate:
|
||||
script:
|
||||
- find $SSTATE_DIR -type f -atime +30 -delete
|
||||
|
||||
# Delete all sstate
|
||||
delete-sstate:
|
||||
# Report on disk usage
|
||||
usage:
|
||||
extends: .setup
|
||||
stage: prep
|
||||
when: manual
|
||||
script:
|
||||
- rm -rf $SSTATE_DIR/*
|
||||
- du -h -s $DL_DIR $SSTATE_DIR $KAS_REPO_REF_DIR $TOOLCHAIN_DIR
|
||||
|
||||
+2
-1
@@ -22,6 +22,7 @@ repos:
|
||||
|
||||
env:
|
||||
BB_LOGCONFIG: ""
|
||||
TOOLCHAIN_DIR: ""
|
||||
|
||||
local_conf_header:
|
||||
base: |
|
||||
@@ -29,11 +30,11 @@ local_conf_header:
|
||||
PACKAGE_CLASSES = "package_ipk"
|
||||
LICENSE_FLAGS_WHITELIST += "armcompiler"
|
||||
PACKAGECONFIG_remove_pn-qemu-system-native = "gtk+ sdl"
|
||||
EXTRA_IMAGE_FEATURES_append = " debug-tweaks"
|
||||
BB_NUMBER_THREADS = "16"
|
||||
PARALLEL_MAKE = "-j16"
|
||||
INHERIT += "rm_work"
|
||||
PACKAGECONFIG_append_pn-perf = " coresight"
|
||||
ERROR_QA = "${WARN_QA}"
|
||||
noptest: |
|
||||
DISTRO_FEATURES_remove = "ptest"
|
||||
|
||||
|
||||
Executable
+43
@@ -0,0 +1,43 @@
|
||||
#! /usr/bin/env python3
|
||||
|
||||
import argparse
|
||||
import pathlib
|
||||
import re
|
||||
import subprocess
|
||||
import sys
|
||||
|
||||
import yaml
|
||||
|
||||
if __name__ == "__main__":
|
||||
parser = argparse.ArgumentParser()
|
||||
parser.add_argument("config", type=argparse.FileType())
|
||||
parser.add_argument("metaarm", type=pathlib.Path, help="Path to meta-arm")
|
||||
parser.add_argument("others", type=pathlib.Path, help="Path to parent of dependencies")
|
||||
args = parser.parse_args()
|
||||
|
||||
config = yaml.safe_load(args.config)
|
||||
layers = config["layers"]
|
||||
dependencies = config["dependencies"]
|
||||
|
||||
found_layers = [p for p in args.metaarm.glob("meta-*") if p.is_dir()]
|
||||
print(f"Testing {len(layers)} layers: {', '.join(layers)}.")
|
||||
print(f"Found {len(found_layers)} layers in meta-arm.")
|
||||
print()
|
||||
|
||||
cli = ["yocto-check-layer-wrapper",]
|
||||
cli.extend([args.metaarm / layer for layer in layers])
|
||||
cli.append("--dependency")
|
||||
cli.extend([args.others / layer for layer in dependencies])
|
||||
|
||||
passed = 0
|
||||
process = subprocess.Popen(cli, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, universal_newlines=True)
|
||||
while True:
|
||||
line = process.stdout.readline()
|
||||
if process.poll() is not None:
|
||||
break
|
||||
print(line.strip())
|
||||
if re.search(r"meta-.+ PASS", line):
|
||||
passed += 1
|
||||
|
||||
print(f"Coverage: {int(passed / len(found_layers) * 100)}%")
|
||||
sys.exit(process.returncode)
|
||||
@@ -0,0 +1,7 @@
|
||||
layers:
|
||||
- meta-arm
|
||||
- meta-arm-bsp
|
||||
- meta-arm-toolchain
|
||||
- meta-gem5
|
||||
dependencies:
|
||||
- meta-openembedded/meta-oe
|
||||
+2
-1
@@ -7,7 +7,8 @@ set -e -u
|
||||
|
||||
LOGFILE=$1
|
||||
|
||||
if test -s $LOGFILE; then
|
||||
LINES=$(grep --invert-match "attempting MIRRORS if available" $LOGFILE | wc -l)
|
||||
if test "$LINES" -ne 0; then
|
||||
echo ==============================
|
||||
echo The build had warnings/errors:
|
||||
echo ==============================
|
||||
|
||||
@@ -5,4 +5,4 @@ local_conf_header:
|
||||
cc: |
|
||||
PNBLACKLIST[gcc-cross-arm] = "Using external toolchain"
|
||||
TCMODE = "external-arm"
|
||||
EXTERNAL_TOOLCHAIN = "/usr/local/gcc-arm-10.2-2020.11-aarch64-arm-none-linux-gnueabihf"
|
||||
EXTERNAL_TOOLCHAIN = "${TOPDIR}/toolchains/${TARGET_ARCH}"
|
||||
Executable
+46
@@ -0,0 +1,46 @@
|
||||
#!/bin/bash
|
||||
set -u
|
||||
|
||||
HOST_ARCH=$(uname -m)
|
||||
VER="10.2-2020.11"
|
||||
|
||||
DOWNLOAD_DIR=$1
|
||||
TOOLCHAIN_DIR=$2
|
||||
TOOLCHAIN_LINK_DIR=$3
|
||||
|
||||
# These should be already created by .gitlab-ci.yml, but do here if run outside of that env
|
||||
mkdir -p $DOWNLOAD_DIR $TOOLCHAIN_DIR $TOOLCHAIN_LINK_DIR
|
||||
|
||||
if [ $HOST_ARCH = "aarch64" ]; then
|
||||
#AArch64 Linux hosted cross compilers
|
||||
|
||||
#AArch32 target with hard float (arm-none-linux-gnueabihf)
|
||||
wget -P $DOWNLOAD_DIR -nc https://developer.arm.com/-/media/Files/downloads/gnu-a/$VER/binrel/gcc-arm-$VER-$HOST_ARCH-arm-none-linux-gnueabihf.tar.xz
|
||||
elif [ $HOST_ARCH = "x86_64" ]; then
|
||||
#x86_64 Linux hosted cross compilers
|
||||
|
||||
#AArch32 target with hard float (arm-linux-none-gnueabihf)
|
||||
wget -P $DOWNLOAD_DIR -nc https://developer.arm.com/-/media/Files/downloads/gnu-a/$VER/binrel/gcc-arm-$VER-$HOST_ARCH-arm-none-linux-gnueabihf.tar.xz
|
||||
|
||||
#AArch64 GNU/Linux target (aarch64-none-linux-gnu)
|
||||
wget -P $DOWNLOAD_DIR -nc https://developer.arm.com/-/media/Files/downloads/gnu-a/$VER/binrel/gcc-arm-$VER-$HOST_ARCH-aarch64-none-linux-gnu.tar.xz
|
||||
|
||||
#AArch64 GNU/Linux target (aarch64_be-none-linux-gnu)
|
||||
wget -P $DOWNLOAD_DIR -nc https://developer.arm.com/-/media/Files/downloads/gnu-a/$VER/binrel/gcc-arm-$VER-$HOST_ARCH-aarch64_be-none-linux-gnu.tar.xz
|
||||
else
|
||||
echo "ERROR - Unknown build arch of $HOST_ARCH"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
for i in arm aarch64 aarch64_be; do
|
||||
if [ ! -d $TOOLCHAIN_DIR/gcc-arm-$VER-$HOST_ARCH-$i-none-linux-gnu*/ ]; then
|
||||
if [ ! -f $DOWNLOAD_DIR/gcc-arm-$VER-$HOST_ARCH-$i-none-linux-gnu*.tar.xz ]; then
|
||||
continue
|
||||
fi
|
||||
|
||||
tar -C $TOOLCHAIN_DIR -axvf $DOWNLOAD_DIR/gcc-arm-$VER-$HOST_ARCH-$i-none-linux-gnu*.tar.xz
|
||||
fi
|
||||
|
||||
# Setup a link for the toolchain to use local to the building machine (e.g., not in a shared location)
|
||||
ln -s $TOOLCHAIN_DIR/gcc-arm-$VER-$HOST_ARCH-$i-none-linux-gnu* $TOOLCHAIN_LINK_DIR/$i
|
||||
done
|
||||
@@ -5,6 +5,11 @@ header:
|
||||
|
||||
machine: qemuarm64-secureboot
|
||||
|
||||
local_conf_header:
|
||||
bugs: |
|
||||
# Only ping until errors can be resolved
|
||||
TEST_SUITES = "ping"
|
||||
|
||||
target:
|
||||
- core-image-base
|
||||
- perf
|
||||
|
||||
@@ -4,3 +4,8 @@ header:
|
||||
- base.yml
|
||||
|
||||
machine: qemuarmv5
|
||||
|
||||
local_conf_header:
|
||||
bugs: |
|
||||
# Remove parselogs until errors can be resolved
|
||||
TEST_SUITES_remove = "parselogs"
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
header:
|
||||
version: 9
|
||||
|
||||
local_conf_header:
|
||||
testimage: |
|
||||
IMAGE_CLASSES += "testimage"
|
||||
TESTIMAGE_AUTO = "1"
|
||||
slirp: |
|
||||
TEST_RUNQEMUPARAMS = "slirp"
|
||||
TEST_SERVER_IP = "127.0.0.1"
|
||||
QEMU_USE_SLIRP = "1"
|
||||
packages: |
|
||||
IMAGE_FEATURES_append = " ssh-server-dropbear"
|
||||
|
||||
# Multiple targets are available, put it down to just one
|
||||
target:
|
||||
- core-image-base
|
||||
+32
@@ -4,4 +4,36 @@
|
||||
# default rootfs, so use vda3 for guest lvm
|
||||
XENGUEST_MANAGER_VOLUME_DEVICE ?= "/dev/vda3"
|
||||
|
||||
# We need to extend the wks search path to be able to find the wks file set in
|
||||
# ARM_AUTONOMY_WKS_FILE.
|
||||
WKS_SEARCH_PATH_prepend := "${ARM_AUTONOMY_ARM_BSP_DYNAMIC_DIR}/wic:"
|
||||
|
||||
ARM_AUTONOMY_WKS_FILE ?= "arm-autonomy-fvp-base-disk.wks.in"
|
||||
# set wks file only if INITRAMFS_IMAGE_BUNDLE is not set
|
||||
WKS_FILE = "${@bb.utils.contains('INITRAMFS_IMAGE_BUNDLE', '1', '',\
|
||||
'${ARM_AUTONOMY_WKS_FILE}', d)}"
|
||||
|
||||
XEN_FILE ?= "xen-fvp-base"
|
||||
DTB_FILE ?= "${@ get_xen_dtb_filename(d)}"
|
||||
XEN_ADDR ?= "0x84000000"
|
||||
DTB_ADDR ?= "0x83000000"
|
||||
|
||||
FVP_DATA += "cluster0.cpu0=${DEPLOY_DIR_IMAGE}/${XEN_FILE}@${XEN_ADDR} \
|
||||
cluster0.cpu0=${DEPLOY_DIR_IMAGE}/${DTB_FILE}@${DTB_ADDR}"
|
||||
|
||||
# Set the wks guest partition size and unit. It must be aligned with the sum of
|
||||
# all XENGUEST_IMAGE_DISK_SIZE set for the guests. By default, LVM2 metadata is
|
||||
# 1 MiB per physical volume, hence it needs to be taken into account when
|
||||
# setting GUEST_PART_SIZE. The XENGUEST_IMAGE_DISK_SIZE default value is 4GiB.
|
||||
GUEST_PART_SIZE ?= "4097"
|
||||
GUEST_PART_SIZE_UNIT ?= "M"
|
||||
|
||||
XENGUEST_NETWORK_BRIDGE_MEMBERS ?= "eth0"
|
||||
|
||||
# This function uses the "KERNEL_DEVICETREE" variable and manipulates it to
|
||||
# return the xen kernel device tree file name.
|
||||
def get_xen_dtb_filename(d):
|
||||
kernel_dtb_filename = d.getVar('KERNEL_DEVICETREE',d)
|
||||
xen_dtb_filename = os.path.splitext(os.path.basename(kernel_dtb_filename))[0] + '-xen.dtb'
|
||||
return xen_dtb_filename
|
||||
|
||||
|
||||
@@ -84,3 +84,7 @@ IMAGE_EFI_BOOT_FILES += "\
|
||||
${@ d.getVar('GRUB_CFG_EXTRA_FILE',d) or '' \
|
||||
if bb.utils.contains('DISTRO_FEATURES', 'alternate-kernel', True, False, d) and \
|
||||
d.getVar('PREFERRED_PROVIDER_alternate/kernel') else ''}"
|
||||
|
||||
# Additionnal kernel modules are necessary for n1sdp to be able to mount FAT
|
||||
# filesystems using CP437.
|
||||
MACHINE_ESSENTIAL_EXTRA_RDEPENDS_append = " kernel-module-nls-cp437 kernel-module-nls-iso8859-1"
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
# short-description: Create a disk image
|
||||
# long-description: Creates a partitioned disk image that the user
|
||||
# can directly dd to boot media.
|
||||
|
||||
# For FVP Base first partition is empty to keep compatibility with disk.img
|
||||
part --label empty --source empty --ondisk sda --size="1M" --system-id 8e --align 1024
|
||||
|
||||
# Second partition is rootfs normally populated as /dev/vda2
|
||||
part / --source rootfs --ondisk sda --fstype=ext4 --label root --align 1024
|
||||
|
||||
# Third partition to accomodate guests images normally populated as /dev/vda3 (used by XENGUEST_MANAGER_VOLUME_DEVICE)
|
||||
part --label guests --source empty --ondisk sda --size="${GUEST_PART_SIZE}${GUEST_PART_SIZE_UNIT}" --system-id 8e --align 1024
|
||||
|
||||
# Fourth partition is user defined entry normally populated as /dev/vda4
|
||||
${AUTONOMY_HOST_EXTRA_PARTITION}
|
||||
|
||||
bootloader --ptable msdos
|
||||
@@ -1,8 +1,3 @@
|
||||
FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
|
||||
|
||||
SRC_URI += "file://0001-vif-nat-fix-hostname.patch \
|
||||
"
|
||||
|
||||
PACKAGECONFIG_remove = "\
|
||||
${@bb.utils.contains('DISTRO_FEATURES', \
|
||||
'arm-autonomy-host', \
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}-4.14:"
|
||||
|
||||
SRC_URI += "file://0001-vif-nat-fix-hostname.patch \
|
||||
"
|
||||
@@ -17,6 +17,9 @@ case "${XENGUEST_NETWORK_TYPE:=}" in
|
||||
echo "vif = ['script=vif-bridge,bridge=${BRIDGE_NAME}']" >> "${guestcfgfile:?}"
|
||||
log info "Network type is bridge: ${BRIDGE_NAME}"
|
||||
;;
|
||||
none)
|
||||
log info "Network type is none"
|
||||
;;
|
||||
*)
|
||||
log error "XENGUEST_NETWORK_TYPE=$XENGUEST_NETWORK_TYPE invalid"
|
||||
;;
|
||||
|
||||
@@ -66,7 +66,7 @@ case "$1" in
|
||||
stop)
|
||||
echo "Stopping xenguest"
|
||||
# update guest list
|
||||
guestlist=$(xenguest-manager status | grep Running | cut -d ":" -f1)
|
||||
guestlist=$(xenguest-manager status | grep Running | cut -d " " -f1)
|
||||
for f in ${guestlist}; do
|
||||
xenguest-manager shutdown "${f}" --kill
|
||||
done
|
||||
|
||||
-77
@@ -1,77 +0,0 @@
|
||||
From 3bc59ed7bc26c967cfe6eb9c1ef9a1ef9108e99d Mon Sep 17 00:00:00 2001
|
||||
From: Luca Fancellu <luca.fancellu@arm.com>
|
||||
Date: Tue, 23 Mar 2021 16:16:39 +0000
|
||||
Subject: [PATCH 4/4] xen/evtchn: Change irq_info lock to raw_spinlock_t
|
||||
|
||||
Unmask operation must be called with interrupt disabled,
|
||||
on preempt_rt spin_lock_irqsave/spin_unlock_irqrestore
|
||||
don't disable/enable interrupts, so use raw_* implementation
|
||||
and change lock variable in struct irq_info from spinlock_t
|
||||
to raw_spinlock_t
|
||||
|
||||
Issue-Id: SCM-2147
|
||||
|
||||
Upstream-Status: Pending
|
||||
Signed-off-by: Luca Fancellu <luca.fancellu@arm.com>
|
||||
---
|
||||
drivers/xen/events/events_base.c | 12 ++++++------
|
||||
1 file changed, 6 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/drivers/xen/events/events_base.c b/drivers/xen/events/events_base.c
|
||||
index 7bd03f6e0422..b91c19b90b8b 100644
|
||||
--- a/drivers/xen/events/events_base.c
|
||||
+++ b/drivers/xen/events/events_base.c
|
||||
@@ -108,7 +108,7 @@ struct irq_info {
|
||||
unsigned short eoi_cpu; /* EOI must happen on this cpu-1 */
|
||||
unsigned int irq_epoch; /* If eoi_cpu valid: irq_epoch of event */
|
||||
u64 eoi_time; /* Time in jiffies when to EOI. */
|
||||
- spinlock_t lock;
|
||||
+ raw_spinlock_t lock;
|
||||
|
||||
union {
|
||||
unsigned short virq;
|
||||
@@ -280,7 +280,7 @@ static int xen_irq_info_common_setup(struct irq_info *info,
|
||||
info->evtchn = evtchn;
|
||||
info->cpu = cpu;
|
||||
info->mask_reason = EVT_MASK_REASON_EXPLICIT;
|
||||
- spin_lock_init(&info->lock);
|
||||
+ raw_spin_lock_init(&info->lock);
|
||||
|
||||
ret = set_evtchn_to_irq(evtchn, irq);
|
||||
if (ret < 0)
|
||||
@@ -432,28 +432,28 @@ static void do_mask(struct irq_info *info, u8 reason)
|
||||
{
|
||||
unsigned long flags;
|
||||
|
||||
- spin_lock_irqsave(&info->lock, flags);
|
||||
+ raw_spin_lock_irqsave(&info->lock, flags);
|
||||
|
||||
if (!info->mask_reason)
|
||||
mask_evtchn(info->evtchn);
|
||||
|
||||
info->mask_reason |= reason;
|
||||
|
||||
- spin_unlock_irqrestore(&info->lock, flags);
|
||||
+ raw_spin_unlock_irqrestore(&info->lock, flags);
|
||||
}
|
||||
|
||||
static void do_unmask(struct irq_info *info, u8 reason)
|
||||
{
|
||||
unsigned long flags;
|
||||
|
||||
- spin_lock_irqsave(&info->lock, flags);
|
||||
+ raw_spin_lock_irqsave(&info->lock, flags);
|
||||
|
||||
info->mask_reason &= ~reason;
|
||||
|
||||
if (!info->mask_reason)
|
||||
unmask_evtchn(info->evtchn);
|
||||
|
||||
- spin_unlock_irqrestore(&info->lock, flags);
|
||||
+ raw_spin_unlock_irqrestore(&info->lock, flags);
|
||||
}
|
||||
|
||||
#ifdef CONFIG_X86
|
||||
--
|
||||
2.17.1
|
||||
|
||||
@@ -44,8 +44,6 @@ python() {
|
||||
and oe.utils.any_distro_features(d, "arm-autonomy-host arm-autonomy-guest"):
|
||||
if LooseVersion(kernelVersion) < '5.9':
|
||||
d.appendVar('SRC_URI', ' file://files/0001-arm-arm64-xen-Fix-to-convert-percpu-address-to-gfn-c.patch' )
|
||||
if '5.10' <= LooseVersion(kernelVersion) < '5.12':
|
||||
d.appendVar('SRC_URI', ' file://files/0001-xen-evtchn-Change-irq_info-lock-to-raw_spinlock_t.patch' )
|
||||
|
||||
if kernelVersion and LooseVersion(kernelVersion) < '5.10':
|
||||
if oe.utils.any_distro_features(d, "arm-autonomy-host arm-autonomy-guest"):
|
||||
|
||||
@@ -15,3 +15,17 @@ UBOOT_MACHINE = "vexpress_aemv8a_semi_defconfig"
|
||||
KERNEL_IMAGETYPE = "Image"
|
||||
|
||||
KERNEL_DEVICETREE = "arm/fvp-base-gicv3-psci-custom.dtb"
|
||||
|
||||
FVP_PROVIDER ?= "fvp-base-a-aem-native"
|
||||
FVP_EXE ?= "FVP_Base_RevC-2xAEMvA"
|
||||
FVP_CONFIG[cache_state_modelled] ?= "0"
|
||||
FVP_CONFIG[bp.secureflashloader.fname] ?= "${DEPLOY_DIR_IMAGE}/bl1-fvp.bin"
|
||||
FVP_CONFIG[bp.flashloader0.fname] ?= "${DEPLOY_DIR_IMAGE}/fip-fvp.bin"
|
||||
FVP_CONFIG[bp.virtioblockdevice.image_path] ?= "${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.wic"
|
||||
FVP_DATA ?= "cluster0.cpu0=${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}@0x80080000 \
|
||||
cluster0.cpu0=${DEPLOY_DIR_IMAGE}/fvp-base-gicv3-psci-custom.dtb@0x83000000"
|
||||
FVP_CONSOLE ?= "terminal_0"
|
||||
FVP_TERMINALS[bp.terminal_0] ?= "Console"
|
||||
FVP_TERMINALS[bp.terminal_1] ?= ""
|
||||
FVP_TERMINALS[bp.terminal_2] ?= ""
|
||||
FVP_TERMINALS[bp.terminal_3] ?= ""
|
||||
|
||||
@@ -8,7 +8,9 @@
|
||||
MACHINE_FEATURES = "optee"
|
||||
|
||||
IMAGE_CLASSES += "image_types_disk_img"
|
||||
IMAGE_FSTYPES += "disk.img"
|
||||
IMAGE_FSTYPES += "disk.img wic"
|
||||
|
||||
WKS_FILE ?= "fvp-base.wks"
|
||||
|
||||
# Disk image configuration
|
||||
# We don't use the first partition
|
||||
|
||||
@@ -10,10 +10,10 @@ require conf/machine/include/arm/arch-armv8a.inc
|
||||
|
||||
MACHINE_FEATURES = "usbhost usbgadget alsa screen wifi bluetooth optee pci"
|
||||
|
||||
KERNEL_IMAGETYPE = "Image"
|
||||
KERNEL_IMAGETYPE = "Image.gz"
|
||||
KERNEL_DEVICETREE = "arm/juno.dtb arm/juno-r1.dtb arm/juno-r2.dtb"
|
||||
|
||||
IMAGE_FSTYPES += "tar.bz2 ext4"
|
||||
IMAGE_FSTYPES += "tar.bz2 ext4 cpio.gz"
|
||||
|
||||
SERIAL_CONSOLES = "115200;ttyAMA0"
|
||||
|
||||
@@ -28,3 +28,6 @@ EXTRA_IMAGEDEPENDS += "virtual/trusted-firmware-a u-boot firmware-image-juno"
|
||||
|
||||
# Juno u-boot configuration
|
||||
UBOOT_MACHINE = "vexpress_aemv8a_juno_defconfig"
|
||||
|
||||
INITRAMFS_IMAGE_BUNDLE ?= "1"
|
||||
INITRAMFS_IMAGE = "core-image-minimal"
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
# Armv8-R AArch64 AEM FVP Support in meta-arm-bsp
|
||||
Armv8-R AArch64 AEM FVP Support in meta-arm-bsp
|
||||
===============================================
|
||||
|
||||
Overview
|
||||
--------
|
||||
|
||||
## Overview
|
||||
Fixed Virtual Platforms (FVP) are complete simulations of an Arm system,
|
||||
including processor, memory and peripherals. These are set out in a
|
||||
"programmer's view", which gives you a comprehensive model on which to build
|
||||
@@ -16,34 +19,75 @@ https://developer.arm.com/ip-products/processors/cortex-r/cortex-r82
|
||||
Fast Models Fixed Virtual Platforms (FVP) Reference Guide:
|
||||
https://developer.arm.com/docs/100966/latest
|
||||
|
||||
## BSP Support
|
||||
|
||||
BSP Support
|
||||
-----------
|
||||
The fvp-baser-aemv8r64 Yocto MACHINE supports the following BSP components:
|
||||
|
||||
- boot-wrapper-aarch64
|
||||
- Kernel: linux-yocto-5.10
|
||||
|
||||
## Quick start: Howto Build and Run
|
||||
|
||||
Quick start: Howto Build and Run
|
||||
--------------------------------
|
||||
|
||||
### Host environment setup
|
||||
Install the Required Packages for the Build Host:
|
||||
https://www.yoctoproject.org/docs/latest/mega-manual/mega-manual.html#required-packages-for-the-build-host
|
||||
The following instructions have been tested on hosts running Ubuntu 18.04 and
|
||||
Ubuntu 20.04.
|
||||
|
||||
Install the required packages for the build host:
|
||||
https://docs.yoctoproject.org/3.3.1/singleindex.html#required-packages-for-the-build-host
|
||||
|
||||
Install the kas setup tool for bitbake based projects:
|
||||
https://kas.readthedocs.io/en/latest/userguide.html#dependencies-installation
|
||||
|
||||
pip3 install --user kas
|
||||
|
||||
For more details on kas, see https://kas.readthedocs.io/.
|
||||
|
||||
**Note:** The host machine should have at least 50 GBytes of free disk space
|
||||
for the next steps to work correctly.
|
||||
|
||||
### Fetch sources
|
||||
Fetch meta-arm repository:
|
||||
```
|
||||
mkdir -p ~/fvp-baser-aemv8r64-bsp
|
||||
cd ~/fvp-baser-aemv8r64-bsp
|
||||
git clone https://git.yoctoproject.org/git/meta-arm
|
||||
```
|
||||
Fetch the meta-arm repository into a build directory:
|
||||
|
||||
mkdir -p ~/fvp-baser-aemv8r64-build
|
||||
cd ~/fvp-baser-aemv8r64-build
|
||||
git clone https://git.yoctoproject.org/git/meta-arm
|
||||
|
||||
### Build
|
||||
```
|
||||
cd ~/fvp-baser-aemv8r64-bsp
|
||||
kas build meta-arm/kas/fvp-baser-aemv8r64-bsp.yml
|
||||
```
|
||||
Building with the standard Linux kernel:
|
||||
|
||||
cd ~/fvp-baser-aemv8r64-build
|
||||
kas build meta-arm/kas/fvp-baser-aemv8r64-bsp.yml
|
||||
|
||||
### Networking
|
||||
To enable networking on the FVP via a host network interface, you will need to
|
||||
install the following package(s):
|
||||
|
||||
**Ubuntu 18.04:**
|
||||
|
||||
sudo apt-get install libvirt-bin
|
||||
|
||||
**Ubuntu 20.04:**
|
||||
|
||||
sudo apt-get install libvirt-dev libvirt-daemon qemu-kvm libvirt-daemon-system libvirt-clients bridge-utils
|
||||
|
||||
Once that is installed for your OS version, setup tap0 using the following
|
||||
commands:
|
||||
|
||||
sudo virsh net-start default
|
||||
sudo ip tuntap add dev tap0 mode tap user $(whoami)
|
||||
sudo ifconfig tap0 0.0.0.0 promisc up
|
||||
sudo brctl addif virbr0 tap0
|
||||
|
||||
|
||||
To clean up the tap0 interface on the host use the following commands:
|
||||
|
||||
sudo brctl delif virbr0 tap0
|
||||
sudo ip link set virbr0 down
|
||||
sudo brctl delbr virbr0
|
||||
sudo virsh net-destroy default
|
||||
sudo ip link delete tap0
|
||||
|
||||
### Run
|
||||
To Run the Fixed Virtual Platform simulation tool you must download "Armv8-R
|
||||
@@ -53,71 +97,54 @@ https://developer.arm.com/tools-and-software/simulation-models/fixed-virtual-pla
|
||||
and install it on your host PC.
|
||||
|
||||
To run an image after the build is done:
|
||||
```
|
||||
export YOCTO_DEPLOY_IMGS_DIR="~/fvp-baser-aemv8r64-bsp/build/tmp/deploy/images/fvp-baser-aemv8r64/"
|
||||
cd <path-to-AEMv8R_base_pkg>/models/Linux64_GCC-6.4/
|
||||
./FVP_BaseR_AEMv8R \
|
||||
-C bp.dram_metadata.init_value=0 \
|
||||
-C bp.dram_metadata.is_enabled=true \
|
||||
-C bp.dram_size=8 \
|
||||
-C bp.exclusive_monitor.monitor_access_level=1 \
|
||||
-C bp.pl011_uart0.unbuffered_output=1 \
|
||||
-C bp.pl011_uart0.untimed_fifos=true \
|
||||
-C bp.refcounter.non_arch_start_at_default=1 \
|
||||
-C bp.smsc_91c111.enabled=0 \
|
||||
-C bp.ve_sysregs.mmbSiteDefault=0 \
|
||||
-C cache_state_modelled=true \
|
||||
-C cluster0.gicv3.cpuintf-mmap-access-level=2 \
|
||||
-C cluster0.gicv3.SRE-enable-action-on-mmap=2 \
|
||||
-C cluster0.gicv3.SRE-EL2-enable-RAO=1 \
|
||||
-C cluster0.gicv3.extended-interrupt-range-support=1 \
|
||||
-C cluster0.has_aarch64=1 \
|
||||
-C cluster0.NUM_CORES=4 \
|
||||
-C cluster0.stage12_tlb_size=512 \
|
||||
-C gic_distributor.GICD_CTLR-DS-1-means-secure-only=1 \
|
||||
-C gic_distributor.GITS_BASER0-type=1 \
|
||||
-C gic_distributor.ITS-count=1 \
|
||||
-C gic_distributor.ITS-hardware-collection-count=1 \
|
||||
-C gic_distributor.direct-lpi-support=1 \
|
||||
-C gic_distributor.has-two-security-states=0 \
|
||||
-C pctl.startup=0.0.0.* \
|
||||
-C bp.virtio_net.enabled=1 \
|
||||
-C cache_state_modelled=0 \
|
||||
-C bp.vis.rate_limit-enable=0 \
|
||||
-C bp.virtio_net.hostbridge.interfaceName=tap0 \
|
||||
-a cluster0*=${YOCTO_DEPLOY_IMGS_DIR}/linux-system.axf \
|
||||
-C bp.virtioblockdevice.image_path=${YOCTO_DEPLOY_IMGS_DIR}/core-image-minimal-fvp-baser-aemv8r64.wic
|
||||
```
|
||||
|
||||
The terminal console login is `root` without password.
|
||||
export YOCTO_DEPLOY_IMGS_DIR="~/fvp-baser-aemv8r64-bsp/build/tmp/deploy/images/fvp-baser-aemv8r64/"
|
||||
cd <path-to-AEMv8R_base_pkg>/models/Linux64_GCC-6.4/
|
||||
./FVP_BaseR_AEMv8R \
|
||||
-C bp.dram_metadata.init_value=0 \
|
||||
-C bp.dram_metadata.is_enabled=true \
|
||||
-C bp.dram_size=8 \
|
||||
-C bp.exclusive_monitor.monitor_access_level=1 \
|
||||
-C bp.pl011_uart0.unbuffered_output=1 \
|
||||
-C bp.pl011_uart0.untimed_fifos=true \
|
||||
-C bp.refcounter.non_arch_start_at_default=1 \
|
||||
-C bp.smsc_91c111.enabled=0 \
|
||||
-C bp.ve_sysregs.mmbSiteDefault=0 \
|
||||
-C cache_state_modelled=true \
|
||||
-C cluster0.gicv3.cpuintf-mmap-access-level=2 \
|
||||
-C cluster0.gicv3.SRE-enable-action-on-mmap=2 \
|
||||
-C cluster0.gicv3.SRE-EL2-enable-RAO=1 \
|
||||
-C cluster0.gicv3.extended-interrupt-range-support=1 \
|
||||
-C cluster0.has_aarch64=1 \
|
||||
-C cluster0.NUM_CORES=4 \
|
||||
-C cluster0.stage12_tlb_size=512 \
|
||||
-C gic_distributor.GICD_CTLR-DS-1-means-secure-only=1 \
|
||||
-C gic_distributor.GITS_BASER0-type=1 \
|
||||
-C gic_distributor.ITS-count=1 \
|
||||
-C gic_distributor.ITS-hardware-collection-count=1 \
|
||||
-C gic_distributor.has-two-security-states=0 \
|
||||
-C pctl.startup=0.0.0.* \
|
||||
-C bp.virtio_net.enabled=1 \
|
||||
-C cache_state_modelled=0 \
|
||||
-C bp.vis.rate_limit-enable=0 \
|
||||
-C bp.virtio_net.hostbridge.interfaceName=tap0 \
|
||||
-a cluster0*=${YOCTO_DEPLOY_IMGS_DIR}/linux-system.axf \
|
||||
-C bp.virtioblockdevice.image_path=${YOCTO_DEPLOY_IMGS_DIR}/core-image-minimal-fvp-baser-aemv8r64.wic
|
||||
|
||||
**Note:** The terminal console login is `root` without password.
|
||||
|
||||
|
||||
Devices supported in the kernel
|
||||
-------------------------------
|
||||
|
||||
## Devices supported in the kernel
|
||||
- serial
|
||||
- virtio disk
|
||||
- virtio network
|
||||
- watchdog
|
||||
- rtc
|
||||
|
||||
## Devices not supported or not functional
|
||||
|
||||
Devices not supported or not functional
|
||||
---------------------------------------
|
||||
|
||||
- Only one CPU since SMP is not functional in boot-wrapper-aarch64 yet
|
||||
|
||||
## Networking
|
||||
|
||||
To enable networking on the FVP via a host network interface, set up tap0 using
|
||||
the following commands (Ubuntu 18.04 Host):
|
||||
```
|
||||
sudo apt-get install libvirt-bin
|
||||
sudo virsh net-start default
|
||||
sudo ip tuntap add dev tap0 mode tap user $(whoami)
|
||||
sudo ifconfig tap0 0.0.0.0 promisc up
|
||||
sudo brctl addif virbr0 tap0
|
||||
```
|
||||
|
||||
To clean up the tap0 interface on the host use the following commands:
|
||||
```
|
||||
sudo brctl delif virbr0 tap0
|
||||
sudo ip link set virbr0 down
|
||||
sudo brctl delbr virbr0
|
||||
sudo virsh net-destroy default
|
||||
sudo ip link delete tap0
|
||||
```
|
||||
|
||||
@@ -62,7 +62,7 @@ do_deploy() {
|
||||
done
|
||||
|
||||
if [ "${INITRAMFS_IMAGE_BUNDLE}" -eq 1 ]; then
|
||||
cp -L -f ${DEPLOY_DIR_IMAGE}/Image-initramfs-juno.bin \
|
||||
cp -L -f ${DEPLOY_DIR_IMAGE}/Image.gz-initramfs-juno.bin \
|
||||
${D}/${UNPACK_DIR}/SOFTWARE/Image
|
||||
else
|
||||
cp -L -f ${DEPLOY_DIR_IMAGE}/Image ${D}/${UNPACK_DIR}/SOFTWARE/
|
||||
|
||||
@@ -6,6 +6,8 @@ SUMMARY = "Total Compute Images"
|
||||
DESCRIPTION = "Build all the images required for Total Compute platform"
|
||||
LICENSE = "Apache-2.0"
|
||||
|
||||
COMPATIBLE_MACHINE = "tc0"
|
||||
|
||||
inherit nopackages
|
||||
|
||||
# The last image to be built is trusted-firmware-a
|
||||
|
||||
+27
@@ -0,0 +1,27 @@
|
||||
From 097a43223da4fa42335944295903ede2755e2dfd Mon Sep 17 00:00:00 2001
|
||||
From: Jon Mason <jdmason@kudzu.us>
|
||||
Date: Mon, 19 Dec 2022 11:36:04 -0500
|
||||
Subject: [PATCH] configs: vexpress: modify to boot compressed initramfs
|
||||
|
||||
Signed-off-by: Jon Mason <jdmason@kudzu.us>
|
||||
Upstream-Status: Inappropriate
|
||||
---
|
||||
include/configs/vexpress_aemv8a.h | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/include/configs/vexpress_aemv8.h b/include/configs/vexpress_aemv8a.h
|
||||
index cd7f6c1b9ba0..c2f5eb302076 100644
|
||||
--- a/include/configs/vexpress_aemv8a.h
|
||||
+++ b/include/configs/vexpress_aemv8a.h
|
||||
@@ -164,6 +164,8 @@
|
||||
"kernel_name=norkern\0" \
|
||||
"kernel_alt_name=Image\0" \
|
||||
"kernel_addr_r=0x80080000\0" \
|
||||
+ "kernel_comp_addr_r=0x90000000\0" \
|
||||
+ "kernel_comp_size=0x3000000\0" \
|
||||
"initrd_name=ramdisk.img\0" \
|
||||
"initrd_addr_r=0x88000000\0" \
|
||||
"fdtfile=board.dtb\0" \
|
||||
--
|
||||
2.30.2
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
CONFIG_BOOTARGS="console=ttyAMA0 earlycon=pl011,0x1c090000 root=/dev/vda2 rw rootwait"
|
||||
@@ -1,17 +0,0 @@
|
||||
Upstream-Status: Inappropriate [OE config specific]
|
||||
Signed-off-by: Anders Dellien <anders.dellien@arm.com>
|
||||
|
||||
diff --git a/configs/vexpress_aemv8a_semi_defconfig b/configs/vexpress_aemv8a_semi_defconfig
|
||||
index f0ac2f9da3..93fcd3026a 100644
|
||||
--- a/configs/vexpress_aemv8a_semi_defconfig
|
||||
+++ b/configs/vexpress_aemv8a_semi_defconfig
|
||||
@@ -10,7 +10,7 @@ CONFIG_DISTRO_DEFAULTS=y
|
||||
CONFIG_ANDROID_BOOT_IMAGE=y
|
||||
CONFIG_BOOTDELAY=1
|
||||
CONFIG_USE_BOOTARGS=y
|
||||
-CONFIG_BOOTARGS="console=ttyAMA0 earlycon=pl011,0x1c090000 debug user_debug=31 loglevel=9"
|
||||
+CONFIG_BOOTARGS="console=ttyAMA0 earlycon=pl011,0x1c090000 debug user_debug=31 androidboot.hardware=fvpbase root=/dev/vda2 rw rootwait loglevel=9"
|
||||
# CONFIG_USE_BOOTCOMMAND is not set
|
||||
# CONFIG_DISPLAY_CPUINFO is not set
|
||||
# CONFIG_DISPLAY_BOARDINFO is not set
|
||||
|
||||
@@ -13,4 +13,7 @@ SRC_URI_append_corstone500 = " \
|
||||
#
|
||||
# Juno KMACHINE
|
||||
#
|
||||
SRC_URI_append_juno = " file://u-boot_vexpress_uenv.patch"
|
||||
SRC_URI_append_juno = " \
|
||||
file://u-boot_vexpress_uenv.patch \
|
||||
file://0002-configs-vexpress-modify-to-boot-compressed-initramfs.patch \
|
||||
"
|
||||
|
||||
@@ -5,7 +5,7 @@ FILESEXTRAPATHS_prepend := "${THISDIR}/${BP}:"
|
||||
#
|
||||
# FVP BASE
|
||||
#
|
||||
SRC_URI_append_fvp-base = " file://u-boot_vexpress_fvp.patch \
|
||||
SRC_URI_append_fvp-base = " file://bootargs.cfg \
|
||||
file://0001-vexpress64_fvp-Set-DRAM-to-4G-to-match-with-kernel-d.patch \
|
||||
"
|
||||
|
||||
|
||||
+54
@@ -0,0 +1,54 @@
|
||||
Upstream-Status: Backport
|
||||
Signed-off-by: Jon Mason <jon.mason@arm.com>
|
||||
|
||||
From e33a814e772cdc36436c8c188d8c42d019fda639 Mon Sep 17 00:00:00 2001
|
||||
From: Dirk Mueller <dmueller@suse.com>
|
||||
Date: Tue, 14 Jan 2020 18:53:41 +0100
|
||||
Subject: [PATCH] scripts/dtc: Remove redundant YYLOC global declaration
|
||||
|
||||
gcc 10 will default to -fno-common, which causes this error at link
|
||||
time:
|
||||
|
||||
(.text+0x0): multiple definition of `yylloc'; dtc-lexer.lex.o (symbol from plugin):(.text+0x0): first defined here
|
||||
|
||||
This is because both dtc-lexer as well as dtc-parser define the same
|
||||
global symbol yyloc. Before with -fcommon those were merged into one
|
||||
defintion. The proper solution would be to to mark this as "extern",
|
||||
however that leads to:
|
||||
|
||||
dtc-lexer.l:26:16: error: redundant redeclaration of 'yylloc' [-Werror=redundant-decls]
|
||||
26 | extern YYLTYPE yylloc;
|
||||
| ^~~~~~
|
||||
In file included from dtc-lexer.l:24:
|
||||
dtc-parser.tab.h:127:16: note: previous declaration of 'yylloc' was here
|
||||
127 | extern YYLTYPE yylloc;
|
||||
| ^~~~~~
|
||||
cc1: all warnings being treated as errors
|
||||
|
||||
which means the declaration is completely redundant and can just be
|
||||
dropped.
|
||||
|
||||
Signed-off-by: Dirk Mueller <dmueller@suse.com>
|
||||
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
|
||||
[robh: cherry-pick from upstream]
|
||||
Cc: stable@vger.kernel.org
|
||||
Signed-off-by: Rob Herring <robh@kernel.org>
|
||||
---
|
||||
scripts/dtc/dtc-lexer.l | 1 -
|
||||
1 file changed, 1 deletion(-)
|
||||
|
||||
diff --git a/scripts/dtc/dtc-lexer.l b/scripts/dtc/dtc-lexer.l
|
||||
index 5c6c3fd557d7..b3b7270300de 100644
|
||||
--- a/scripts/dtc/dtc-lexer.l
|
||||
+++ b/scripts/dtc/dtc-lexer.l
|
||||
@@ -23,7 +23,6 @@ LINECOMMENT "//".*\n
|
||||
#include "srcpos.h"
|
||||
#include "dtc-parser.tab.h"
|
||||
|
||||
-YYLTYPE yylloc;
|
||||
extern bool treesource_error;
|
||||
|
||||
/* CAUTION: this will stop working if we ever use yyless() or yyunput() */
|
||||
--
|
||||
2.30.2
|
||||
|
||||
@@ -5,7 +5,11 @@
|
||||
# in this file. Update SRC_URI and do_patch for building images with custom dts
|
||||
#
|
||||
|
||||
FILESEXTRAPATHS_prepend := "${THISDIR}:${THISDIR}/files:"
|
||||
# We can't set FILESEXTRAPATHS once because of how the kernel classes search for
|
||||
# config fragments. Discussion is ongoing as to whether this is the correct
|
||||
# solution, or a workaround.
|
||||
# https://bugzilla.yoctoproject.org/show_bug.cgi?id=14154
|
||||
ARMBSPFILESPATHS := "${THISDIR}:${THISDIR}/files:"
|
||||
|
||||
# Arm platforms kmeta
|
||||
SRC_URI_KMETA = "file://arm-platforms-kmeta;type=kmeta;name=arm-platforms-kmeta;destsuffix=arm-platforms-kmeta"
|
||||
@@ -26,6 +30,7 @@ COMPATIBLE_MACHINE_corstone500 = "corstone500"
|
||||
#
|
||||
COMPATIBLE_MACHINE_fvp-base = "fvp-base"
|
||||
KMACHINE_fvp-base = "fvp"
|
||||
FILESEXTRAPATHS_prepend_fvp-base := "${ARMBSPFILESPATHS}"
|
||||
SRC_URI_append_fvp-base = " file://fvp-base-dts.patch"
|
||||
|
||||
#
|
||||
@@ -33,6 +38,7 @@ SRC_URI_append_fvp-base = " file://fvp-base-dts.patch"
|
||||
#
|
||||
COMPATIBLE_MACHINE_fvp-base-arm32 = "fvp-base-arm32"
|
||||
KMACHINE_fvp-base-arm32 = "fvp-arm32"
|
||||
FILESEXTRAPATHS_prepend_fvp-base-arm32 := "${ARMBSPFILESPATHS}"
|
||||
SRC_URI_append_fvp-base-arm32 = " file://fvp-base-arm32-dts.patch \
|
||||
file://0001-ARM-vexpress-enable-GICv3.patch"
|
||||
|
||||
@@ -43,6 +49,11 @@ COMPATIBLE_MACHINE_juno = "juno"
|
||||
KMACHINE_juno = "juno"
|
||||
KBUILD_DEFCONFIG_juno = "defconfig"
|
||||
KCONFIG_MODE_juno = "--alldefconfig"
|
||||
#FIXME - temporarily pin kernel version to allow for juno patches to apply
|
||||
KBRANCH_juno = "v5.4/standard/base"
|
||||
KERNEL_VERSION_SANITY_SKIP_juno = "1"
|
||||
SRCREV_machine_juno = "dd8a64a523fb714a98328441e0de72cde115a6fc"
|
||||
FILESEXTRAPATHS_prepend_juno := "${ARMBSPFILESPATHS}"
|
||||
SRC_URI_append_juno = " \
|
||||
file://0001-mailbox-add-support-for-doorbell-signal-mode-control.patch \
|
||||
file://0002-dt-bindings-mailbox-add-bindings-to-support-ARM-MHU-.patch \
|
||||
@@ -68,6 +79,7 @@ KCONFIG_MODE_sgi575 = "--alldefconfig"
|
||||
COMPATIBLE_MACHINE_tc0 = "tc0"
|
||||
KMACHINE_tc0 = "tc0"
|
||||
KCONFIG_MODE_tc0 = "--alldefconfig"
|
||||
FILESEXTRAPATHS_prepend_tc0 := "${ARMBSPFILESPATHS}"
|
||||
SRC_URI_append_tc0 = " \
|
||||
file://defconfig \
|
||||
file://0001-drm-Add-component-aware-simple-encoder.patch \
|
||||
@@ -94,12 +106,12 @@ FILESEXTRAPATHS_prepend_n1sdp := "${THISDIR}/linux-yocto-5.10/n1sdp:"
|
||||
COMPATIBLE_MACHINE_n1sdp = "n1sdp"
|
||||
KBUILD_DEFCONFIG_n1sdp = "defconfig"
|
||||
KCONFIG_MODE_n1sdp = "--alldefconfig"
|
||||
FILESEXTRAPATHS_prepend_n1sdp := "${ARMBSPFILESPATHS}"
|
||||
SRC_URI_append_n1sdp = " \
|
||||
file://0001-pci_quirk-add-acs-override-for-PCI-devices.patch \
|
||||
file://0002-pcie-Add-quirk-for-the-Arm-Neoverse-N1SDP-platform.patch \
|
||||
file://0003-n1sdp-update-n1sdp-pci-quirk-for-SR-IOV-support.patch \
|
||||
file://0004-n1sdp-pcie-add-quirk-support-enabling-remote-chip-PC.patch \
|
||||
file://0005-r8169-Fix-to-avoid-duplicate-sysfs-entry-creation-er.patch \
|
||||
file://0001-arm64-defconfig-drop-unused-BACKLIGHT_GENERIC-option.patch \
|
||||
file://no-power-avs.patch \
|
||||
file://enable-realtek-R8169.cfg \
|
||||
@@ -119,4 +131,5 @@ COMPATIBLE_MACHINE_musca-s1 = "(^$)"
|
||||
# FVP BaseR AEMv8r64 Machine
|
||||
#
|
||||
COMPATIBLE_MACHINE_fvp-baser-aemv8r64 = "fvp-baser-aemv8r64"
|
||||
FILESEXTRAPATHS_prepend_fvp-baser-aemv8r64 := "${ARMBSPFILESPATHS}"
|
||||
SRC_URI_append_fvp-baser-aemv8r64 = " file://fvp-baser-aemv8r64.dts;subdir=git/arch/arm64/boot/dts/arm"
|
||||
|
||||
-45
@@ -1,45 +0,0 @@
|
||||
From 914fe7871fc2f00ec94cd4d17722158e94fa88df Mon Sep 17 00:00:00 2001
|
||||
From: Khasim Mohammed <khasim.mohammed@arm.com>
|
||||
Date: Fri, 8 Jan 2021 04:21:23 +0000
|
||||
Subject: [PATCH] r8169: Fix to avoid duplicate sysfs entry creation error
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Upstream-Status: Pending [yet to submit]
|
||||
|
||||
Signed-off-by: Khasim Syed Mohammed <khasim.mohammed@arm.com>
|
||||
|
||||
Patch taken from :
|
||||
https://git.linaro.org/landing-teams/working/arm/kernel-release.git/commit/?h=n1sdp&id=84baaae9e751c058717d9702438429257f077f03
|
||||
|
||||
Following error observed with r8169 driver, this patch fix the issue.
|
||||
|
||||
[ 27.544136] r8169 0002:07:00.0: enabling device (0000 -> 0003)
|
||||
[ 27.559734] sysfs: cannot create duplicate filename '/class/mdio_bus/r8169-700'
|
||||
…
|
||||
[ 27.684858] libphy: mii_bus r8169-700 failed to register
|
||||
[ 27.695602] r8169: probe of 0002:07:00.0 failed with error -22
|
||||
|
||||
Change-Id: Id696abbabd794ecef5c551c5c45630963d9502a6
|
||||
Signed-off-by: Sayanta Pattanayak <sayanta.pattanayak@arm.com>
|
||||
---
|
||||
drivers/net/ethernet/realtek/r8169_main.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/drivers/net/ethernet/realtek/r8169_main.c b/drivers/net/ethernet/realtek/r8169_main.c
|
||||
index 85d9c3e30c69..6d6b24978fd5 100644
|
||||
--- a/drivers/net/ethernet/realtek/r8169_main.c
|
||||
+++ b/drivers/net/ethernet/realtek/r8169_main.c
|
||||
@@ -5088,7 +5088,7 @@ static int r8169_mdio_register(struct rtl8169_private *tp)
|
||||
new_bus->priv = tp;
|
||||
new_bus->parent = &pdev->dev;
|
||||
new_bus->irq[0] = PHY_IGNORE_INTERRUPT;
|
||||
- snprintf(new_bus->id, MII_BUS_ID_SIZE, "r8169-%x", pci_dev_id(pdev));
|
||||
+ snprintf(new_bus->id, MII_BUS_ID_SIZE, "r8169-%x-%x", pdev->bus->domain_nr, pci_dev_id(pdev));
|
||||
|
||||
new_bus->read = r8169_mdio_read_reg;
|
||||
new_bus->write = r8169_mdio_write_reg;
|
||||
--
|
||||
2.17.1
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
FILESEXTRAPATHS_prepend := "${THISDIR}/files/corstone700:"
|
||||
FILESEXTRAPATHS_prepend := "${THISDIR}:${THISDIR}/files:"
|
||||
|
||||
COMPATIBLE_MACHINE = "${MACHINE}"
|
||||
|
||||
|
||||
@@ -6,7 +6,9 @@ SRCREV_machine = "d4f3318ed8fab6316cb7a269b8f42306632a3876"
|
||||
SRCREV_meta = "8d0ed83a864cc91eef4d2abbc90f13d4ecd1c213"
|
||||
|
||||
SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;name=machine;branch=${KBRANCH}; \
|
||||
git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-5.4;destsuffix=${KMETA}"
|
||||
git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-5.4;destsuffix=${KMETA} \
|
||||
file://0001-scripts-dtc-Remove-redundant-YYLOC-global-declaratio.patch \
|
||||
"
|
||||
|
||||
LINUX_VERSION = "5.3.18"
|
||||
LIC_FILES_CHKSUM = "file://COPYING;md5=bbea815ee2795b2f4230826c0c6b8814"
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
# For fvp-base* machines we just need to populate the rootfs partition
|
||||
# but to keep backwards compatibility with disk.img,
|
||||
# we need to create first partition empty
|
||||
|
||||
part --label empty --source empty --ondisk sda --size="1M" --system-id 8e --align 1024
|
||||
part / --source rootfs --ondisk sda --fstype=ext4 --label root --size="2048"
|
||||
@@ -4,15 +4,15 @@ set default="0"
|
||||
set timeout="5"
|
||||
|
||||
menuentry 'Arm reference image boot on N1SDP (ACPI)' {
|
||||
linux /Image earlycon=pl011,0x2A400000 console=ttyAMA0,115200 root=PARTUUID=6a60524d-061d-454a-bfd1-38989910eccd rootwait rootfstype=ext4 acpi=force verbose debug
|
||||
linux /Image earlycon=pl011,0x2A400000 console=ttyAMA0,115200 root=PARTUUID=6a60524d-061d-454a-bfd1-38989910eccd rootwait rootfstype=ext4 acpi=force
|
||||
}
|
||||
|
||||
menuentry 'Arm reference image boot on Single-Chip N1SDP (Device Tree)' {
|
||||
devicetree /n1sdp-single-chip.dtb
|
||||
linux /Image earlycon=pl011,0x2A400000 console=ttyAMA0,115200 root=PARTUUID=6a60524d-061d-454a-bfd1-38989910eccd rootwait rootfstype=ext4 verbose debug
|
||||
linux /Image earlycon=pl011,0x2A400000 console=ttyAMA0,115200 root=PARTUUID=6a60524d-061d-454a-bfd1-38989910eccd rootwait rootfstype=ext4
|
||||
}
|
||||
|
||||
menuentry 'Arm reference image boot on Multi-Chip N1SDP (Device Tree)' {
|
||||
devicetree /n1sdp-multi-chip.dtb
|
||||
linux /Image earlycon=pl011,0x2A400000 console=ttyAMA0,115200 root=PARTUUID=6a60524d-061d-454a-bfd1-38989910eccd rootwait rootfstype=ext4 verbose debug
|
||||
linux /Image earlycon=pl011,0x2A400000 console=ttyAMA0,115200 root=PARTUUID=6a60524d-061d-454a-bfd1-38989910eccd rootwait rootfstype=ext4
|
||||
}
|
||||
|
||||
@@ -139,19 +139,5 @@ python external_arm_toolchain_version_handler () {
|
||||
d.setVar('EAT_VER_KERNEL', eat_get_kernel_version(ld))
|
||||
d.setVar('EAT_VER_GDB', eat_get_gdb_version(ld))
|
||||
d.setVar('EAT_VER_BFD', eat_get_bfd_version(ld))
|
||||
|
||||
lc_libc = "LGPL-2.1"
|
||||
lc_gcc = "GPL-3.0"
|
||||
lc_rle = "GPL-3.0-with-GCC-exception"
|
||||
lc_gdb = "GPL-3.0"
|
||||
lc_bfd = "GPL-3.0"
|
||||
|
||||
d.setVar('EAT_LIBC_LICENSE', lc_libc)
|
||||
d.setVar('EAT_GCC_LICENSE', lc_gcc)
|
||||
d.setVar('EAT_RLE_LICENSE', lc_rle)
|
||||
d.setVar('EAT_GDB_LICENSE', lc_gdb)
|
||||
d.setVar('EAT_BFD_LICENSE', lc_bfd)
|
||||
|
||||
d.setVar('EAT_LICENSE', "%s & %s & %s & %s & %s" % (lc_libc, lc_gcc, lc_rle, lc_gdb, lc_bfd))
|
||||
}
|
||||
addhandler external_arm_toolchain_version_handler
|
||||
|
||||
@@ -14,8 +14,5 @@ LICENSE_PATH += "${LAYERDIR}/custom-licenses"
|
||||
LAYERDEPENDS_arm-toolchain = "core"
|
||||
LAYERSERIES_COMPAT_arm-toolchain = "hardknott"
|
||||
|
||||
# do not error out on bbappends for missing recipes
|
||||
BB_DANGLINGAPPENDS_WARNONLY = "true"
|
||||
|
||||
# These variables are used for armcompiler license
|
||||
BB_HASHBASE_WHITELIST_append = " ARM_TOOL_VARIANT ARMLMD_LICENSE_FILE LM_LICENSE_FILE"
|
||||
|
||||
+2
-3
@@ -1,5 +1,7 @@
|
||||
inherit cross-canadian
|
||||
|
||||
require license.inc
|
||||
|
||||
PN = "external-arm-sdk-toolchain-${TARGET_ARCH}"
|
||||
BPN = "external-arm-sdk-toolchain"
|
||||
PV = "${EAT_VER_MAIN}"
|
||||
@@ -10,9 +12,6 @@ INHIBIT_SYSROOT_STRIP = "1"
|
||||
INHIBIT_DEFAULT_DEPS = "1"
|
||||
EXCLUDE_FROM_SHLIBS = "1"
|
||||
|
||||
EAT_LICENSE ??= ""
|
||||
|
||||
LICENSE = "${EAT_LICENSE}"
|
||||
LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302"
|
||||
|
||||
# Skip packaging QA checks for prebuilt binaries
|
||||
|
||||
@@ -1,7 +1,10 @@
|
||||
LICENSE = "GPL-3.0-with-GCC-exception & GPLv3 & GPLv2 & LGPLv3 & LGPLv2.1 & LGPLv2"
|
||||
|
||||
EAT_BFD_LICENSE = "GPL-3.0"
|
||||
EAT_GCC_LICENSE = "GPL-3.0-with-GCC-exception & GPLv3"
|
||||
EAT_GDB_LICENSE = "GPL-3.0"
|
||||
EAT_LIBC_LICENSE = "GPLv2 & LGPLv2.1"
|
||||
EAT_RLE_LICENSE = "GPL-3.0-with-GCC-exception"
|
||||
|
||||
LICENSE_${PN} = "${EAT_LIBC_LICENSE}"
|
||||
LICENSE_${PN}-dev = "${EAT_LIBC_LICENSE}"
|
||||
|
||||
@@ -0,0 +1,80 @@
|
||||
# Image class to write .fvpconf files for use with runfvp. If this is desired
|
||||
# then add fvpboot to IMAGE_CLASSES, and set the variables below in your machine
|
||||
# configuration as appropriate.
|
||||
|
||||
# Name of recipe providing FVP executable. If unset then the executable must be installed on the host.
|
||||
FVP_PROVIDER ?= ""
|
||||
# Name of FVP executable to run
|
||||
FVP_EXE ?= ""
|
||||
# Flags for --parameter/-C
|
||||
FVP_CONFIG ?= ""
|
||||
# Flags for --data
|
||||
FVP_DATA ?= ""
|
||||
# Flags for --application
|
||||
FVP_APPLICATIONS ?= ""
|
||||
# Flags to name serial terminals. Flag name is the terminal id (such as
|
||||
# terminal_0), value is a human-readable name. If the name is not set
|
||||
# then runfvp will hide the terminal.
|
||||
FVP_TERMINALS ?= ""
|
||||
# What terminal should be considered the primary console
|
||||
FVP_CONSOLE ?= ""
|
||||
# Arbitrary extra arguments
|
||||
FVP_EXTRA_ARGS ?= ""
|
||||
|
||||
EXTRA_IMAGEDEPENDS += "${FVP_PROVIDER}"
|
||||
|
||||
inherit image-artifact-names
|
||||
|
||||
addtask do_write_fvpboot_conf after do_rootfs before do_image
|
||||
python do_write_fvpboot_conf() {
|
||||
# Note that currently this JSON file is in development and the format may
|
||||
# change at any point, so it should always be used with a matching runfvp.
|
||||
|
||||
import json, shlex
|
||||
|
||||
if not d.getVar("FVP_EXE"):
|
||||
return
|
||||
|
||||
conffile = os.path.join(d.getVar("IMGDEPLOYDIR"), d.getVar("IMAGE_NAME") + ".fvpconf")
|
||||
conffile_link = os.path.join(d.getVar("IMGDEPLOYDIR"), d.getVar("IMAGE_LINK_NAME") + ".fvpconf")
|
||||
|
||||
data = {}
|
||||
provider = d.getVar("FVP_PROVIDER")
|
||||
if provider:
|
||||
data["provider"] = provider
|
||||
data["fvp-bindir"] = os.path.join(d.getVar("COMPONENTS_DIR"),
|
||||
d.getVar("BUILD_ARCH"),
|
||||
provider,
|
||||
"usr", "bin")
|
||||
|
||||
def getFlags(varname):
|
||||
flags = d.getVarFlags(varname)
|
||||
# For unexplained reasons, getVarFlags() returns None if there are no flags
|
||||
if flags is None:
|
||||
return {}
|
||||
# For other reasons, you can't pass expand=True
|
||||
return {key: d.expand(value) for key, value in flags.items()}
|
||||
|
||||
data["exe"] = d.getVar("FVP_EXE")
|
||||
data["parameters"] = getFlags("FVP_CONFIG")
|
||||
data["data"] = shlex.split(d.getVar("FVP_DATA") or "")
|
||||
data["applications"] = getFlags("FVP_APPLICATIONS")
|
||||
data["console"] = d.getVar("FVP_CONSOLE")
|
||||
data["terminals"] = getFlags("FVP_TERMINALS")
|
||||
data["args"] = shlex.split(d.getVar("FVP_EXTRA_ARGS") or "")
|
||||
|
||||
os.makedirs(os.path.dirname(conffile), exist_ok=True)
|
||||
with open(conffile, "wt") as f:
|
||||
json.dump(data, f)
|
||||
|
||||
if conffile_link != conffile:
|
||||
if os.path.lexists(conffile_link):
|
||||
os.remove(conffile_link)
|
||||
os.symlink(os.path.basename(conffile), conffile_link)
|
||||
}
|
||||
|
||||
def fvpboot_vars(d):
|
||||
build_vars = ['DEPLOY_DIR_IMAGE', 'IMAGE_NAME', 'IMAGE_LINK_NAME',
|
||||
'COMPONENTS_DIR', 'BUILD_ARCH']
|
||||
return build_vars + [k for k in d.keys() if k.startswith('FVP_')]
|
||||
do_write_fvpboot_conf[vardeps] += "${@' '.join(fvpboot_vars(d))}"
|
||||
@@ -1,23 +1,24 @@
|
||||
#@TYPE: Machine
|
||||
#@NAME: generic-arm64
|
||||
#@DESCRIPTION: Generic Arm64 machine for creating rootfs that should work on all arm64 hardware
|
||||
#@DESCRIPTION: Generic Arm64 machine for typical SystemReady platforms, which
|
||||
#have working firmware and boot via EFI.
|
||||
|
||||
require conf/machine/include/arm/arch-armv8a.inc
|
||||
|
||||
SERIAL_CONSOLES ?= "115200;ttyAMA0"
|
||||
SERIAL_CONSOLES_CHECK = "${SERIAL_CONSOLES}"
|
||||
|
||||
PREFERRED_PROVIDER_virtual/kernel ?= "linux-yocto"
|
||||
PREFERRED_VERSION_linux-yocto ?= "5.10%"
|
||||
|
||||
KERNEL_IMAGETYPE = "Image"
|
||||
|
||||
IMAGE_BOOT_FILES = "${KERNEL_IMAGETYPE}"
|
||||
IMAGE_FSTYPES ?= "wic"
|
||||
|
||||
WKS_FILE ?= "mkefidisk.wks"
|
||||
WKS_FILE ?= "efi-disk.wks.in"
|
||||
|
||||
MACHINE_FEATURES += "efi"
|
||||
MACHINE_FEATURES += "alsa bluetooth efi qemu-usermode rtc screen usbhost vfat wifi"
|
||||
|
||||
EFI_PROVIDER ?= "${@bb.utils.contains("DISTRO_FEATURES", "systemd", "systemd-boot", "grub-efi", d)}"
|
||||
|
||||
KBUILD_DEFCONFIG = "defconfig"
|
||||
KCONFIG_MODE = "--alldefconfig"
|
||||
|
||||
MACHINE_EXTRA_RRECOMMENDS += "kernel-modules linux-firmware"
|
||||
|
||||
@@ -56,8 +56,7 @@ LIC_FILES_CHKSUM_append = "${@bb.utils.contains('TFA_MBEDTLS', '1', ' ${LIC_FILE
|
||||
SRCREV_FORMAT_append = "${@bb.utils.contains('TFA_MBEDTLS', '1', '_mbedtls', '', d)}"
|
||||
|
||||
SRC_URI_append = " \
|
||||
file://0002-pmf.h-made-PMF_STOTE_ENABLE-pass-Wtautological.patch \
|
||||
file://0003-xlat-tables-v2-remove-tautological-assert.patch \
|
||||
file://0002-pmf.h-made-PMF_STOTE_ENABLE-pass-Wtautological.patch \
|
||||
"
|
||||
|
||||
# U-boot support (set TFA_UBOOT to 1 to activate)
|
||||
|
||||
@@ -13,3 +13,5 @@ SRC_URI_MBEDTLS = "git://github.com/ARMmbed/mbedtls.git;name=mbedtls;protocol=ht
|
||||
SRCREV_mbedtls = "523f0554b6cdc7ace5d360885c3f5bbcc73ec0e8"
|
||||
|
||||
LIC_FILES_CHKSUM_MBEDTLS = "file://mbedtls/LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57"
|
||||
|
||||
SRC_URI_append = " file://0003-xlat-tables-v2-remove-tautological-assert.patch"
|
||||
|
||||
@@ -0,0 +1,26 @@
|
||||
require fvp-common.inc
|
||||
|
||||
SUMMARY = "Arm Fixed Virtual Platform - Armv-A Base RevC Architecture Envelope Model FVP"
|
||||
HOMEPAGE = "https://developer.arm.com/tools-and-software/simulation-models/fixed-virtual-platforms/arm-ecosystem-models"
|
||||
LIC_FILES_CHKSUM = "file://license_terms/license_agreement.txt;md5=1a33828e132ba71861c11688dbb0bd16 \
|
||||
file://license_terms/third_party_licenses.txt;md5=b40ecbbbd3409d48263437b782df6df9"
|
||||
|
||||
# This FVP cannot be downloaded directly, so download the Armv-A Base RevC AEM
|
||||
# FVP yourself from the homepage and set FVP_BASE_A_AEM_TARBALL_URI appropriately
|
||||
# (for example, file:///home/user/FVP_Base_RevC-2xAEMvA_11.14_21.tgz).
|
||||
FVP_BASE_A_AEM_TARBALL_URI ?= ""
|
||||
PV = "11.14_21"
|
||||
|
||||
SRC_URI = "${FVP_BASE_A_AEM_TARBALL_URI};subdir=${BP}"
|
||||
python() {
|
||||
if not d.getVar("FVP_BASE_A_AEM_TARBALL_URI"):
|
||||
raise bb.parse.SkipRecipe("FVP_BASE_A_AEM_TARBALL_URI not set")
|
||||
}
|
||||
|
||||
do_install() {
|
||||
mkdir --parents ${D}${FVPDIR} ${D}${bindir}
|
||||
|
||||
cp --archive --no-preserve=ownership ${S}/Base_RevC_AEMvA_pkg/* ${D}${FVPDIR}/
|
||||
|
||||
fvp_link_binaries
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
HOMEPAGE = "https://developer.arm.com/tools-and-software/simulation-models/fixed-virtual-platforms"
|
||||
|
||||
# FVP has an End User License Agreement. Add Arm-FVP-EULA to your
|
||||
# LICENSE_FLAGS_WHITELIST if you agree to these terms.
|
||||
LICENSE_FLAGS = "Arm-FVP-EULA"
|
||||
|
||||
LICENSE = "Proprietary & Apache-2.0 & Python-2.0 & GPL-3.0-with-GCC-exception & Zlib & NCSA & LGPLv2+ & MIT & BSD-3-Clause"
|
||||
|
||||
COMPATIBLE_HOST = '(x86_64|i.86).*-linux'
|
||||
FVP_ARCH = "Linux64_GCC-6.4"
|
||||
|
||||
# The directory the FVP is installed into
|
||||
FVPDIR = "${libdir}/fvp/${BPN}"
|
||||
|
||||
# Used in do_install to create symlinks in $bindir to $FVPDIR
|
||||
fvp_link_binaries() {
|
||||
for FVP in ${D}${FVPDIR}/models/${FVP_ARCH}/FVP_*; do
|
||||
lnr $FVP ${D}${bindir}/$(basename $FVP)
|
||||
done
|
||||
# But not the .so files too
|
||||
rm -f ${D}${bindir}/*.so
|
||||
}
|
||||
|
||||
FILES_${PN} = "${bindir} ${FVPDIR}"
|
||||
|
||||
# Prebuilt binaries are already stripped
|
||||
INSANE_SKIP_${PN} += "already-stripped"
|
||||
# FVP can optionally have a GUI, but we can use the host libraries in native/nativesdk
|
||||
INSANE_SKIP_${PN} += "file-rdeps"
|
||||
|
||||
# FVP brings its own standard library so don't let it be used as a shlib provider
|
||||
PRIVATE_LIBS = "libgcc_s.so.1 libstdc++.so.6"
|
||||
|
||||
INHIBIT_DEFAULT_DEPS = "1"
|
||||
|
||||
BBCLASSEXTEND = "native nativesdk"
|
||||
@@ -0,0 +1,25 @@
|
||||
require fvp-common.inc
|
||||
|
||||
# These need to be set
|
||||
MODEL ?= "unset"
|
||||
MODEL_CODE ?= "unset"
|
||||
PV ?= "unset"
|
||||
|
||||
SUMMARY = "Arm Fixed Virtual Platform - ${MODEL} Ecosystem Reference Design"
|
||||
HOMEPAGE = "https://developer.arm.com/tools-and-software/open-source-software/arm-platforms-software/arm-ecosystem-fvps"
|
||||
|
||||
SRC_URI = "https://developer.arm.com/-/media/Arm%20Developer%20Community/Downloads/OSS/FVP/${MODEL}/${MODEL_CODE}_${PV}.tgz;subdir=${BP}"
|
||||
|
||||
LIC_FILES_CHKSUM = "file://license_terms/license_agreement.txt;md5=1a33828e132ba71861c11688dbb0bd16 \
|
||||
file://license_terms/third_party_licenses.txt;md5=47473b1e04b70938cf0a7ffea8ea4cc3"
|
||||
|
||||
do_install() {
|
||||
mkdir --parents ${D}${FVPDIR} ${D}${bindir}
|
||||
|
||||
${S}/${MODEL_CODE}.sh \
|
||||
--i-agree-to-the-contained-eula \
|
||||
--no-interactive \
|
||||
--destination ${D}${FVPDIR}
|
||||
|
||||
fvp_link_binaries
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
require fvp-ecosystem.inc
|
||||
|
||||
MODEL = "Library"
|
||||
MODEL_CODE = "FVP_ARM_Std_Library"
|
||||
PV = "11.14_21"
|
||||
|
||||
HOMEPAGE = "https://developer.arm.com/tools-and-software/simulation-models/fixed-virtual-platforms"
|
||||
|
||||
LIC_FILES_CHKSUM = "file://license_terms/license_agreement.txt;md5=a50d186fffa51ed55599183aad911298 \
|
||||
file://license_terms/third_party_licenses.txt;md5=b40ecbbbd3409d48263437b782df6df9"
|
||||
|
||||
|
||||
# The FVP Library tarball cannot be downloaded directly, so download the it
|
||||
# yourself from from the homepage and set FVP_LIBRARY_TARBALL_URI appropriately
|
||||
# (for example, "file:///home/user/FVP_ARM_Std_Library_11.14_21.tgz").
|
||||
FVP_LIBRARY_TARBALL_URI ?= ""
|
||||
|
||||
SRC_URI = "${FVP_LIBRARY_TARBALL_URI};subdir=${BP}"
|
||||
python() {
|
||||
if not d.getVar("FVP_LIBRARY_TARBALL_URI"):
|
||||
raise bb.parse.SkipRecipe("FVP_LIBRARY_TARBALL_URI not set")
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
require fvp-ecosystem.inc
|
||||
|
||||
MODEL = "Neoverse-N1"
|
||||
MODEL_CODE = "FVP_RD_N1_edge"
|
||||
PV = "11.12_43"
|
||||
|
||||
SRC_URI[sha256sum] = "e428cc44db251202bf45ae68d40832d01efbc5d0f1323f1ce46237213dd4f0fa"
|
||||
@@ -0,0 +1,7 @@
|
||||
require fvp-ecosystem.inc
|
||||
|
||||
MODEL = "SGI-575"
|
||||
MODEL_CODE = "FVP_CSS_SGI-575"
|
||||
PV = "11.12_59"
|
||||
|
||||
SRC_URI[sha256sum] = "86c7a16d83b0801278b4a3d05c8d42c4955ed22a0dbea3c583798fb971bc425c"
|
||||
@@ -1,11 +1,17 @@
|
||||
Change USB_CONN_GPIO to 'y' by default and regenerate the defconfig via
|
||||
`make savedefconfig`.
|
||||
From c72967164b63ea16c7c0276a306b66797998b62a Mon Sep 17 00:00:00 2001
|
||||
From: Jon Mason <jdmason@kudzu.us>
|
||||
Date: Sat, 1 May 2021 17:18:37 -0400
|
||||
Subject: [PATCH] Change USB_CONN_GPIO to 'y' by default and regenerate the
|
||||
defconfig via `make savedefconfig`.
|
||||
|
||||
Upstream-Status: Inappropriate [not needed in newer kernels]
|
||||
Signed-off-by: Jon Mason <jon.mason@arm.com>
|
||||
---
|
||||
arch/arm64/configs/defconfig | 65 +++++++++++++-----------------------
|
||||
1 file changed, 24 insertions(+), 41 deletions(-)
|
||||
|
||||
diff --git a/arch/arm64/configs/defconfig b/arch/arm64/configs/defconfig
|
||||
index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
index 6d84761d1285..8a2f7e075ba9 100644
|
||||
--- a/arch/arm64/configs/defconfig
|
||||
+++ b/arch/arm64/configs/defconfig
|
||||
@@ -13,7 +13,6 @@ CONFIG_IKCONFIG=y
|
||||
@@ -36,11 +42,11 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_ACPI=y
|
||||
CONFIG_ACPI_APEI=y
|
||||
CONFIG_ACPI_APEI_GHES=y
|
||||
-CONFIG_ACPI_APEI_PCIEAER=y
|
||||
-CONFIG_PCIEAER=y
|
||||
CONFIG_ACPI_APEI_PCIEAER=y
|
||||
CONFIG_ACPI_APEI_MEMORY_FAILURE=y
|
||||
CONFIG_ACPI_APEI_EINJ=y
|
||||
CONFIG_VIRTUALIZATION=y
|
||||
@@ -180,12 +176,11 @@ CONFIG_QRTR_SMD=m
|
||||
@@ -181,12 +177,11 @@ CONFIG_QRTR_SMD=m
|
||||
CONFIG_QRTR_TUN=m
|
||||
CONFIG_BPF_JIT=y
|
||||
CONFIG_CAN=m
|
||||
@@ -54,7 +60,15 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
# CONFIG_BT_LE is not set
|
||||
CONFIG_BT_LEDS=y
|
||||
# CONFIG_BT_DEBUGFS is not set
|
||||
@@ -222,13 +217,13 @@ CONFIG_PCI_HOST_THUNDER_ECAM=y
|
||||
@@ -206,6 +201,7 @@ CONFIG_NFC_NCI=m
|
||||
CONFIG_NFC_S3FWRN5_I2C=m
|
||||
CONFIG_PCI=y
|
||||
CONFIG_PCIEPORTBUS=y
|
||||
+CONFIG_PCIEAER=y
|
||||
CONFIG_PCI_IOV=y
|
||||
CONFIG_PCI_PASID=y
|
||||
CONFIG_HOTPLUG_PCI=y
|
||||
@@ -223,13 +219,13 @@ CONFIG_PCI_HOST_THUNDER_ECAM=y
|
||||
CONFIG_PCIE_ROCKCHIP_HOST=m
|
||||
CONFIG_PCIE_BRCMSTB=m
|
||||
CONFIG_PCI_LAYERSCAPE=y
|
||||
@@ -69,7 +83,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_PCI_ENDPOINT=y
|
||||
CONFIG_PCI_ENDPOINT_CONFIGFS=y
|
||||
CONFIG_PCI_EPF_TEST=m
|
||||
@@ -238,7 +233,6 @@ CONFIG_FW_LOADER_USER_HELPER=y
|
||||
@@ -239,7 +235,6 @@ CONFIG_FW_LOADER_USER_HELPER=y
|
||||
CONFIG_FW_LOADER_USER_HELPER_FALLBACK=y
|
||||
CONFIG_HISILICON_LPC=y
|
||||
CONFIG_SIMPLE_PM_BUS=y
|
||||
@@ -77,7 +91,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_TEGRA_ACONNECT=m
|
||||
CONFIG_MTD=y
|
||||
CONFIG_MTD_BLOCK=y
|
||||
@@ -257,7 +251,6 @@ CONFIG_MTD_NAND_MARVELL=y
|
||||
@@ -258,7 +253,6 @@ CONFIG_MTD_NAND_MARVELL=y
|
||||
CONFIG_MTD_NAND_FSL_IFC=y
|
||||
CONFIG_MTD_NAND_QCOM=y
|
||||
CONFIG_MTD_SPI_NOR=y
|
||||
@@ -85,7 +99,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_BLK_DEV_LOOP=y
|
||||
CONFIG_BLK_DEV_NBD=m
|
||||
CONFIG_VIRTIO_BLK=y
|
||||
@@ -342,18 +335,18 @@ CONFIG_SNI_NETSEC=y
|
||||
@@ -343,18 +337,18 @@ CONFIG_SNI_NETSEC=y
|
||||
CONFIG_STMMAC_ETH=m
|
||||
CONFIG_TI_K3_AM65_CPSW_NUSS=y
|
||||
CONFIG_QCOM_IPA=m
|
||||
@@ -107,7 +121,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_USB_PEGASUS=m
|
||||
CONFIG_USB_RTL8150=m
|
||||
CONFIG_USB_RTL8152=m
|
||||
@@ -453,6 +446,7 @@ CONFIG_SPI=y
|
||||
@@ -454,6 +448,7 @@ CONFIG_SPI=y
|
||||
CONFIG_SPI_ARMADA_3700=y
|
||||
CONFIG_SPI_BCM2835=m
|
||||
CONFIG_SPI_BCM2835AUX=m
|
||||
@@ -115,7 +129,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_SPI_FSL_LPSPI=y
|
||||
CONFIG_SPI_FSL_QUADSPI=y
|
||||
CONFIG_SPI_NXP_FLEXSPI=y
|
||||
@@ -513,9 +507,6 @@ CONFIG_GPIO_PCA953X_IRQ=y
|
||||
@@ -514,9 +509,6 @@ CONFIG_GPIO_PCA953X_IRQ=y
|
||||
CONFIG_GPIO_BD9571MWV=m
|
||||
CONFIG_GPIO_MAX77620=y
|
||||
CONFIG_GPIO_SL28CPLD=m
|
||||
@@ -125,7 +139,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_POWER_RESET_MSM=y
|
||||
CONFIG_POWER_RESET_XGENE=y
|
||||
CONFIG_POWER_RESET_SYSCON=y
|
||||
@@ -532,10 +523,10 @@ CONFIG_SENSORS_INA3221=m
|
||||
@@ -533,10 +525,10 @@ CONFIG_SENSORS_INA3221=m
|
||||
CONFIG_THERMAL_GOV_POWER_ALLOCATOR=y
|
||||
CONFIG_CPU_THERMAL=y
|
||||
CONFIG_THERMAL_EMULATION=y
|
||||
@@ -138,7 +152,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_ROCKCHIP_THERMAL=m
|
||||
CONFIG_RCAR_THERMAL=y
|
||||
CONFIG_RCAR_GEN3_THERMAL=y
|
||||
@@ -552,7 +543,6 @@ CONFIG_WATCHDOG=y
|
||||
@@ -553,7 +545,6 @@ CONFIG_WATCHDOG=y
|
||||
CONFIG_SL28CPLD_WATCHDOG=m
|
||||
CONFIG_ARM_SP805_WATCHDOG=y
|
||||
CONFIG_ARM_SBSA_WATCHDOG=y
|
||||
@@ -146,7 +160,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_S3C2410_WATCHDOG=y
|
||||
CONFIG_DW_WATCHDOG=y
|
||||
CONFIG_SUNXI_WATCHDOG=m
|
||||
@@ -561,6 +551,7 @@ CONFIG_IMX_SC_WDT=m
|
||||
@@ -562,6 +553,7 @@ CONFIG_IMX_SC_WDT=m
|
||||
CONFIG_QCOM_WDT=m
|
||||
CONFIG_MESON_GXBB_WATCHDOG=m
|
||||
CONFIG_MESON_WATCHDOG=m
|
||||
@@ -154,7 +168,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_RENESAS_WDT=y
|
||||
CONFIG_UNIPHIER_WATCHDOG=y
|
||||
CONFIG_BCM2835_WDT=y
|
||||
@@ -607,13 +598,12 @@ CONFIG_MEDIA_CAMERA_SUPPORT=y
|
||||
@@ -608,13 +600,12 @@ CONFIG_MEDIA_CAMERA_SUPPORT=y
|
||||
CONFIG_MEDIA_ANALOG_TV_SUPPORT=y
|
||||
CONFIG_MEDIA_DIGITAL_TV_SUPPORT=y
|
||||
CONFIG_MEDIA_SDR_SUPPORT=y
|
||||
@@ -169,7 +183,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_VIDEO_RCAR_CSI2=m
|
||||
CONFIG_VIDEO_RCAR_VIN=m
|
||||
CONFIG_VIDEO_SUN6I_CSI=m
|
||||
@@ -628,7 +618,6 @@ CONFIG_SDR_PLATFORM_DRIVERS=y
|
||||
@@ -629,7 +620,6 @@ CONFIG_SDR_PLATFORM_DRIVERS=y
|
||||
CONFIG_VIDEO_RCAR_DRIF=m
|
||||
CONFIG_VIDEO_IMX219=m
|
||||
CONFIG_VIDEO_OV5645=m
|
||||
@@ -177,7 +191,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_DRM=m
|
||||
CONFIG_DRM_I2C_NXP_TDA998X=m
|
||||
CONFIG_DRM_MALI_DISPLAY=m
|
||||
@@ -660,8 +649,8 @@ CONFIG_DRM_PANEL_RAYDIUM_RM67191=m
|
||||
@@ -661,8 +651,8 @@ CONFIG_DRM_PANEL_RAYDIUM_RM67191=m
|
||||
CONFIG_DRM_PANEL_SITRONIX_ST7703=m
|
||||
CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA=m
|
||||
CONFIG_DRM_DISPLAY_CONNECTOR=m
|
||||
@@ -187,7 +201,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_DRM_SII902X=m
|
||||
CONFIG_DRM_SIMPLE_BRIDGE=m
|
||||
CONFIG_DRM_THINE_THC63LVD1024=m
|
||||
@@ -682,7 +671,6 @@ CONFIG_DRM_PANFROST=m
|
||||
@@ -683,7 +673,6 @@ CONFIG_DRM_PANFROST=m
|
||||
CONFIG_FB=y
|
||||
CONFIG_FB_MODE_HELPERS=y
|
||||
CONFIG_FB_EFI=y
|
||||
@@ -195,7 +209,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_BACKLIGHT_PWM=m
|
||||
CONFIG_BACKLIGHT_LP855X=m
|
||||
CONFIG_LOGO=y
|
||||
@@ -726,7 +714,6 @@ CONFIG_SND_SOC_WSA881X=m
|
||||
@@ -727,7 +716,6 @@ CONFIG_SND_SOC_WSA881X=m
|
||||
CONFIG_SND_SIMPLE_CARD=m
|
||||
CONFIG_SND_AUDIO_GRAPH_CARD=m
|
||||
CONFIG_I2C_HID=m
|
||||
@@ -203,7 +217,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_USB=y
|
||||
CONFIG_USB_OTG=y
|
||||
CONFIG_USB_XHCI_HCD=y
|
||||
@@ -859,7 +846,6 @@ CONFIG_VIRTIO_BALLOON=y
|
||||
@@ -859,7 +847,6 @@ CONFIG_VIRTIO_BALLOON=y
|
||||
CONFIG_VIRTIO_MMIO=y
|
||||
CONFIG_XEN_GNTDEV=y
|
||||
CONFIG_XEN_GRANT_DEV_ALLOC=y
|
||||
@@ -211,7 +225,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_CHROME_PLATFORMS=y
|
||||
CONFIG_CROS_EC=y
|
||||
CONFIG_CROS_EC_I2C=y
|
||||
@@ -885,8 +871,8 @@ CONFIG_QCOM_A53PLL=y
|
||||
@@ -885,8 +872,8 @@ CONFIG_QCOM_A53PLL=y
|
||||
CONFIG_QCOM_CLK_APCS_MSM8916=y
|
||||
CONFIG_QCOM_CLK_SMD_RPM=y
|
||||
CONFIG_QCOM_CLK_RPMH=y
|
||||
@@ -221,7 +235,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_MSM_GCC_8916=y
|
||||
CONFIG_MSM_GCC_8994=y
|
||||
CONFIG_MSM_MMCC_8996=y
|
||||
@@ -894,12 +880,9 @@ CONFIG_MSM_GCC_8998=y
|
||||
@@ -894,12 +881,9 @@ CONFIG_MSM_GCC_8998=y
|
||||
CONFIG_QCS_GCC_404=y
|
||||
CONFIG_SC_GCC_7180=y
|
||||
CONFIG_SDM_CAMCC_845=m
|
||||
@@ -234,7 +248,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_SM_GPUCC_8150=y
|
||||
CONFIG_SM_GPUCC_8250=y
|
||||
CONFIG_QCOM_HFPLL=y
|
||||
@@ -930,6 +913,7 @@ CONFIG_RASPBERRYPI_POWER=y
|
||||
@@ -930,6 +914,7 @@ CONFIG_RASPBERRYPI_POWER=y
|
||||
CONFIG_FSL_DPAA=y
|
||||
CONFIG_FSL_MC_DPIO=y
|
||||
CONFIG_QCOM_AOSS_QMP=y
|
||||
@@ -242,7 +256,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_QCOM_GENI_SE=y
|
||||
CONFIG_QCOM_RMTFS_MEM=m
|
||||
CONFIG_QCOM_RPMH=y
|
||||
@@ -941,19 +925,20 @@ CONFIG_QCOM_SMP2P=y
|
||||
@@ -941,19 +926,20 @@ CONFIG_QCOM_SMP2P=y
|
||||
CONFIG_QCOM_SMSM=y
|
||||
CONFIG_QCOM_SOCINFO=m
|
||||
CONFIG_QCOM_APR=m
|
||||
@@ -271,7 +285,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_ROCKCHIP_PM_DOMAINS=y
|
||||
CONFIG_ARCH_TEGRA_132_SOC=y
|
||||
CONFIG_ARCH_TEGRA_210_SOC=y
|
||||
@@ -1017,9 +1002,9 @@ CONFIG_PHY_UNIPHIER_USB3=y
|
||||
@@ -1017,9 +1003,9 @@ CONFIG_PHY_UNIPHIER_USB3=y
|
||||
CONFIG_PHY_TEGRA_XUSB=y
|
||||
CONFIG_ARM_SMMU_V3_PMU=m
|
||||
CONFIG_FSL_IMX8_DDR_PMU=m
|
||||
@@ -282,7 +296,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_NVMEM_IMX_OCOTP=y
|
||||
CONFIG_NVMEM_IMX_OCOTP_SCU=y
|
||||
CONFIG_QCOM_QFPROM=y
|
||||
@@ -1035,10 +1020,9 @@ CONFIG_FPGA_REGION=m
|
||||
@@ -1035,10 +1021,9 @@ CONFIG_FPGA_REGION=m
|
||||
CONFIG_OF_FPGA_REGION=m
|
||||
CONFIG_TEE=y
|
||||
CONFIG_OPTEE=y
|
||||
@@ -294,7 +308,7 @@ index 5cfe3cf6f2ac..1fed16950a7c 100644
|
||||
CONFIG_INTERCONNECT=y
|
||||
CONFIG_INTERCONNECT_QCOM=y
|
||||
CONFIG_INTERCONNECT_QCOM_MSM8916=m
|
||||
@@ -1059,7 +1043,6 @@ CONFIG_CUSE=m
|
||||
@@ -1059,7 +1044,6 @@ CONFIG_CUSE=m
|
||||
CONFIG_OVERLAY_FS=m
|
||||
CONFIG_VFAT_FS=y
|
||||
CONFIG_HUGETLBFS=y
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
CONFIG_HW_RANDOM_OPTEE=y
|
||||
CONFIG_TEE=y
|
||||
|
||||
#
|
||||
# TEE drivers
|
||||
#
|
||||
CONFIG_OPTEE=y
|
||||
CONFIG_OPTEE_SHM_NUM_PRIV_PAGES=1
|
||||
# end of TEE drivers
|
||||
|
||||
@@ -1,126 +0,0 @@
|
||||
Revert ZONE_DMA patches
|
||||
|
||||
Upstream-Status: Inappropriate
|
||||
Signed-off-by: Jon Mason <jon.mason@arm.com>
|
||||
|
||||
diff --git a/arch/arm64/mm/init.c b/arch/arm64/mm/init.c
|
||||
index 916e0547fdcc..7fbb9c85af8a 100644
|
||||
--- a/arch/arm64/mm/init.c
|
||||
+++ b/arch/arm64/mm/init.c
|
||||
@@ -29,7 +29,6 @@
|
||||
#include <linux/kexec.h>
|
||||
#include <linux/crash_dump.h>
|
||||
#include <linux/hugetlb.h>
|
||||
-#include <linux/acpi_iort.h>
|
||||
|
||||
#include <asm/boot.h>
|
||||
#include <asm/fixmap.h>
|
||||
@@ -43,6 +42,8 @@
|
||||
#include <asm/tlb.h>
|
||||
#include <asm/alternative.h>
|
||||
|
||||
+#define ARM64_ZONE_DMA_BITS 30
|
||||
+
|
||||
/*
|
||||
* We need to be able to catch inadvertent references to memstart_addr
|
||||
* that occur (potentially in generic code) before arm64_memblock_init()
|
||||
@@ -187,13 +188,9 @@ static phys_addr_t __init max_zone_phys(unsigned int zone_bits)
|
||||
static void __init zone_sizes_init(unsigned long min, unsigned long max)
|
||||
{
|
||||
unsigned long max_zone_pfns[MAX_NR_ZONES] = {0};
|
||||
- unsigned int __maybe_unused acpi_zone_dma_bits;
|
||||
- unsigned int __maybe_unused dt_zone_dma_bits;
|
||||
|
||||
#ifdef CONFIG_ZONE_DMA
|
||||
- acpi_zone_dma_bits = fls64(acpi_iort_dma_get_max_cpu_address());
|
||||
- dt_zone_dma_bits = fls64(of_dma_get_max_cpu_address(NULL));
|
||||
- zone_dma_bits = min3(32U, dt_zone_dma_bits, acpi_zone_dma_bits);
|
||||
+ zone_dma_bits = ARM64_ZONE_DMA_BITS;
|
||||
arm64_dma_phys_limit = max_zone_phys(zone_dma_bits);
|
||||
max_zone_pfns[ZONE_DMA] = PFN_DOWN(arm64_dma_phys_limit);
|
||||
#endif
|
||||
diff --git a/drivers/acpi/arm64/iort.c b/drivers/acpi/arm64/iort.c
|
||||
index 2494138a6905..94f34109695c 100644
|
||||
--- a/drivers/acpi/arm64/iort.c
|
||||
+++ b/drivers/acpi/arm64/iort.c
|
||||
@@ -1730,58 +1730,3 @@ void __init acpi_iort_init(void)
|
||||
|
||||
iort_init_platform_devices();
|
||||
}
|
||||
-
|
||||
-#ifdef CONFIG_ZONE_DMA
|
||||
-/*
|
||||
- * Extract the highest CPU physical address accessible to all DMA masters in
|
||||
- * the system. PHYS_ADDR_MAX is returned when no constrained device is found.
|
||||
- */
|
||||
-phys_addr_t __init acpi_iort_dma_get_max_cpu_address(void)
|
||||
-{
|
||||
- phys_addr_t limit = PHYS_ADDR_MAX;
|
||||
- struct acpi_iort_node *node, *end;
|
||||
- struct acpi_table_iort *iort;
|
||||
- acpi_status status;
|
||||
- int i;
|
||||
-
|
||||
- if (acpi_disabled)
|
||||
- return limit;
|
||||
-
|
||||
- status = acpi_get_table(ACPI_SIG_IORT, 0,
|
||||
- (struct acpi_table_header **)&iort);
|
||||
- if (ACPI_FAILURE(status))
|
||||
- return limit;
|
||||
-
|
||||
- node = ACPI_ADD_PTR(struct acpi_iort_node, iort, iort->node_offset);
|
||||
- end = ACPI_ADD_PTR(struct acpi_iort_node, iort, iort->header.length);
|
||||
-
|
||||
- for (i = 0; i < iort->node_count; i++) {
|
||||
- if (node >= end)
|
||||
- break;
|
||||
-
|
||||
- switch (node->type) {
|
||||
- struct acpi_iort_named_component *ncomp;
|
||||
- struct acpi_iort_root_complex *rc;
|
||||
- phys_addr_t local_limit;
|
||||
-
|
||||
- case ACPI_IORT_NODE_NAMED_COMPONENT:
|
||||
- ncomp = (struct acpi_iort_named_component *)node->node_data;
|
||||
- local_limit = DMA_BIT_MASK(ncomp->memory_address_limit);
|
||||
- limit = min_not_zero(limit, local_limit);
|
||||
- break;
|
||||
-
|
||||
- case ACPI_IORT_NODE_PCI_ROOT_COMPLEX:
|
||||
- if (node->revision < 1)
|
||||
- break;
|
||||
-
|
||||
- rc = (struct acpi_iort_root_complex *)node->node_data;
|
||||
- local_limit = DMA_BIT_MASK(rc->memory_address_limit);
|
||||
- limit = min_not_zero(limit, local_limit);
|
||||
- break;
|
||||
- }
|
||||
- node = ACPI_ADD_PTR(struct acpi_iort_node, node, node->length);
|
||||
- }
|
||||
- acpi_put_table(&iort->header);
|
||||
- return limit;
|
||||
-}
|
||||
-#endif
|
||||
diff --git a/include/linux/acpi_iort.h b/include/linux/acpi_iort.h
|
||||
index 1a12baa58e40..20a32120bb88 100644
|
||||
--- a/include/linux/acpi_iort.h
|
||||
+++ b/include/linux/acpi_iort.h
|
||||
@@ -38,7 +38,6 @@ void iort_dma_setup(struct device *dev, u64 *dma_addr, u64 *size);
|
||||
const struct iommu_ops *iort_iommu_configure_id(struct device *dev,
|
||||
const u32 *id_in);
|
||||
int iort_iommu_msi_get_resv_regions(struct device *dev, struct list_head *head);
|
||||
-phys_addr_t acpi_iort_dma_get_max_cpu_address(void);
|
||||
#else
|
||||
static inline void acpi_iort_init(void) { }
|
||||
static inline u32 iort_msi_map_id(struct device *dev, u32 id)
|
||||
@@ -56,9 +55,6 @@ static inline const struct iommu_ops *iort_iommu_configure_id(
|
||||
static inline
|
||||
int iort_iommu_msi_get_resv_regions(struct device *dev, struct list_head *head)
|
||||
{ return 0; }
|
||||
-
|
||||
-static inline phys_addr_t acpi_iort_dma_get_max_cpu_address(void)
|
||||
-{ return PHYS_ADDR_MAX; }
|
||||
#endif
|
||||
|
||||
#endif /* __ACPI_IORT_H__ */
|
||||
@@ -1,11 +0,0 @@
|
||||
FILESEXTRAPATHS_prepend := "${THISDIR}:${THISDIR}/linux-yocto:"
|
||||
|
||||
SRC_URI_append_qemuarm64-sbsa = " \
|
||||
file://defconfig.patch \
|
||||
"
|
||||
|
||||
COMPATIBLE_MACHINE_generic-arm64 = "generic-arm64"
|
||||
|
||||
SRC_URI_append_generic-arm64 = " \
|
||||
file://defconfig.patch \
|
||||
"
|
||||
@@ -1,3 +1,21 @@
|
||||
FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
|
||||
ARMFILESPATHS := "${THISDIR}/${PN}:"
|
||||
|
||||
SRC_URI_append_qemuarm64-secureboot = " file://zone_dma_revert.patch"
|
||||
COMPATIBLE_MACHINE_generic-arm64 = "generic-arm64"
|
||||
FILESEXTRAPATHS_prepend_generic-arm64 = "${ARMFILESPATHS}"
|
||||
SRC_URI_append_generic-arm64 = " \
|
||||
file://defconfig.patch \
|
||||
"
|
||||
|
||||
FILESEXTRAPATHS_prepend_qemuarm64-sbsa = "${ARMFILESPATHS}"
|
||||
LINUX_VERSION_qemuarm64-sbsa = "5.10.30"
|
||||
SRCREV_machine_qemuarm64-sbsa = "d6e20b2257ecfa6e796a45a4175863862a28fa11"
|
||||
SRC_URI_append_qemuarm64-sbsa = " \
|
||||
file://defconfig.patch \
|
||||
"
|
||||
|
||||
LINUX_VERSION_qemuarm64-secureboot = "5.10.21"
|
||||
SRCREV_machine_qemuarm64-secureboot = "012f78dadb7186c479343b77e97df2925caf681e"
|
||||
FILESEXTRAPATHS_prepend_qemuarm64-secureboot = "${ARMFILESPATHS}"
|
||||
SRC_URI_append_qemuarm64-secureboot = " \
|
||||
file://tee.cfg \
|
||||
"
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
# short-description: Create an EFI disk image
|
||||
# long-description: Creates a partitioned EFI disk image that the user
|
||||
# can directly dd to boot media.
|
||||
|
||||
part /boot --source bootimg-efi --sourceparams="loader=${EFI_PROVIDER}" --label boot --active --align 1024 --use-uuid
|
||||
|
||||
part / --source rootfs --fstype=ext4 --label root --align 1024 --use-uuid
|
||||
|
||||
part swap --size 44 --label swap --fstype=swap --use-uuid
|
||||
|
||||
bootloader --ptable gpt --timeout=5 --append="rootwait rootfstype=ext4"
|
||||
Executable
+167
@@ -0,0 +1,167 @@
|
||||
#! /usr/bin/env python3
|
||||
|
||||
import json
|
||||
import os
|
||||
import sys
|
||||
import subprocess
|
||||
import pathlib
|
||||
|
||||
import logging
|
||||
logger = logging.getLogger("RunFVP")
|
||||
|
||||
# TODO: option to switch between telnet and netcat
|
||||
connect_command = "telnet localhost %port"
|
||||
|
||||
terminal_map = {
|
||||
"tmux": f"tmux new-window -n \"%title\" \"{connect_command}\"",
|
||||
"xterm": f"xterm -title \"%title\" -e {connect_command}",
|
||||
"none": ""
|
||||
# TODO more terminals
|
||||
}
|
||||
|
||||
def get_image_directory(machine=None):
|
||||
"""
|
||||
Get the DEPLOY_DIR_IMAGE for the specified machine
|
||||
(or the configured machine if not set).
|
||||
"""
|
||||
import bb.tinfoil
|
||||
|
||||
if machine:
|
||||
os.environ["MACHINE"] = machine
|
||||
|
||||
with bb.tinfoil.Tinfoil() as tinfoil:
|
||||
tinfoil.prepare(config_only=True)
|
||||
image_dir = tinfoil.config_data.getVar("DEPLOY_DIR_IMAGE")
|
||||
logger.debug(f"Got DEPLOY_DIR_IMAGE {image_dir}")
|
||||
return pathlib.Path(image_dir)
|
||||
|
||||
|
||||
def runfvp(args):
|
||||
import argparse
|
||||
|
||||
parser = argparse.ArgumentParser(description="Run images in a FVP")
|
||||
parser.add_argument("config", nargs="?", help="Machine name or path to .fvpconf file")
|
||||
group = parser.add_mutually_exclusive_group()
|
||||
group.add_argument("-t", "--terminals", choices=terminal_map.keys(), default="xterm", help="Automatically start terminals")
|
||||
group.add_argument("-c", "--console", action="store_true", help="Attach the first uart to stdin/stdout")
|
||||
parser.add_argument("--verbose", action="store_true", help="Output verbose logging")
|
||||
parser.usage = f"{parser.format_usage().strip()} -- [ arguments passed to FVP ]"
|
||||
# TODO option for telnet vs netcat
|
||||
|
||||
try:
|
||||
i = sys.argv.index("--")
|
||||
arguments = sys.argv[1:i]
|
||||
fvp_args = sys.argv[i+1:]
|
||||
except ValueError:
|
||||
arguments = sys.argv[1:]
|
||||
fvp_args = []
|
||||
|
||||
args = parser.parse_args(args=arguments)
|
||||
logging.basicConfig(level=args.verbose and logging.DEBUG or logging.WARNING)
|
||||
logger.debug(f"Parsed arguments are {vars(args)}")
|
||||
|
||||
# If we're hooking up the console, don't start any terminals
|
||||
if args.console:
|
||||
args.terminals = "none"
|
||||
|
||||
if args.config and os.path.exists(args.config):
|
||||
config_file = args.config
|
||||
else:
|
||||
image_dir = get_image_directory(args.config)
|
||||
# All .fvpconf configuration files
|
||||
configs = image_dir.glob("*.fvpconf")
|
||||
# Just the files
|
||||
configs = [p for p in configs if p.is_file() and not p.is_symlink()]
|
||||
if not configs:
|
||||
print(f"Cannot find any .fvpconf in {image_dir}")
|
||||
sys.exit(1)
|
||||
# Sorted by modification time
|
||||
configs = sorted(configs, key=lambda p: p.stat().st_mtime)
|
||||
config_file = configs[-1]
|
||||
|
||||
logger.debug(f"Loading {config_file}")
|
||||
with open(config_file) as f:
|
||||
config = json.load(f)
|
||||
|
||||
# Ensure that all expected keys are present
|
||||
def sanitise(key, value):
|
||||
if key not in config or config[key] is None:
|
||||
config[key] = value
|
||||
sanitise("fvp-bindir", "")
|
||||
sanitise("exe", "")
|
||||
sanitise("parameters", {})
|
||||
sanitise("data", {})
|
||||
sanitise("applications", {})
|
||||
sanitise("terminals", {})
|
||||
sanitise("args", [])
|
||||
sanitise("console", "")
|
||||
|
||||
if not config["exe"]:
|
||||
logger.error("Required value FVP_EXE not set in machine configuration")
|
||||
sys.exit(1)
|
||||
|
||||
cli = []
|
||||
if config["fvp-bindir"]:
|
||||
cli.append(os.path.join(config["fvp-bindir"], config["exe"]))
|
||||
else:
|
||||
cli.append(config["exe"])
|
||||
|
||||
for param, value in config["parameters"].items():
|
||||
cli.extend(["--parameter", f"{param}={value}"])
|
||||
|
||||
for value in config["data"]:
|
||||
cli.extend(["--data", value])
|
||||
|
||||
for param, value in config["applications"].items():
|
||||
cli.extend(["--application", f"{param}={value}"])
|
||||
|
||||
for terminal, name in config["terminals"].items():
|
||||
# If terminals are enabled and this terminal has been named
|
||||
if args.terminals != "none" and name:
|
||||
# TODO if raw mode
|
||||
# cli.extend(["--parameter", f"{terminal}.mode=raw"])
|
||||
# TODO put name into terminal title
|
||||
cli.extend(["--parameter", f"{terminal}.terminal_command={terminal_map[args.terminals]}"])
|
||||
else:
|
||||
# Disable terminal
|
||||
cli.extend(["--parameter", f"{terminal}.start_telnet=0"])
|
||||
|
||||
cli.extend(config["args"])
|
||||
|
||||
# Finally add the user's extra arguments
|
||||
cli.extend(fvp_args)
|
||||
|
||||
logger.debug(f"Constructed FVP call: {cli}")
|
||||
if args.console:
|
||||
expected_terminal = config["console"]
|
||||
if not expected_terminal:
|
||||
logger.error("--console used but FVP_CONSOLE not set in machine configuration")
|
||||
sys.exit(1)
|
||||
|
||||
fvp_process = subprocess.Popen(cli, bufsize=1, universal_newlines=True, stdin=subprocess.DEVNULL, stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
|
||||
|
||||
import selectors, re
|
||||
selector = selectors.DefaultSelector()
|
||||
selector.register(fvp_process.stdout, selectors.EVENT_READ)
|
||||
output = ""
|
||||
looking = True
|
||||
while fvp_process.poll() is None:
|
||||
# TODO some sort of timeout for 'input never appeared'
|
||||
events = selector.select(timeout=10)
|
||||
for key, mask in events:
|
||||
line = key.fileobj.readline()
|
||||
output += line
|
||||
if looking:
|
||||
m = re.match(fr"^{expected_terminal}: Listening.+port ([0-9]+)$", line)
|
||||
if m:
|
||||
port = m.group(1)
|
||||
subprocess.run(["telnet", "localhost", port])
|
||||
looking = False
|
||||
if fvp_process.returncode:
|
||||
logger.error(f"{fvp_process.args[0]} quit with code {fvp_process.returncode}:")
|
||||
logger.error(output)
|
||||
else:
|
||||
sys.exit(subprocess.run(cli).returncode)
|
||||
|
||||
if __name__ == "__main__":
|
||||
runfvp(sys.argv)
|
||||
Reference in New Issue
Block a user