[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 11/12] tests/qtest: Don't run cdrom boot tests if no accelerator i
|
From: |
Peter Maydell |
|
Subject: |
[PULL 11/12] tests/qtest: Don't run cdrom boot tests if no accelerator is present |
|
Date: |
Fri, 12 May 2023 16:34:22 +0100 |
From: Fabiano Rosas <farosas@suse.de>
On a build configured with: --disable-tcg --enable-xen it is possible
to produce a QEMU binary with no TCG nor KVM support. Skip the cdrom
boot tests if that's the case.
Fixes: 0c1ae3ff9d ("tests/qtest: Fix tests when no KVM or TCG are present")
Signed-off-by: Fabiano Rosas <farosas@suse.de>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Message-id: 20230508181611.2621-4-farosas@suse.de
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
tests/qtest/cdrom-test.c | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/tests/qtest/cdrom-test.c b/tests/qtest/cdrom-test.c
index 26a2400181a..31d3bacd8c3 100644
--- a/tests/qtest/cdrom-test.c
+++ b/tests/qtest/cdrom-test.c
@@ -130,6 +130,11 @@ static void test_cdboot(gconstpointer data)
static void add_x86_tests(void)
{
+ if (!qtest_has_accel("tcg") && !qtest_has_accel("kvm")) {
+ g_test_skip("No KVM or TCG accelerator available, skipping boot
tests");
+ return;
+ }
+
qtest_add_data_func("cdrom/boot/default", "-cdrom ", test_cdboot);
qtest_add_data_func("cdrom/boot/virtio-scsi",
"-device virtio-scsi -device scsi-cd,drive=cdr "
@@ -176,6 +181,11 @@ static void add_x86_tests(void)
static void add_s390x_tests(void)
{
+ if (!qtest_has_accel("tcg") && !qtest_has_accel("kvm")) {
+ g_test_skip("No KVM or TCG accelerator available, skipping boot
tests");
+ return;
+ }
+
qtest_add_data_func("cdrom/boot/default", "-cdrom ", test_cdboot);
qtest_add_data_func("cdrom/boot/virtio-scsi",
"-device virtio-scsi -device scsi-cd,drive=cdr "
--
2.34.1
- [PULL 00/12] target-arm queue, Peter Maydell, 2023/05/12
- [PULL 01/12] target/arm: Move translate-a32.h, arm_ldst.h, sve_ldst_internal.h to tcg/, Peter Maydell, 2023/05/12
- [PULL 04/12] target/arm: Fix handling of SW and NSW bits for stage 2 walks, Peter Maydell, 2023/05/12
- [PULL 07/12] docs: Remove unused weirdly-named cross-reference targets, Peter Maydell, 2023/05/12
- [PULL 11/12] tests/qtest: Don't run cdrom boot tests if no accelerator is present,
Peter Maydell <=
- [PULL 02/12] target/arm: Move helper-{a64,mve,sme,sve}.h to tcg/, Peter Maydell, 2023/05/12
- [PULL 03/12] target/arm: Don't allow stage 2 page table walks to downgrade to NS, Peter Maydell, 2023/05/12
- [PULL 05/12] MAINTAINERS: Update Akihiko Odaki's email address, Peter Maydell, 2023/05/12
- [PULL 08/12] hw/mips/malta: Fix minor dead code issue, Peter Maydell, 2023/05/12
- [PULL 09/12] target/arm: Select SEMIHOSTING when using TCG, Peter Maydell, 2023/05/12
- [PULL 06/12] ui: Fix pixel colour channel order for PNG screenshots, Peter Maydell, 2023/05/12
- [PULL 10/12] target/arm: Select CONFIG_ARM_V7M when TCG is enabled, Peter Maydell, 2023/05/12
- [PULL 12/12] target/arm: Correct AArch64.S2MinTxSZ 32-bit EL1 input size check, Peter Maydell, 2023/05/12
- Re: [PULL 00/12] target-arm queue, Richard Henderson, 2023/05/13