Skip to content

Commit 1b3b631

Browse files
committed
ci: Also boot test with default QEMU smbios
1 parent c98abd8 commit 1b3b631

2 files changed

Lines changed: 38 additions & 5 deletions

File tree

.github/workflows/qemu.yml

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ name: Run in QEMU
22
on: [push, pull_request]
33

44
jobs:
5-
build:
6-
name: "Run in QEMU"
5+
miix:
6+
name: "Run in QEMU (Lenovo Miix 630)"
77
runs-on: ubuntu-latest
88
steps:
99
- name: Install additional build dependencies
@@ -16,6 +16,23 @@ jobs:
1616
- name: Prepare ESP
1717
run: dtc .ci/dummy.dts -o build-aarch64/msm8998-lenovo-miix-630.dtb
1818
- name: Run QEMU
19-
run: ./scripts/run_qemu.sh | tee log.txt
19+
run: ./scripts/run_qemu.sh miix | tee log.txt
2020
- name: Check the log
2121
run: "grep -q 'Detected device: LENOVO Miix 630' log.txt && ! grep -q 'Synchronous Exception' log.txt"
22+
nosmbios:
23+
name: "Run in QEMU (firmware default)"
24+
runs-on: ubuntu-latest
25+
steps:
26+
- name: Install additional build dependencies
27+
run: sudo apt-get update && sudo apt-get install -yqq llvm lld device-tree-compiler qemu-system-arm qemu-efi-aarch64
28+
- uses: actions/checkout@v4
29+
with:
30+
submodules: recursive
31+
- name: Build dtbloader
32+
run: git clean -dxf && make -j$(nproc) DEBUG=1 CFLAGS_SRC="-Wall -Werror -fsanitize=undefined -fsanitize-trap=all"
33+
- name: Prepare ESP
34+
run: dtc .ci/dummy.dts -o build-aarch64/msm8998-lenovo-miix-630.dtb
35+
- name: Run QEMU
36+
run: ./scripts/run_qemu.sh nosmbios | tee log.txt
37+
- name: Check the log
38+
run: "! grep -q 'Synchronous Exception' log.txt"

scripts/run_qemu.sh

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,23 @@ then
1919
wget https://github.com/pbatard/UEFI-Shell/releases/download/24H2/shellaa64.efi -O "$BUILDDIR/efi/boot/bootaa64.efi"
2020
fi
2121

22+
QEMU_SMBIOS_ARGS='
23+
-smbios type=1,manufacturer="LENOVO",product="81F1",sku="LENOVO_MT_81F1_BU_idea_FM_Miix 630",family="Miix 630"
24+
-smbios type=2,manufacturer="LENOVO",product="LNVNB161216"
25+
'
26+
27+
if [ $# -ge 1 ]
28+
then
29+
case $1 in
30+
nosmbios)
31+
QEMU_SMBIOS_ARGS=""
32+
;;
33+
miix)
34+
# default
35+
;;
36+
esac
37+
fi
38+
2239
timeout --foreground \
2340
--kill-after=120s \
2441
30s \
@@ -28,8 +45,7 @@ timeout --foreground \
2845
-m 512 \
2946
-bios "/usr/share/AAVMF/AAVMF_CODE.fd" \
3047
-drive if=virtio,format=raw,file=fat:rw:"$BUILDDIR" \
31-
-smbios type=1,manufacturer="LENOVO",product="81F1",sku="LENOVO_MT_81F1_BU_idea_FM_Miix 630",family="Miix 630" \
32-
-smbios type=2,manufacturer="LENOVO",product="LNVNB161216" \
48+
$QEMU_SMBIOS_ARGS \
3349
-nographic -no-reboot \
3450
| sed \
3551
-e 's/\x1b\[[0-9]\+;01H/\n/g' \

0 commit comments

Comments
 (0)