ed5979
From badfb1290c8eea8a2e1769b2392c7899d5077698 Mon Sep 17 00:00:00 2001
586cba
From: Miroslav Rezanina <mrezanin@redhat.com>
586cba
Date: Wed, 2 Sep 2020 09:39:41 +0200
586cba
Subject: Enable make check
586cba
586cba
Fixing tests after device disabling and machine types changes and enabling
586cba
make check run during build.
586cba
586cba
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
586cba
---
586cba
Rebase changes (6.1.0):
586cba
- removed unnecessary test changes
586cba
586cba
Rebase changes (6.2.0):
586cba
- new way of disabling bios-table-test
586cba
586cba
Rebase changes (7.0.0):
586cba
- Disable testing virtio-iommu-pci
586cba
- Rename default_bus_bypass_iommu property to default-bus-bypass-iommu
586cba
- Disable qtest-bios-table for aarch64
586cba
- Removed redhat chunks for boot-serial-test.c, cdrom-test.c and cpu-plug-test.c qtests
586cba
- Do not disable boot-order-test, prom-env-test and boot-serial-test qtests
586cba
- Use rhel machine type for new intel hda qtest
586cba
- Remove unnecessary changes in iotest 051
586cba
- Remove changes in bios-tables-test.c and prom-env-test.c qtests
586cba
ed5979
Rebase changes (7.1.0 rc0):
ed5979
- Disable bcm2835-dma-test (added upstream)
ed5979
586cba
Merged patches (6.1.0):
586cba
- 2f129df7d3 redhat: Enable the 'test-block-iothread' test again
ed5979
ed5979
Merged patches (7.1.0 rc0):
ed5979
- 64d736640e RHEL-only: tests/avocado: Switch aarch64 tests from a53 to a57
586cba
---
586cba
 .distro/qemu-kvm.spec.template      | 5 ++---
ed5979
 tests/avocado/replay_kernel.py      | 2 +-
ed5979
 tests/avocado/reverse_debugging.py  | 2 +-
ed5979
 tests/avocado/tcg_plugins.py        | 6 +++---
586cba
 tests/qtest/fuzz-e1000e-test.c      | 2 +-
586cba
 tests/qtest/fuzz-virtio-scsi-test.c | 2 +-
586cba
 tests/qtest/intel-hda-test.c        | 2 +-
586cba
 tests/qtest/libqos/meson.build      | 2 +-
586cba
 tests/qtest/lpc-ich9-test.c         | 2 +-
ed5979
 tests/qtest/meson.build             | 7 +------
586cba
 tests/qtest/usb-hcd-xhci-test.c     | 4 ++++
586cba
 tests/qtest/virtio-net-failover.c   | 1 +
ed5979
 12 files changed, 18 insertions(+), 19 deletions(-)
586cba
ed5979
diff --git a/tests/avocado/replay_kernel.py b/tests/avocado/replay_kernel.py
ed5979
index 00a26e4a0c..fe5ecf238a 100644
ed5979
--- a/tests/avocado/replay_kernel.py
ed5979
+++ b/tests/avocado/replay_kernel.py
ed5979
@@ -147,7 +147,7 @@ def test_aarch64_virt(self):
ed5979
         """
ed5979
         :avocado: tags=arch:aarch64
ed5979
         :avocado: tags=machine:virt
ed5979
-        :avocado: tags=cpu:cortex-a53
ed5979
+        :avocado: tags=cpu:cortex-a57
ed5979
         """
ed5979
         kernel_url = ('https://archives.fedoraproject.org/pub/archive/fedora'
ed5979
                       '/linux/releases/29/Everything/aarch64/os/images/pxeboot'
ed5979
diff --git a/tests/avocado/reverse_debugging.py b/tests/avocado/reverse_debugging.py
ed5979
index d2921e70c3..66d185ed42 100644
ed5979
--- a/tests/avocado/reverse_debugging.py
ed5979
+++ b/tests/avocado/reverse_debugging.py
ed5979
@@ -198,7 +198,7 @@ def test_aarch64_virt(self):
ed5979
         """
ed5979
         :avocado: tags=arch:aarch64
ed5979
         :avocado: tags=machine:virt
ed5979
-        :avocado: tags=cpu:cortex-a53
ed5979
+        :avocado: tags=cpu:cortex-a57
ed5979
         """
ed5979
         kernel_url = ('https://archives.fedoraproject.org/pub/archive/fedora'
ed5979
                       '/linux/releases/29/Everything/aarch64/os/images/pxeboot'
ed5979
diff --git a/tests/avocado/tcg_plugins.py b/tests/avocado/tcg_plugins.py
ed5979
index 642d2e49e3..93b3afd823 100644
ed5979
--- a/tests/avocado/tcg_plugins.py
ed5979
+++ b/tests/avocado/tcg_plugins.py
ed5979
@@ -68,7 +68,7 @@ def test_aarch64_virt_insn(self):
ed5979
         :avocado: tags=accel:tcg
ed5979
         :avocado: tags=arch:aarch64
ed5979
         :avocado: tags=machine:virt
ed5979
-        :avocado: tags=cpu:cortex-a53
ed5979
+        :avocado: tags=cpu:cortex-a57
ed5979
         """
ed5979
         kernel_path = self._grab_aarch64_kernel()
ed5979
         kernel_command_line = (self.KERNEL_COMMON_COMMAND_LINE +
ed5979
@@ -94,7 +94,7 @@ def test_aarch64_virt_insn_icount(self):
ed5979
         :avocado: tags=accel:tcg
ed5979
         :avocado: tags=arch:aarch64
ed5979
         :avocado: tags=machine:virt
ed5979
-        :avocado: tags=cpu:cortex-a53
ed5979
+        :avocado: tags=cpu:cortex-a57
ed5979
         """
ed5979
         kernel_path = self._grab_aarch64_kernel()
ed5979
         kernel_command_line = (self.KERNEL_COMMON_COMMAND_LINE +
ed5979
@@ -120,7 +120,7 @@ def test_aarch64_virt_mem_icount(self):
ed5979
         :avocado: tags=accel:tcg
ed5979
         :avocado: tags=arch:aarch64
ed5979
         :avocado: tags=machine:virt
ed5979
-        :avocado: tags=cpu:cortex-a53
ed5979
+        :avocado: tags=cpu:cortex-a57
ed5979
         """
ed5979
         kernel_path = self._grab_aarch64_kernel()
ed5979
         kernel_command_line = (self.KERNEL_COMMON_COMMAND_LINE +
586cba
diff --git a/tests/qtest/fuzz-e1000e-test.c b/tests/qtest/fuzz-e1000e-test.c
ed5979
index 5052883fb6..b5286f4b12 100644
586cba
--- a/tests/qtest/fuzz-e1000e-test.c
586cba
+++ b/tests/qtest/fuzz-e1000e-test.c
586cba
@@ -17,7 +17,7 @@ static void test_lp1879531_eth_get_rss_ex_dst_addr(void)
586cba
 {
586cba
     QTestState *s;
586cba
 
586cba
-    s = qtest_init("-nographic -monitor none -serial none -M pc-q35-5.0");
586cba
+    s = qtest_init("-nographic -monitor none -serial none -M pc-q35-rhel8.4.0");
586cba
 
586cba
     qtest_outl(s, 0xcf8, 0x80001010);
586cba
     qtest_outl(s, 0xcfc, 0xe1020000);
586cba
diff --git a/tests/qtest/fuzz-virtio-scsi-test.c b/tests/qtest/fuzz-virtio-scsi-test.c
ed5979
index e37b48b2cc..88647da054 100644
586cba
--- a/tests/qtest/fuzz-virtio-scsi-test.c
586cba
+++ b/tests/qtest/fuzz-virtio-scsi-test.c
586cba
@@ -19,7 +19,7 @@ static void test_mmio_oob_from_memory_region_cache(void)
586cba
 {
586cba
     QTestState *s;
586cba
 
ed5979
-    s = qtest_init("-M pc-q35-5.2 -m 512M "
ed5979
+    s = qtest_init("-M pc-q35-rhel8.4.0 -m 512M "
586cba
                    "-device virtio-scsi,num_queues=8,addr=03.0 ");
586cba
 
586cba
     qtest_outl(s, 0xcf8, 0x80001811);
586cba
diff --git a/tests/qtest/intel-hda-test.c b/tests/qtest/intel-hda-test.c
ed5979
index d4a8db6fd6..1a796ec15a 100644
586cba
--- a/tests/qtest/intel-hda-test.c
586cba
+++ b/tests/qtest/intel-hda-test.c
586cba
@@ -38,7 +38,7 @@ static void test_issue542_ich6(void)
586cba
 {
586cba
     QTestState *s;
586cba
 
586cba
-    s = qtest_init("-nographic -nodefaults -M pc-q35-6.2 "
586cba
+    s = qtest_init("-nographic -nodefaults -M pc-q35-rhel9.0.0 "
586cba
                    "-device intel-hda,id=" HDA_ID CODEC_DEVICES);
586cba
 
586cba
     qtest_outl(s, 0xcf8, 0x80000804);
586cba
diff --git a/tests/qtest/libqos/meson.build b/tests/qtest/libqos/meson.build
ed5979
index 32f028872c..1e78a1a055 100644
586cba
--- a/tests/qtest/libqos/meson.build
586cba
+++ b/tests/qtest/libqos/meson.build
ed5979
@@ -43,7 +43,7 @@ libqos_srcs = files(
586cba
         'virtio-rng.c',
586cba
         'virtio-scsi.c',
586cba
         'virtio-serial.c',
586cba
-        'virtio-iommu.c',
586cba
+#        'virtio-iommu.c',
ed5979
         'virtio-gpio.c',
ed5979
         'generic-pcihost.c',
586cba
 
586cba
diff --git a/tests/qtest/lpc-ich9-test.c b/tests/qtest/lpc-ich9-test.c
ed5979
index 8ac95b89f7..cd2102555c 100644
586cba
--- a/tests/qtest/lpc-ich9-test.c
586cba
+++ b/tests/qtest/lpc-ich9-test.c
586cba
@@ -15,7 +15,7 @@ static void test_lp1878642_pci_bus_get_irq_level_assert(void)
586cba
 {
586cba
     QTestState *s;
586cba
 
586cba
-    s = qtest_init("-M pc-q35-5.0 "
586cba
+    s = qtest_init("-M pc-q35-rhel8.4.0 "
586cba
                    "-nographic -monitor none -serial none");
586cba
 
586cba
     qtest_outl(s, 0xcf8, 0x8000f840); /* PMBASE */
586cba
diff --git a/tests/qtest/meson.build b/tests/qtest/meson.build
ed5979
index c07a5b1a5f..9df3f9f8b9 100644
586cba
--- a/tests/qtest/meson.build
586cba
+++ b/tests/qtest/meson.build
ed5979
@@ -82,7 +82,6 @@ qtests_i386 = \
586cba
    config_all_devices.has_key('CONFIG_Q35') and                                             \
586cba
    config_all_devices.has_key('CONFIG_VIRTIO_PCI') and                                      \
586cba
    slirp.found() ? ['virtio-net-failover'] : []) +                                          \
586cba
-  (unpack_edk2_blobs ? ['bios-tables-test'] : []) +                                         \
586cba
   qtests_pci +                                                                              \
ed5979
   qtests_cxl +                                                                              \
586cba
   ['fdc-test',
ed5979
@@ -96,7 +95,6 @@ qtests_i386 = \
586cba
    'drive_del-test',
586cba
    'tco-test',
586cba
    'cpu-plug-test',
586cba
-   'q35-test',
586cba
    'vmgenid-test',
586cba
    'migration-test',
586cba
    'test-x86-cpuid-compat',
ed5979
@@ -209,15 +207,13 @@ qtests_arm = \
586cba
 
586cba
 # TODO: once aarch64 TCG is fixed on ARM 32 bit host, make bios-tables-test unconditional
586cba
 qtests_aarch64 = \
586cba
-  (cpu != 'arm' and unpack_edk2_blobs ? ['bios-tables-test'] : []) +                            \
586cba
   (config_all_devices.has_key('CONFIG_TPM_TIS_SYSBUS') ? ['tpm-tis-device-test'] : []) +        \
586cba
   (config_all_devices.has_key('CONFIG_TPM_TIS_SYSBUS') ? ['tpm-tis-device-swtpm-test'] : []) +  \
586cba
   (config_all_devices.has_key('CONFIG_XLNX_ZYNQMP_ARM') ? ['xlnx-can-test', 'fuzz-xlnx-dp-test'] : []) + \
ed5979
   ['arm-cpu-features',
ed5979
    'numa-test',
ed5979
    'boot-serial-test',
ed5979
-   'migration-test',
ed5979
-   'bcm2835-dma-test']
ed5979
+   'migration-test']
ed5979
 
ed5979
 qtests_s390x = \
ed5979
   (slirp.found() ? ['pxe-test', 'test-netfilter'] : []) +                 \
ed5979
@@ -225,7 +221,6 @@ qtests_s390x = \
586cba
   (config_host.has_key('CONFIG_POSIX') ? ['test-filter-redirector'] : []) +                     \
586cba
   ['boot-serial-test',
586cba
    'drive_del-test',
586cba
-   'device-plug-test',
586cba
    'virtio-ccw-test',
586cba
    'cpu-plug-test',
586cba
    'migration-test']
586cba
diff --git a/tests/qtest/usb-hcd-xhci-test.c b/tests/qtest/usb-hcd-xhci-test.c
586cba
index 10ef9d2a91..3855873050 100644
586cba
--- a/tests/qtest/usb-hcd-xhci-test.c
586cba
+++ b/tests/qtest/usb-hcd-xhci-test.c
586cba
@@ -21,6 +21,7 @@ static void test_xhci_hotplug(void)
586cba
     usb_test_hotplug(global_qtest, "xhci", "1", NULL);
586cba
 }
586cba
 
586cba
+#if 0 /* Disabled for Red Hat Enterprise Linux */
586cba
 static void test_usb_uas_hotplug(void)
586cba
 {
586cba
     QTestState *qts = global_qtest;
586cba
@@ -36,6 +37,7 @@ static void test_usb_uas_hotplug(void)
586cba
     qtest_qmp_device_del(qts, "scsihd");
586cba
     qtest_qmp_device_del(qts, "uas");
586cba
 }
586cba
+#endif
586cba
 
586cba
 static void test_usb_ccid_hotplug(void)
586cba
 {
586cba
@@ -56,7 +58,9 @@ int main(int argc, char **argv)
586cba
 
586cba
     qtest_add_func("/xhci/pci/init", test_xhci_init);
586cba
     qtest_add_func("/xhci/pci/hotplug", test_xhci_hotplug);
586cba
+#if 0 /* Disabled for Red Hat Enterprise Linux */
586cba
     qtest_add_func("/xhci/pci/hotplug/usb-uas", test_usb_uas_hotplug);
586cba
+#endif
586cba
     qtest_add_func("/xhci/pci/hotplug/usb-ccid", test_usb_ccid_hotplug);
586cba
 
586cba
     qtest_start("-device nec-usb-xhci,id=xhci"
586cba
diff --git a/tests/qtest/virtio-net-failover.c b/tests/qtest/virtio-net-failover.c
ed5979
index 4a809590bf..1bf3fa641c 100644
586cba
--- a/tests/qtest/virtio-net-failover.c
586cba
+++ b/tests/qtest/virtio-net-failover.c
586cba
@@ -25,6 +25,7 @@
586cba
 #define PCI_SEL_BASE            0x0010
586cba
 
586cba
 #define BASE_MACHINE "-M q35 -nodefaults " \
586cba
+    "-global ICH9-LPC.acpi-pci-hotplug-with-bridge-support=on " \
586cba
     "-device pcie-root-port,id=root0,addr=0x1,bus=pcie.0,chassis=1 " \
586cba
     "-device pcie-root-port,id=root1,addr=0x2,bus=pcie.0,chassis=2 "
586cba
 
586cba
-- 
586cba
2.31.1
586cba