tests: Add LoongArch to various test cases
I ran the test suite on a 3A5000 desktop, a LoongArch architecture machine, using Archlinux for LoongArch distro, see https://github.com/loongarchlinux. Some software versions are: * linux 6.3.0-rc4 * gcc 13.0.1 20230312 * binutils 2.40 * qemu 7.2.0 The test results of running "make check" with qemu 7.2 are as follows: ================================= GRUB 2.11: ./test-suite.log ================================= # TOTAL: 85 # PASS: 73 # SKIP: 8 # XFAIL: 0 # FAIL: 2 # XPASS: 0 # ERROR: 2 .. contents:: :depth: 2 ERROR: f2fs_test ================ mount: /tmp/grub-fs-tester.20230418175640563815408.f2fs.UDs/f2fs_rw: unknown filesystem type 'f2fs'. dmesg(1) may have more information after failed mount system call. MOUNT FAILED. ERROR f2fs_test (exit status: 99) FAIL: hfs_test ============== recode: Request `utf8..macroman' is erroneous mkfs.hfs: name required with -v option FAIL hfs_test (exit status: 1) ERROR: zfs_test =============== zpool not installed; cannot test zfs. ERROR zfs_test (exit status: 99) SKIP: pata_test =============== SKIP pata_test (exit status: 77) SKIP: ahci_test =============== SKIP ahci_test (exit status: 77) SKIP: uhci_test =============== SKIP uhci_test (exit status: 77) SKIP: ohci_test =============== SKIP ohci_test (exit status: 77) SKIP: ehci_test =============== SKIP ehci_test (exit status: 77) SKIP: fddboot_test ================== SKIP fddboot_test (exit status: 77) SKIP: netboot_test ================== SKIP netboot_test (exit status: 77) SKIP: pseries_test ================== SKIP pseries_test (exit status: 77) FAIL: grub_func_test ==================== WARNING: Image format was not specified for '/tmp/grub-shell.HeTAD8Ty3U/grub.iso' and probing guessed raw. Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted. Specify the 'raw' format explicitly to remove the restrictions. Functional test failure: shift_test: ... gfxterm_menu_640x480xi16:3 failed: 0xce34981e vs 0xd9f04953 tests/video_checksum.c:checksum:615: assert failed: 0 Checksum gfxterm_menu_640x480xi16:2 failed: 0xa8fb749d vs 0xbf3fa5d0 tests/video_checksum.c:checksum:615: assert failed: 0 Checksum gfxterm_menu_640x480xi16:1 failed: 0xce34981e vs 0xd9f04953 gfxterm_menu: FAIL ... videotest_checksum: videotest_checksum: PASS exfctest: exfctest: PASS TEST FAILURE FAIL grub_func_test (exit status: 1) We got 2 errors: * f2fs_test The kernel uses 16k pages, causing failures when loading the f2fs kernel module, see https://github.com/torvalds/linux/blob/master/fs/f2fs/super.c#L4670 This error can be ignored. * zfs_test zfs does not support the LoongArch architecture and is not compatible with the 6.3 kernel. This error can be ignored. We got 2 failures: * hfs_test I use recode 3.7.14-1 on Archlinux, running `recode -l` gives no output `MacRoman`, so we get this error. On Linux systems that support LoongArch, there is currently no need to use HFS, so this failure can be ignored. * grub_func_test I don't know the reason for this failure. I guess it may be related to qemu's edk2. In the previous review, I was told that the failure here is the expected behavior. So, we can ignore this failure. Signed-off-by: Xiaotian Wu <wuxiaotian@loongson.cn> Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
This commit is contained in:
parent
6588f2c295
commit
2188db1a9f
@ -30,7 +30,7 @@ case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||
mips*-arc | mips*-qemu_mips)
|
||||
exit 77;;
|
||||
# FIXME: No native drivers are available for those
|
||||
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi)
|
||||
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi | loongarch64-efi)
|
||||
exit 77;;
|
||||
esac
|
||||
|
||||
|
||||
@ -30,7 +30,7 @@ case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||
mips*-arc | mips*-qemu_mips)
|
||||
exit 77;;
|
||||
# FIXME: No native drivers are available for those
|
||||
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi)
|
||||
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi | loongarch64-efi)
|
||||
exit 77;;
|
||||
esac
|
||||
|
||||
|
||||
@ -12,6 +12,8 @@ case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||
# PLATFORM: Max RAM is 256M
|
||||
mips-qemu_mips | mipsel-qemu_mips)
|
||||
mem=256M;;
|
||||
loongarch64-efi)
|
||||
mem=3G;;
|
||||
*)
|
||||
mem=512M;;
|
||||
esac
|
||||
|
||||
@ -30,7 +30,7 @@ case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||
mips*-arc | mips*-qemu_mips)
|
||||
exit 77;;
|
||||
# FIXME: No native drivers are available for those
|
||||
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi)
|
||||
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi | loongarch64-efi)
|
||||
exit 77;;
|
||||
esac
|
||||
|
||||
|
||||
@ -33,7 +33,7 @@ case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||
i386-efi)
|
||||
exit 77;;
|
||||
# FIXME: No native drivers are available for those
|
||||
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi)
|
||||
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi | loongarch64-efi)
|
||||
exit 77;;
|
||||
i386-ieee1275)
|
||||
disk=hdb
|
||||
|
||||
@ -30,7 +30,7 @@ case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||
mips*-arc | mips*-qemu_mips)
|
||||
exit 77;;
|
||||
# FIXME: No native drivers are available for those
|
||||
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi)
|
||||
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi | loongarch64-efi)
|
||||
exit 77;;
|
||||
esac
|
||||
|
||||
|
||||
@ -72,6 +72,9 @@ case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||
i386-qemu)
|
||||
disk="ata0"
|
||||
;;
|
||||
loongarch64-efi)
|
||||
disk="hd1"
|
||||
;;
|
||||
esac
|
||||
|
||||
# Check the arguments.
|
||||
|
||||
@ -208,6 +208,17 @@ case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||
disk="device virtio-blk-device,drive=hd1 -drive if=none,id=hd1,file="
|
||||
serial_port=efi0
|
||||
;;
|
||||
loongarch64-efi)
|
||||
qemu=qemu-system-loongarch64
|
||||
boot=hd
|
||||
console=console
|
||||
trim=1
|
||||
qemuopts="-machine virt -cpu la464-loongarch-cpu -smp 4 -nographic -m 3G \
|
||||
-bios QEMU_EFI.fd -L ${srcdir} -L /usr/share/edk2/loongarch64 \
|
||||
-L /usr/share/qemu-efi-loongarch64 $qemuopts"
|
||||
disk="device virtio-blk-pci,drive=hd1 -drive if=none,id=hd1,file="
|
||||
serial_port=
|
||||
;;
|
||||
*)
|
||||
boot=hd
|
||||
qemu=qemu-system-i386
|
||||
@ -423,6 +434,8 @@ fi
|
||||
if [ x$boot = xhd ]; then
|
||||
if [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = arm64-efi ] || [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = arm-efi ]; then
|
||||
device="device virtio-blk-device,drive=hd0 -drive if=none,id=hd0,file="
|
||||
elif [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = loongarch64-efi ]; then
|
||||
device="device virtio-blk-pci,drive=grubdisk -drive if=none,id=grubdisk,file="
|
||||
elif [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = mips-arc ]; then
|
||||
device="hdb "
|
||||
else
|
||||
@ -433,6 +446,8 @@ fi
|
||||
if [ x$boot = xcd ]; then
|
||||
if [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = arm64-efi ] || [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = arm-efi ]; then
|
||||
device="device virtio-blk-device,drive=cd0 -drive if=none,id=cd0,media=cdrom,file="
|
||||
elif [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = loongarch64-efi ]; then
|
||||
device="device virtio-blk-pci,drive=grubcd -drive if=none,id=grubcd,media=cdrom,file="
|
||||
elif [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = powerpc-ieee1275 ] && [ x$pseries != xy ] ; then
|
||||
device="-drive if=ide,media=cdrom,file="
|
||||
else
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user