e73cc6
From: Jiri Denemark <jdenemar@redhat.com>
e73cc6
Date: Wed, 12 Nov 2014 16:49:59 +0100
e73cc6
Subject: [PATCH] qemu: Don't try to parse -help for new QEMU
e73cc6
e73cc6
Since QEMU 1.2.0, we switched to QMP probing instead of parsing -help
e73cc6
(and other commands, such as -cpu ?) output. However, if QMP probing
e73cc6
failed, we still tried starting QEMU with various options and parsing
e73cc6
the output, which was guaranteed to fail because the output changed.
e73cc6
Let's just refuse parsing -help for QEMU >= 1.2.0.
e73cc6
e73cc6
https://bugzilla.redhat.com/show_bug.cgi?id=1160318
e73cc6
Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
e73cc6
(cherry picked from commit ae3e29e6e7a9a208732f22721e735d238b2aa8cb)
e73cc6
---
e73cc6
 src/qemu/qemu_capabilities.c             |  10 ++
e73cc6
 tests/qemuhelpdata/qemu-kvm-1.2.0-device | 238 ------------------------------
e73cc6
 tests/qemuhelptest.c                     | 246 ++-----------------------------
e73cc6
 3 files changed, 24 insertions(+), 470 deletions(-)
e73cc6
 delete mode 100644 tests/qemuhelpdata/qemu-kvm-1.2.0-device
e73cc6
e73cc6
diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c
e73cc6
index b6c0f1b..6eb2955 100644
e73cc6
--- a/src/qemu/qemu_capabilities.c
e73cc6
+++ b/src/qemu/qemu_capabilities.c
e73cc6
@@ -1383,6 +1383,16 @@ int virQEMUCapsParseHelpStr(const char *qemu,
e73cc6
 
e73cc6
     *version = (major * 1000 * 1000) + (minor * 1000) + micro;
e73cc6
 
e73cc6
+    /* Refuse to parse -help output for QEMU releases >= 1.2.0 that should be
e73cc6
+     * using QMP probing.
e73cc6
+     */
e73cc6
+    if (*version >= 1002000) {
e73cc6
+        virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
e73cc6
+                       _("QEMU %u.%u.%u is too new for help parsing"),
e73cc6
+                       major, minor, micro);
e73cc6
+        goto cleanup;
e73cc6
+    }
e73cc6
+
e73cc6
     if (virQEMUCapsComputeCmdFlags(help, *version, *is_kvm, *kvm_version,
e73cc6
                                    qemuCaps, check_yajl) < 0)
e73cc6
         goto cleanup;
e73cc6
diff --git a/tests/qemuhelpdata/qemu-kvm-1.2.0-device b/tests/qemuhelpdata/qemu-kvm-1.2.0-device
e73cc6
deleted file mode 100644
e73cc6
index f4bfd68..0000000
e73cc6
--- a/tests/qemuhelpdata/qemu-kvm-1.2.0-device
e73cc6
+++ /dev/null
e73cc6
@@ -1,238 +0,0 @@
e73cc6
-name "VGA", bus PCI
e73cc6
-name "usb-storage", bus usb-bus
e73cc6
-name "scsi-hd", bus SCSI, desc "virtual SCSI disk"
e73cc6
-name "i82559a", bus PCI, desc "Intel i82559A Ethernet"
e73cc6
-name "i82559b", bus PCI, desc "Intel i82559B Ethernet"
e73cc6
-name "i82559c", bus PCI, desc "Intel i82559C Ethernet"
e73cc6
-name "esp", bus System
e73cc6
-name "sysbus-ohci", bus System, desc "OHCI USB Controller"
e73cc6
-name "virtio-blk-pci", bus PCI, alias "virtio-blk"
e73cc6
-name "usb-uas", bus usb-bus
e73cc6
-name "qxl-vga", bus PCI, desc "Spice QXL GPU (primary, vga compatible)"
e73cc6
-name "ide-drive", bus IDE, desc "virtual IDE disk or CD-ROM (legacy)"
e73cc6
-name "x3130-upstream", bus PCI, desc "TI X3130 Upstream Port of PCI Express Switch"
e73cc6
-name "cirrus-vga", bus PCI, desc "Cirrus CLGD 54xx VGA"
e73cc6
-name "ide-hd", bus IDE, desc "virtual IDE disk"
e73cc6
-name "ES1370", bus PCI, desc "ENSONIQ AudioPCI ES1370"
e73cc6
-name "ioh3420", bus PCI, desc "Intel IOH device id 3420 PCIE Root Port"
e73cc6
-name "sga", bus ISA, desc "Serial Graphics Adapter"
e73cc6
-name "scsi-block", bus SCSI, desc "SCSI block device passthrough"
e73cc6
-name "usb-serial", bus usb-bus
e73cc6
-name "pc-sysfw", bus System, desc "PC System Firmware"
e73cc6
-name "usb-mouse", bus usb-bus
e73cc6
-name "usb-net", bus usb-bus
e73cc6
-name "usb-hub", bus usb-bus
e73cc6
-name "ccid-card-emulated", bus ccid-bus, desc "emulated smartcard"
e73cc6
-name "ne2k_isa", bus ISA
e73cc6
-name "pci-assign", bus PCI
e73cc6
-name "scsi-generic", bus SCSI, desc "pass through generic scsi device (/dev/sg*)"
e73cc6
-name "pcnet", bus PCI
e73cc6
-name "lsi53c895a", bus PCI, alias "lsi"
e73cc6
-name "scsi-disk", bus SCSI, desc "virtual SCSI disk or CD-ROM (legacy)"
e73cc6
-name "hda-micro", bus HDA, desc "HDA Audio Codec, duplex (speaker, microphone)"
e73cc6
-name "pci-ohci", bus PCI, desc "Apple USB Controller"
e73cc6
-name "nec-usb-xhci", bus PCI
e73cc6
-name "xio3130-downstream", bus PCI, desc "TI X3130 Downstream Port of PCI Express Switch"
e73cc6
-name "virtserialport", bus virtio-serial-bus
e73cc6
-name "usb-redir", bus usb-bus
e73cc6
-name "usb-braille", bus usb-bus
e73cc6
-name "scsi-cd", bus SCSI, desc "virtual SCSI CD-ROM"
e73cc6
-name "usb-wacom-tablet", bus usb-bus, desc "QEMU PenPartner Tablet"
e73cc6
-name "isa-serial", bus ISA
e73cc6
-name "i82550", bus PCI, desc "Intel i82550 Ethernet"
e73cc6
-name "i82551", bus PCI, desc "Intel i82551 Ethernet"
e73cc6
-name "isa-debugcon", bus ISA
e73cc6
-name "ide-cd", bus IDE, desc "virtual IDE CD-ROM"
e73cc6
-name "SUNW,fdtwo", bus System
e73cc6
-name "ich9-usb-uhci2", bus PCI
e73cc6
-name "ich9-usb-uhci3", bus PCI
e73cc6
-name "ich9-usb-uhci1", bus PCI
e73cc6
-name "isa-parallel", bus ISA
e73cc6
-name "virtconsole", bus virtio-serial-bus
e73cc6
-name "ne2k_pci", bus PCI
e73cc6
-name "virtio-serial-pci", bus PCI, alias "virtio-serial"
e73cc6
-name "hda-duplex", bus HDA, desc "HDA Audio Codec, duplex (line-out, line-in)"
e73cc6
-name "intel-hda", bus PCI, desc "Intel HD Audio Controller"
e73cc6
-name "megasas", bus PCI, desc "LSI MegaRAID SAS 1078"
e73cc6
-name "i82559er", bus PCI, desc "Intel i82559ER Ethernet"
e73cc6
-name "hda-output", bus HDA, desc "HDA Audio Codec, output-only (line-out)"
e73cc6
-name "i82562", bus PCI, desc "Intel i82562 Ethernet"
e73cc6
-name "sysbus-ahci", bus System
e73cc6
-name "usb-ccid", bus usb-bus, desc "CCID Rev 1.1 smartcard reader"
e73cc6
-name "ivshmem", bus PCI
e73cc6
-name "AC97", bus PCI, desc "Intel 82801AA AC97 Audio"
e73cc6
-name "e1000", bus PCI, desc "Intel Gigabit Ethernet"
e73cc6
-name "sysbus-fdc", bus System
e73cc6
-name "usb-bt-dongle", bus usb-bus
e73cc6
-name "usb-tablet", bus usb-bus
e73cc6
-name "isa-vga", bus ISA
e73cc6
-name "usb-kbd", bus usb-bus
e73cc6
-name "isa-applesmc", bus ISA
e73cc6
-name "rtl8139", bus PCI
e73cc6
-name "qxl", bus PCI, desc "Spice QXL GPU (secondary)"
e73cc6
-name "i82557a", bus PCI, desc "Intel i82557A Ethernet"
e73cc6
-name "i82557c", bus PCI, desc "Intel i82557C Ethernet"
e73cc6
-name "usb-audio", bus usb-bus
e73cc6
-name "ib700", bus ISA
e73cc6
-name "piix3-usb-uhci", bus PCI
e73cc6
-name "i82557b", bus PCI, desc "Intel i82557B Ethernet"
e73cc6
-name "piix4-usb-uhci", bus PCI
e73cc6
-name "ccid-card-passthru", bus ccid-bus, desc "passthrough smartcard"
e73cc6
-name "i82801", bus PCI, desc "Intel i82801 Ethernet"
e73cc6
-name "smbus-eeprom", bus i2c-bus
e73cc6
-name "vmware-svga", bus PCI
e73cc6
-name "dc390", bus PCI, desc "Tekram DC-390 SCSI adapter"
e73cc6
-name "isa-cirrus-vga", bus ISA
e73cc6
-name "sb16", bus ISA, desc "Creative Sound Blaster 16"
e73cc6
-name "am53c974", bus PCI, desc "AMD Am53c974 PCscsi-PCI SCSI adapter"
e73cc6
-name "pci-bridge", bus PCI, desc "Standard PCI Bridge"
e73cc6
-name "i82558a", bus PCI, desc "Intel i82558A Ethernet"
e73cc6
-name "i82558b", bus PCI, desc "Intel i82558B Ethernet"
e73cc6
-name "virtio-net-pci", bus PCI, alias "virtio-net"
e73cc6
-name "virtio-balloon-pci", bus PCI, alias "virtio-balloon"
e73cc6
-name "ich9-usb-ehci1", bus PCI
e73cc6
-name "isa-ide", bus ISA
e73cc6
-name "usb-host", bus usb-bus
e73cc6
-name "ich9-ahci", bus PCI, alias "ahci"
e73cc6
-name "vt82c686b-usb-uhci", bus PCI
e73cc6
-name "usb-ehci", bus PCI
e73cc6
-name "testdev", bus ISA
e73cc6
-name "i6300esb", bus PCI
e73cc6
-name "virtio-scsi-pci", bus PCI
e73cc6
-pci-assign.host=pci-host-devaddr
e73cc6
-pci-assign.prefer_msi=on/off
e73cc6
-pci-assign.share_intx=on/off
e73cc6
-pci-assign.bootindex=int32
e73cc6
-pci-assign.configfd=string
e73cc6
-pci-assign.addr=pci-devfn
e73cc6
-pci-assign.romfile=string
e73cc6
-pci-assign.rombar=uint32
e73cc6
-pci-assign.multifunction=on/off
e73cc6
-pci-assign.command_serr_enable=on/off
e73cc6
-virtio-blk-pci.class=hex32
e73cc6
-virtio-blk-pci.drive=drive
e73cc6
-virtio-blk-pci.logical_block_size=blocksize
e73cc6
-virtio-blk-pci.physical_block_size=blocksize
e73cc6
-virtio-blk-pci.min_io_size=uint16
e73cc6
-virtio-blk-pci.opt_io_size=uint32
e73cc6
-virtio-blk-pci.bootindex=int32
e73cc6
-virtio-blk-pci.discard_granularity=uint32
e73cc6
-virtio-blk-pci.cyls=uint32
e73cc6
-virtio-blk-pci.heads=uint32
e73cc6
-virtio-blk-pci.secs=uint32
e73cc6
-virtio-blk-pci.serial=string
e73cc6
-virtio-blk-pci.scsi=on/off
e73cc6
-virtio-blk-pci.config-wce=on/off
e73cc6
-virtio-blk-pci.ioeventfd=on/off
e73cc6
-virtio-blk-pci.vectors=uint32
e73cc6
-virtio-blk-pci.indirect_desc=on/off
e73cc6
-virtio-blk-pci.event_idx=on/off
e73cc6
-virtio-blk-pci.config-wce=on/off
e73cc6
-virtio-blk-pci.addr=pci-devfn
e73cc6
-virtio-blk-pci.romfile=string
e73cc6
-virtio-blk-pci.rombar=uint32
e73cc6
-virtio-blk-pci.multifunction=on/off
e73cc6
-virtio-blk-pci.command_serr_enable=on/off
e73cc6
-virtio-net-pci.ioeventfd=on/off
e73cc6
-virtio-net-pci.vectors=uint32
e73cc6
-virtio-net-pci.indirect_desc=on/off
e73cc6
-virtio-net-pci.event_idx=on/off
e73cc6
-virtio-net-pci.csum=on/off
e73cc6
-virtio-net-pci.guest_csum=on/off
e73cc6
-virtio-net-pci.gso=on/off
e73cc6
-virtio-net-pci.guest_tso4=on/off
e73cc6
-virtio-net-pci.guest_tso6=on/off
e73cc6
-virtio-net-pci.guest_ecn=on/off
e73cc6
-virtio-net-pci.guest_ufo=on/off
e73cc6
-virtio-net-pci.host_tso4=on/off
e73cc6
-virtio-net-pci.host_tso6=on/off
e73cc6
-virtio-net-pci.host_ecn=on/off
e73cc6
-virtio-net-pci.host_ufo=on/off
e73cc6
-virtio-net-pci.mrg_rxbuf=on/off
e73cc6
-virtio-net-pci.status=on/off
e73cc6
-virtio-net-pci.ctrl_vq=on/off
e73cc6
-virtio-net-pci.ctrl_rx=on/off
e73cc6
-virtio-net-pci.ctrl_vlan=on/off
e73cc6
-virtio-net-pci.ctrl_rx_extra=on/off
e73cc6
-virtio-net-pci.mac=macaddr
e73cc6
-virtio-net-pci.vlan=vlan
e73cc6
-virtio-net-pci.netdev=netdev
e73cc6
-virtio-net-pci.bootindex=int32
e73cc6
-virtio-net-pci.x-txtimer=uint32
e73cc6
-virtio-net-pci.x-txburst=int32
e73cc6
-virtio-net-pci.tx=string
e73cc6
-virtio-net-pci.addr=pci-devfn
e73cc6
-virtio-net-pci.romfile=string
e73cc6
-virtio-net-pci.rombar=uint32
e73cc6
-virtio-net-pci.multifunction=on/off
e73cc6
-virtio-net-pci.command_serr_enable=on/off
e73cc6
-scsi-disk.drive=drive
e73cc6
-scsi-disk.logical_block_size=blocksize
e73cc6
-scsi-disk.physical_block_size=blocksize
e73cc6
-scsi-disk.min_io_size=uint16
e73cc6
-scsi-disk.opt_io_size=uint32
e73cc6
-scsi-disk.bootindex=int32
e73cc6
-scsi-disk.discard_granularity=uint32
e73cc6
-scsi-disk.ver=string
e73cc6
-scsi-disk.serial=string
e73cc6
-scsi-disk.vendor=string
e73cc6
-scsi-disk.product=string
e73cc6
-scsi-disk.removable=on/off
e73cc6
-scsi-disk.dpofua=on/off
e73cc6
-scsi-disk.wwn=hex64
e73cc6
-scsi-disk.channel=uint32
e73cc6
-scsi-disk.scsi-id=uint32
e73cc6
-scsi-disk.lun=uint32
e73cc6
-PIIX4_PM.smb_io_base=uint32
e73cc6
-PIIX4_PM.disable_s3=uint8
e73cc6
-PIIX4_PM.disable_s4=uint8
e73cc6
-PIIX4_PM.s4_val=uint8
e73cc6
-PIIX4_PM.addr=pci-devfn
e73cc6
-PIIX4_PM.romfile=string
e73cc6
-PIIX4_PM.rombar=uint32
e73cc6
-PIIX4_PM.multifunction=on/off
e73cc6
-PIIX4_PM.command_serr_enable=on/off
e73cc6
-usb-redir.chardev=chr
e73cc6
-usb-redir.debug=uint8
e73cc6
-usb-redir.filter=string
e73cc6
-usb-redir.bootindex=int32
e73cc6
-usb-redir.port=string
e73cc6
-usb-redir.full-path=on/off
e73cc6
-ide-drive.drive=drive
e73cc6
-ide-drive.logical_block_size=blocksize
e73cc6
-ide-drive.physical_block_size=blocksize
e73cc6
-ide-drive.min_io_size=uint16
e73cc6
-ide-drive.opt_io_size=uint32
e73cc6
-ide-drive.bootindex=int32
e73cc6
-ide-drive.discard_granularity=uint32
e73cc6
-ide-drive.ver=string
e73cc6
-ide-drive.wwn=hex64
e73cc6
-ide-drive.serial=string
e73cc6
-ide-drive.model=string
e73cc6
-ide-drive.unit=uint32
e73cc6
-usb-host.hostbus=uint32
e73cc6
-usb-host.hostaddr=uint32
e73cc6
-usb-host.hostport=string
e73cc6
-usb-host.vendorid=hex32
e73cc6
-usb-host.productid=hex32
e73cc6
-usb-host.isobufs=uint32
e73cc6
-usb-host.bootindex=int32
e73cc6
-usb-host.pipeline=on/off
e73cc6
-usb-host.port=string
e73cc6
-usb-host.full-path=on/off
e73cc6
-scsi-generic.drive=drive
e73cc6
-scsi-generic.bootindex=int32
e73cc6
-scsi-generic.channel=uint32
e73cc6
-scsi-generic.scsi-id=uint32
e73cc6
-scsi-generic.lun=uint32
e73cc6
-usb-storage.drive=drive
e73cc6
-usb-storage.logical_block_size=blocksize
e73cc6
-usb-storage.physical_block_size=blocksize
e73cc6
-usb-storage.min_io_size=uint16
e73cc6
-usb-storage.opt_io_size=uint32
e73cc6
-usb-storage.bootindex=int32
e73cc6
-usb-storage.discard_granularity=uint32
e73cc6
-usb-storage.serial=string
e73cc6
-usb-storage.removable=on/off
e73cc6
-usb-storage.port=string
e73cc6
-usb-storage.full-path=on/off
e73cc6
diff --git a/tests/qemuhelptest.c b/tests/qemuhelptest.c
e73cc6
index 7e62a50..0c68367 100644
e73cc6
--- a/tests/qemuhelptest.c
e73cc6
+++ b/tests/qemuhelptest.c
e73cc6
@@ -19,6 +19,7 @@ struct testInfo {
e73cc6
     unsigned int version;
e73cc6
     bool is_kvm;
e73cc6
     unsigned int kvm_version;
e73cc6
+    int error;
e73cc6
 };
e73cc6
 
e73cc6
 static void printMismatchedFlags(virQEMUCapsPtr got,
e73cc6
@@ -58,8 +59,11 @@ static int testHelpStrParsing(const void *data)
e73cc6
         goto cleanup;
e73cc6
 
e73cc6
     if (virQEMUCapsParseHelpStr("QEMU", help, flags,
e73cc6
-                                &version, &is_kvm, &kvm_version, false) == -1)
e73cc6
+                                &version, &is_kvm, &kvm_version, false) == -1) {
e73cc6
+        if (info->error && virGetLastError()->code == info->error)
e73cc6
+            ret = 0;
e73cc6
         goto cleanup;
e73cc6
+    }
e73cc6
 
e73cc6
 # ifndef WITH_YAJL
e73cc6
     if (virQEMUCapsGet(info->flags, QEMU_CAPS_MONITOR_JSON))
e73cc6
@@ -132,10 +136,10 @@ mymain(void)
e73cc6
 {
e73cc6
     int ret = 0;
e73cc6
 
e73cc6
-# define DO_TEST(name, version, is_kvm, kvm_version, ...)                   \
e73cc6
+# define DO_TEST_FULL(name, version, is_kvm, kvm_version, error, ...)       \
e73cc6
     do {                                                                    \
e73cc6
         struct testInfo info = {                                            \
e73cc6
-            name, NULL, version, is_kvm, kvm_version                        \
e73cc6
+            name, NULL, version, is_kvm, kvm_version, error                 \
e73cc6
         };                                                                  \
e73cc6
         if (!(info.flags = virQEMUCapsNew()))                               \
e73cc6
             return EXIT_FAILURE;                                            \
e73cc6
@@ -146,6 +150,9 @@ mymain(void)
e73cc6
         virObjectUnref(info.flags);                                         \
e73cc6
     } while (0)
e73cc6
 
e73cc6
+# define DO_TEST(name, version, is_kvm, kvm_version, ...) \
e73cc6
+    DO_TEST_FULL(name, version, is_kvm, kvm_version, VIR_ERR_OK, __VA_ARGS__)
e73cc6
+
e73cc6
     DO_TEST("qemu-0.9.1", 9001, 0, 0,
e73cc6
             QEMU_CAPS_KQEMU,
e73cc6
             QEMU_CAPS_VNC_COLON,
e73cc6
@@ -849,235 +856,10 @@ mymain(void)
e73cc6
             QEMU_CAPS_OBJECT_USB_AUDIO,
e73cc6
             QEMU_CAPS_SPLASH_TIMEOUT,
e73cc6
             QEMU_CAPS_DEVICE_IVSHMEM);
e73cc6
-    DO_TEST("qemu-1.2.0", 1002000, 0, 0,
e73cc6
-            QEMU_CAPS_VNC_COLON,
e73cc6
-            QEMU_CAPS_NO_REBOOT,
e73cc6
-            QEMU_CAPS_DRIVE,
e73cc6
-            QEMU_CAPS_NAME,
e73cc6
-            QEMU_CAPS_UUID,
e73cc6
-            QEMU_CAPS_MIGRATE_QEMU_TCP,
e73cc6
-            QEMU_CAPS_MIGRATE_QEMU_EXEC,
e73cc6
-            QEMU_CAPS_DRIVE_CACHE_V2,
e73cc6
-            QEMU_CAPS_DRIVE_CACHE_UNSAFE,
e73cc6
-            QEMU_CAPS_DRIVE_FORMAT,
e73cc6
-            QEMU_CAPS_DRIVE_SERIAL,
e73cc6
-            QEMU_CAPS_XEN_DOMID,
e73cc6
-            QEMU_CAPS_DRIVE_READONLY,
e73cc6
-            QEMU_CAPS_VGA,
e73cc6
-            QEMU_CAPS_0_10,
e73cc6
-            QEMU_CAPS_MEM_PATH,
e73cc6
-            QEMU_CAPS_SDL,
e73cc6
-            QEMU_CAPS_MIGRATE_QEMU_UNIX,
e73cc6
-            QEMU_CAPS_CHARDEV,
e73cc6
-            QEMU_CAPS_ENABLE_KVM,
e73cc6
-            QEMU_CAPS_MONITOR_JSON,
e73cc6
-            QEMU_CAPS_BALLOON,
e73cc6
-            QEMU_CAPS_DEVICE,
e73cc6
-            QEMU_CAPS_SMP_TOPOLOGY,
e73cc6
-            QEMU_CAPS_NETDEV,
e73cc6
-            QEMU_CAPS_RTC,
e73cc6
-            QEMU_CAPS_VHOST_NET,
e73cc6
-            QEMU_CAPS_NO_HPET,
e73cc6
-            QEMU_CAPS_NODEFCONFIG,
e73cc6
-            QEMU_CAPS_BOOT_MENU,
e73cc6
-            QEMU_CAPS_FSDEV,
e73cc6
-            QEMU_CAPS_NAME_PROCESS,
e73cc6
-            QEMU_CAPS_SMBIOS_TYPE,
e73cc6
-            QEMU_CAPS_VGA_QXL,
e73cc6
-            QEMU_CAPS_SPICE,
e73cc6
-            QEMU_CAPS_VGA_NONE,
e73cc6
-            QEMU_CAPS_MIGRATE_QEMU_FD,
e73cc6
-            QEMU_CAPS_BOOTINDEX,
e73cc6
-            QEMU_CAPS_HDA_DUPLEX,
e73cc6
-            QEMU_CAPS_DRIVE_AIO,
e73cc6
-            QEMU_CAPS_CCID_EMULATED,
e73cc6
-            QEMU_CAPS_CCID_PASSTHRU,
e73cc6
-            QEMU_CAPS_CHARDEV_SPICEVMC,
e73cc6
-            QEMU_CAPS_VIRTIO_TX_ALG,
e73cc6
-            QEMU_CAPS_DEVICE_QXL_VGA,
e73cc6
-            QEMU_CAPS_PCI_MULTIFUNCTION,
e73cc6
-            QEMU_CAPS_VIRTIO_IOEVENTFD,
e73cc6
-            QEMU_CAPS_SGA,
e73cc6
-            QEMU_CAPS_VIRTIO_BLK_EVENT_IDX,
e73cc6
-            QEMU_CAPS_VIRTIO_NET_EVENT_IDX,
e73cc6
-            QEMU_CAPS_DRIVE_CACHE_DIRECTSYNC,
e73cc6
-            QEMU_CAPS_PIIX3_USB_UHCI,
e73cc6
-            QEMU_CAPS_PIIX4_USB_UHCI,
e73cc6
-            QEMU_CAPS_USB_EHCI,
e73cc6
-            QEMU_CAPS_ICH9_USB_EHCI1,
e73cc6
-            QEMU_CAPS_VT82C686B_USB_UHCI,
e73cc6
-            QEMU_CAPS_PCI_OHCI,
e73cc6
-            QEMU_CAPS_USB_REDIR,
e73cc6
-            QEMU_CAPS_USB_HUB,
e73cc6
-            QEMU_CAPS_NO_SHUTDOWN,
e73cc6
-            QEMU_CAPS_PCI_ROMBAR,
e73cc6
-            QEMU_CAPS_ICH9_AHCI,
e73cc6
-            QEMU_CAPS_NO_ACPI,
e73cc6
-            QEMU_CAPS_FSDEV_READONLY,
e73cc6
-            QEMU_CAPS_VIRTIO_BLK_SCSI,
e73cc6
-            QEMU_CAPS_VIRTIO_BLK_SG_IO,
e73cc6
-            QEMU_CAPS_DRIVE_COPY_ON_READ,
e73cc6
-            QEMU_CAPS_CPU_HOST,
e73cc6
-            QEMU_CAPS_FSDEV_WRITEOUT,
e73cc6
-            QEMU_CAPS_DRIVE_IOTUNE,
e73cc6
-            QEMU_CAPS_SCSI_DISK_CHANNEL,
e73cc6
-            QEMU_CAPS_SCSI_BLOCK,
e73cc6
-            QEMU_CAPS_SCSI_CD,
e73cc6
-            QEMU_CAPS_IDE_CD,
e73cc6
-            QEMU_CAPS_NO_USER_CONFIG,
e73cc6
-            QEMU_CAPS_HDA_MICRO,
e73cc6
-            QEMU_CAPS_NEC_USB_XHCI,
e73cc6
-            QEMU_CAPS_NETDEV_BRIDGE,
e73cc6
-            QEMU_CAPS_SCSI_LSI,
e73cc6
-            QEMU_CAPS_VIRTIO_SCSI,
e73cc6
-            QEMU_CAPS_BLOCKIO,
e73cc6
-            QEMU_CAPS_DISABLE_S3,
e73cc6
-            QEMU_CAPS_DISABLE_S4,
e73cc6
-            QEMU_CAPS_USB_REDIR_FILTER,
e73cc6
-            QEMU_CAPS_IDE_DRIVE_WWN,
e73cc6
-            QEMU_CAPS_SCSI_DISK_WWN,
e73cc6
-            QEMU_CAPS_SECCOMP_SANDBOX,
e73cc6
-            QEMU_CAPS_DUMP_GUEST_CORE,
e73cc6
-            QEMU_CAPS_VNC,
e73cc6
-            QEMU_CAPS_MACHINE_OPT,
e73cc6
-            QEMU_CAPS_USB_REDIR_BOOTINDEX,
e73cc6
-            QEMU_CAPS_USB_HOST_BOOTINDEX,
e73cc6
-            QEMU_CAPS_DEVICE_QXL,
e73cc6
-            QEMU_CAPS_DEVICE_VGA,
e73cc6
-            QEMU_CAPS_DEVICE_CIRRUS_VGA,
e73cc6
-            QEMU_CAPS_DEVICE_VMWARE_SVGA,
e73cc6
-            QEMU_CAPS_DEVICE_USB_SERIAL,
e73cc6
-            QEMU_CAPS_DEVICE_USB_NET,
e73cc6
-            QEMU_CAPS_DTB,
e73cc6
-            QEMU_CAPS_SCSI_MEGASAS,
e73cc6
-            QEMU_CAPS_IPV6_MIGRATION,
e73cc6
-            QEMU_CAPS_DEVICE_PCI_BRIDGE,
e73cc6
-            QEMU_CAPS_DEVICE_SCSI_GENERIC,
e73cc6
-            QEMU_CAPS_DEVICE_SCSI_GENERIC_BOOTINDEX,
e73cc6
-            QEMU_CAPS_VNC_SHARE_POLICY,
e73cc6
-            QEMU_CAPS_DEVICE_USB_STORAGE,
e73cc6
-            QEMU_CAPS_DEVICE_USB_KBD,
e73cc6
-            QEMU_CAPS_USB_STORAGE_REMOVABLE,
e73cc6
-            QEMU_CAPS_OBJECT_USB_AUDIO,
e73cc6
-            QEMU_CAPS_SPLASH_TIMEOUT,
e73cc6
-            QEMU_CAPS_DEVICE_IVSHMEM);
e73cc6
-    DO_TEST("qemu-kvm-1.2.0", 1002000, 1, 0,
e73cc6
-            QEMU_CAPS_VNC_COLON,
e73cc6
-            QEMU_CAPS_NO_REBOOT,
e73cc6
-            QEMU_CAPS_DRIVE,
e73cc6
-            QEMU_CAPS_NAME,
e73cc6
-            QEMU_CAPS_UUID,
e73cc6
-            QEMU_CAPS_VNET_HDR,
e73cc6
-            QEMU_CAPS_MIGRATE_QEMU_TCP,
e73cc6
-            QEMU_CAPS_MIGRATE_QEMU_EXEC,
e73cc6
-            QEMU_CAPS_DRIVE_CACHE_V2,
e73cc6
-            QEMU_CAPS_KVM,
e73cc6
-            QEMU_CAPS_DRIVE_CACHE_UNSAFE,
e73cc6
-            QEMU_CAPS_DRIVE_FORMAT,
e73cc6
-            QEMU_CAPS_DRIVE_SERIAL,
e73cc6
-            QEMU_CAPS_XEN_DOMID,
e73cc6
-            QEMU_CAPS_DRIVE_READONLY,
e73cc6
-            QEMU_CAPS_VGA,
e73cc6
-            QEMU_CAPS_0_10,
e73cc6
-            QEMU_CAPS_MEM_PATH,
e73cc6
-            QEMU_CAPS_SDL,
e73cc6
-            QEMU_CAPS_MIGRATE_QEMU_UNIX,
e73cc6
-            QEMU_CAPS_CHARDEV,
e73cc6
-            QEMU_CAPS_ENABLE_KVM,
e73cc6
-            QEMU_CAPS_MONITOR_JSON,
e73cc6
-            QEMU_CAPS_BALLOON,
e73cc6
-            QEMU_CAPS_DEVICE,
e73cc6
-            QEMU_CAPS_SMP_TOPOLOGY,
e73cc6
-            QEMU_CAPS_NETDEV,
e73cc6
-            QEMU_CAPS_RTC,
e73cc6
-            QEMU_CAPS_VHOST_NET,
e73cc6
-            QEMU_CAPS_NO_HPET,
e73cc6
-            QEMU_CAPS_NO_KVM_PIT,
e73cc6
-            QEMU_CAPS_PCI_CONFIGFD,
e73cc6
-            QEMU_CAPS_NODEFCONFIG,
e73cc6
-            QEMU_CAPS_BOOT_MENU,
e73cc6
-            QEMU_CAPS_FSDEV,
e73cc6
-            QEMU_CAPS_NAME_PROCESS,
e73cc6
-            QEMU_CAPS_SMBIOS_TYPE,
e73cc6
-            QEMU_CAPS_VGA_QXL,
e73cc6
-            QEMU_CAPS_SPICE,
e73cc6
-            QEMU_CAPS_VGA_NONE,
e73cc6
-            QEMU_CAPS_MIGRATE_QEMU_FD,
e73cc6
-            QEMU_CAPS_BOOTINDEX,
e73cc6
-            QEMU_CAPS_HDA_DUPLEX,
e73cc6
-            QEMU_CAPS_DRIVE_AIO,
e73cc6
-            QEMU_CAPS_PCI_BOOTINDEX,
e73cc6
-            QEMU_CAPS_CCID_EMULATED,
e73cc6
-            QEMU_CAPS_CCID_PASSTHRU,
e73cc6
-            QEMU_CAPS_CHARDEV_SPICEVMC,
e73cc6
-            QEMU_CAPS_VIRTIO_TX_ALG,
e73cc6
-            QEMU_CAPS_DEVICE_QXL_VGA,
e73cc6
-            QEMU_CAPS_PCI_MULTIFUNCTION,
e73cc6
-            QEMU_CAPS_VIRTIO_IOEVENTFD,
e73cc6
-            QEMU_CAPS_SGA,
e73cc6
-            QEMU_CAPS_VIRTIO_BLK_EVENT_IDX,
e73cc6
-            QEMU_CAPS_VIRTIO_NET_EVENT_IDX,
e73cc6
-            QEMU_CAPS_DRIVE_CACHE_DIRECTSYNC,
e73cc6
-            QEMU_CAPS_PIIX3_USB_UHCI,
e73cc6
-            QEMU_CAPS_PIIX4_USB_UHCI,
e73cc6
-            QEMU_CAPS_USB_EHCI,
e73cc6
-            QEMU_CAPS_ICH9_USB_EHCI1,
e73cc6
-            QEMU_CAPS_VT82C686B_USB_UHCI,
e73cc6
-            QEMU_CAPS_PCI_OHCI,
e73cc6
-            QEMU_CAPS_USB_REDIR,
e73cc6
-            QEMU_CAPS_USB_HUB,
e73cc6
-            QEMU_CAPS_NO_SHUTDOWN,
e73cc6
-            QEMU_CAPS_PCI_ROMBAR,
e73cc6
-            QEMU_CAPS_ICH9_AHCI,
e73cc6
-            QEMU_CAPS_NO_ACPI,
e73cc6
-            QEMU_CAPS_FSDEV_READONLY,
e73cc6
-            QEMU_CAPS_VIRTIO_BLK_SCSI,
e73cc6
-            QEMU_CAPS_VIRTIO_BLK_SG_IO,
e73cc6
-            QEMU_CAPS_DRIVE_COPY_ON_READ,
e73cc6
-            QEMU_CAPS_CPU_HOST,
e73cc6
-            QEMU_CAPS_FSDEV_WRITEOUT,
e73cc6
-            QEMU_CAPS_DRIVE_IOTUNE,
e73cc6
-            QEMU_CAPS_SCSI_DISK_CHANNEL,
e73cc6
-            QEMU_CAPS_SCSI_BLOCK,
e73cc6
-            QEMU_CAPS_SCSI_CD,
e73cc6
-            QEMU_CAPS_IDE_CD,
e73cc6
-            QEMU_CAPS_NO_USER_CONFIG,
e73cc6
-            QEMU_CAPS_HDA_MICRO,
e73cc6
-            QEMU_CAPS_NEC_USB_XHCI,
e73cc6
-            QEMU_CAPS_NETDEV_BRIDGE,
e73cc6
-            QEMU_CAPS_SCSI_LSI,
e73cc6
-            QEMU_CAPS_VIRTIO_SCSI,
e73cc6
-            QEMU_CAPS_BLOCKIO,
e73cc6
-            QEMU_CAPS_DISABLE_S3,
e73cc6
-            QEMU_CAPS_DISABLE_S4,
e73cc6
-            QEMU_CAPS_USB_REDIR_FILTER,
e73cc6
-            QEMU_CAPS_IDE_DRIVE_WWN,
e73cc6
-            QEMU_CAPS_SCSI_DISK_WWN,
e73cc6
-            QEMU_CAPS_SECCOMP_SANDBOX,
e73cc6
-            QEMU_CAPS_DUMP_GUEST_CORE,
e73cc6
-            QEMU_CAPS_VNC,
e73cc6
-            QEMU_CAPS_MACHINE_OPT,
e73cc6
-            QEMU_CAPS_USB_REDIR_BOOTINDEX,
e73cc6
-            QEMU_CAPS_USB_HOST_BOOTINDEX,
e73cc6
-            QEMU_CAPS_DEVICE_QXL,
e73cc6
-            QEMU_CAPS_DEVICE_VGA,
e73cc6
-            QEMU_CAPS_DEVICE_CIRRUS_VGA,
e73cc6
-            QEMU_CAPS_DEVICE_VMWARE_SVGA,
e73cc6
-            QEMU_CAPS_DEVICE_USB_SERIAL,
e73cc6
-            QEMU_CAPS_DEVICE_USB_NET,
e73cc6
-            QEMU_CAPS_DTB,
e73cc6
-            QEMU_CAPS_SCSI_MEGASAS,
e73cc6
-            QEMU_CAPS_IPV6_MIGRATION,
e73cc6
-            QEMU_CAPS_DEVICE_PCI_BRIDGE,
e73cc6
-            QEMU_CAPS_DEVICE_SCSI_GENERIC,
e73cc6
-            QEMU_CAPS_DEVICE_SCSI_GENERIC_BOOTINDEX,
e73cc6
-            QEMU_CAPS_VNC_SHARE_POLICY,
e73cc6
-            QEMU_CAPS_DEVICE_USB_STORAGE,
e73cc6
-            QEMU_CAPS_DEVICE_USB_KBD,
e73cc6
-            QEMU_CAPS_USB_STORAGE_REMOVABLE,
e73cc6
-            QEMU_CAPS_OBJECT_USB_AUDIO,
e73cc6
-            QEMU_CAPS_SPLASH_TIMEOUT,
e73cc6
-            QEMU_CAPS_DEVICE_IVSHMEM);
e73cc6
+    DO_TEST_FULL("qemu-1.2.0", 1002000, 0, 0, VIR_ERR_CONFIG_UNSUPPORTED,
e73cc6
+            QEMU_CAPS_LAST);
e73cc6
+    DO_TEST_FULL("qemu-kvm-1.2.0", 1002000, 1, 0, VIR_ERR_CONFIG_UNSUPPORTED,
e73cc6
+            QEMU_CAPS_LAST);
e73cc6
 
e73cc6
     return ret == 0 ? EXIT_SUCCESS : EXIT_FAILURE;
e73cc6
 }