mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 10:11:27 +01:00
This removes qemu-system-aarch64-6.0.0-*-export and fixes the outstanding TODOs about efi-virtio.rom, now that the QEMU in use has it's /usr/share/ properly packaged. Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com> Reviewed-by: Michal Orzel <michal.orzel@amd.com>
79 lines
2.0 KiB
Bash
79 lines
2.0 KiB
Bash
#!/bin/bash
|
|
#
|
|
# XTF test utilities (arm64).
|
|
#
|
|
|
|
# Arch-specific environment overrides.
|
|
function xtf_arch_prepare()
|
|
{
|
|
export FW_PREFIX="${FW_PREFIX:-/usr/lib/u-boot/qemu_arm64/}"
|
|
export QEMU_PREFIX="${QEMU_PREFIX:-}"
|
|
export XEN_BINARY="${XEN_BINARY:-${WORKDIR}/xen}"
|
|
export XEN_CMDLINE="${XEN_CMDLINE:-loglvl=all noreboot console_timestamps=boot console=dtuart}"
|
|
export XTF_SRC_BRANCH="${XTF_SRC_BRANCH:-xtf-arm}"
|
|
export XTF_SRC_URI="${XTF_SRC_URI:-https://gitlab.com/xen-project/fusa/xtf.git}"
|
|
export XTF_SRC_VARIANTS="mmu64le"
|
|
}
|
|
|
|
# Perform arch-specific XTF environment setup.
|
|
function xtf_arch_setup()
|
|
{
|
|
# Crude check for local testing
|
|
if [ ! -d imagebuilder ]; then
|
|
git clone --depth 1 https://gitlab.com/xen-project/imagebuilder.git
|
|
fi
|
|
|
|
cat > ${WORKDIR}/config <<EOF
|
|
MEMORY_START="0x40000000"
|
|
MEMORY_END="0xC0000000"
|
|
|
|
XEN="xen"
|
|
DEVICE_TREE="virt-gicv2.dtb"
|
|
|
|
XEN_CMD="${XEN_CMDLINE}"
|
|
|
|
DOMU_KERNEL[0]="xtf-test"
|
|
DOMU_MEM[0]="128"
|
|
|
|
NUM_DOMUS=1
|
|
|
|
LOAD_CMD="tftpb"
|
|
UBOOT_SOURCE="boot.source"
|
|
UBOOT_SCRIPT="boot.scr"
|
|
EOF
|
|
cp ${XTF_BINARY} ${WORKDIR}/xtf-test
|
|
|
|
# Generate virt-gicv2.dtb
|
|
${QEMU_PREFIX}qemu-system-aarch64 \
|
|
-machine virtualization=true \
|
|
-cpu cortex-a57 \
|
|
-machine type=virt \
|
|
-m 2048 \
|
|
-smp 2 \
|
|
-display none \
|
|
-machine dumpdtb=${WORKDIR}/virt-gicv2.dtb
|
|
|
|
# Generate U-Boot environment
|
|
bash -x imagebuilder/scripts/uboot-script-gen \
|
|
-t tftp \
|
|
-d ${WORKDIR}/ \
|
|
-c ${WORKDIR}/config
|
|
|
|
export TEST_CMD="${QEMU_PREFIX}qemu-system-aarch64 \
|
|
-machine virtualization=true \
|
|
-cpu cortex-a57 \
|
|
-machine type=virt \
|
|
-no-reboot \
|
|
-nographic \
|
|
-monitor none \
|
|
-serial stdio \
|
|
-m 2048 \
|
|
-smp 2 \
|
|
-device virtio-net-pci,netdev=n0 \
|
|
-netdev user,id=n0,tftp=${WORKDIR} \
|
|
-bios ${FW_PREFIX}u-boot.bin \
|
|
"
|
|
|
|
export UBOOT_CMD="virtio scan; dhcp; tftpb 0x40000000 boot.scr; source 0x40000000"
|
|
}
|