Re: [PATCH v2 1/2] tests: Sync tests between qemuxml2argv and qemuxml2xml

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



+42 for doing this :-)

ACK to the patch, because I don't have the intestinal fortitude to connect reconcile single change, but I'm assuming you had some methodology to the way that you added/removed things (and I'd like to subscribe to your newsletter on the topic).

(Seriously, I tried diffing qemuxml2xmltest.c and qemuxml2argvtest.c, and it showed a lot of differences in the region of the test invocations. Maybe in the future we could handle this by making both .c's reference a common file (not that *I'm* going to do this, or even that I expect you to. It would be nice though if there was a single place to put new tests that should be in both xml2argv and xml2xml tests).


On 02/23/2017 01:39 PM, Andrea Bolognani wrote:
In some cases, only one of the two transformations was
checked; in other cases, the capabilities set differed.
---
Note that the input file for the "pci-bridge" test case
had to be changed to make it usable for qemuxml2argv.

  .../qemuxml2argvdata/qemuxml2argv-pci-bridge.args  |  90 +++++++++
  tests/qemuxml2argvdata/qemuxml2argv-pci-bridge.xml |  97 +++-------
  .../qemuxml2argv-vcpu-placement-static.args        |  20 ++
  tests/qemuxml2argvtest.c                           |  74 ++++---
  .../qemuxml2xmlout-boot-floppy-q35.xml             |  32 +++
  .../qemuxml2xmlout-bootindex-floppy-q35.xml        |  32 +++
  .../qemuxml2xmlout-intel-iommu-machine.xml         |  26 +++
  .../qemuxml2xmlout-pci-bridge.xml                  |  98 ++++------
  .../qemuxml2xmloutdata/qemuxml2xmlout-pci-many.xml | 214 +++++++++++++++++++++
  ...qemuxml2xmlout-video-device-pciaddr-default.xml |  51 +++++
  tests/qemuxml2xmltest.c                            | 154 +++++++++++----
  11 files changed, 697 insertions(+), 191 deletions(-)
  create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-pci-bridge.args
  create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-vcpu-placement-static.args
  create mode 100644 tests/qemuxml2xmloutdata/qemuxml2xmlout-boot-floppy-q35.xml
  create mode 100644 tests/qemuxml2xmloutdata/qemuxml2xmlout-bootindex-floppy-q35.xml
  create mode 100644 tests/qemuxml2xmloutdata/qemuxml2xmlout-intel-iommu-machine.xml
  create mode 100644 tests/qemuxml2xmloutdata/qemuxml2xmlout-pci-many.xml
  create mode 100644 tests/qemuxml2xmloutdata/qemuxml2xmlout-video-device-pciaddr-default.xml

diff --git a/tests/qemuxml2argvdata/qemuxml2argv-pci-bridge.args b/tests/qemuxml2argvdata/qemuxml2argv-pci-bridge.args
new file mode 100644
index 0000000..d1d51b3
--- /dev/null
+++ b/tests/qemuxml2argvdata/qemuxml2argv-pci-bridge.args
@@ -0,0 +1,90 @@
+LC_ALL=C \
+PATH=/bin \
+HOME=/home/test \
+USER=test \
+LOGNAME=test \
+QEMU_AUDIO_DRV=none \
+/usr/libexec/qemu-kvm \
+-name fdr-br \
+-S \
+-M pc-1.2 \
+-m 2048 \
+-smp 2,sockets=2,cores=1,threads=1 \
+-uuid 3ec6cbe1-b5a2-4515-b800-31a61855df41 \
+-nodefaults \
+-monitor unix:/tmp/lib/domain--1-fdr-br/monitor.sock,server,nowait \
+-boot c \
+-device pci-bridge,chassis_nr=1,id=pci.1,bus=pci.0,addr=0x3 \
+-device pci-bridge,chassis_nr=2,id=pci.2,bus=pci.0,addr=0x4 \
+-usb \
+-drive file=/var/iso/f18kde.iso,format=raw,if=none,media=cdrom,\
+id=drive-ide0-1-0,readonly=on \
+-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
+-device rtl8139,vlan=0,id=net0,mac=52:54:00:f1:95:51,bus=pci.0,addr=0x5 \
+-net user,vlan=0,name=hostnet0 \
+-device e1000,vlan=1,id=net1,mac=52:54:00:5c:c6:1a,bus=pci.0,addr=0x7 \
+-net user,vlan=1,name=hostnet1 \
+-device e1000,vlan=2,id=net2,mac=52:54:00:39:97:ac,bus=pci.0,addr=0x8 \
+-net user,vlan=2,name=hostnet2 \
+-device e1000,vlan=3,id=net3,mac=52:54:00:45:28:cb,bus=pci.0,addr=0x9 \
+-net user,vlan=3,name=hostnet3 \
+-device e1000,vlan=4,id=net4,mac=52:54:00:ee:b9:a8,bus=pci.0,addr=0xa \
+-net user,vlan=4,name=hostnet4 \
+-device e1000,vlan=5,id=net5,mac=52:54:00:a9:f7:17,bus=pci.0,addr=0xb \
+-net user,vlan=5,name=hostnet5 \
+-device e1000,vlan=6,id=net6,mac=52:54:00:df:2b:f3,bus=pci.0,addr=0xc \
+-net user,vlan=6,name=hostnet6 \
+-device e1000,vlan=7,id=net7,mac=52:54:00:78:94:b4,bus=pci.0,addr=0xd \
+-net user,vlan=7,name=hostnet7 \
+-device e1000,vlan=8,id=net8,mac=52:54:00:6b:9b:06,bus=pci.0,addr=0xe \
+-net user,vlan=8,name=hostnet8 \
+-device e1000,vlan=9,id=net9,mac=52:54:00:17:df:bc,bus=pci.0,addr=0xf \
+-net user,vlan=9,name=hostnet9 \
+-device rtl8139,vlan=10,id=net10,mac=52:54:00:3b:d0:51,bus=pci.0,addr=0x10 \
+-net user,vlan=10,name=hostnet10 \
+-device e1000,vlan=11,id=net11,mac=52:54:00:8d:2d:17,bus=pci.0,addr=0x11 \
+-net user,vlan=11,name=hostnet11 \
+-device e1000,vlan=12,id=net12,mac=52:54:00:a7:66:af,bus=pci.0,addr=0x12 \
+-net user,vlan=12,name=hostnet12 \
+-device e1000,vlan=13,id=net13,mac=52:54:00:54:ab:d7,bus=pci.0,addr=0x13 \
+-net user,vlan=13,name=hostnet13 \
+-device e1000,vlan=14,id=net14,mac=52:54:00:1f:99:90,bus=pci.0,addr=0x14 \
+-net user,vlan=14,name=hostnet14 \
+-device e1000,vlan=15,id=net15,mac=52:54:00:c8:43:87,bus=pci.0,addr=0x15 \
+-net user,vlan=15,name=hostnet15 \
+-device e1000,vlan=16,id=net16,mac=52:54:00:df:22:b2,bus=pci.0,addr=0x16 \
+-net user,vlan=16,name=hostnet16 \
+-device e1000,vlan=17,id=net17,mac=52:54:00:d2:9a:47,bus=pci.0,addr=0x17 \
+-net user,vlan=17,name=hostnet17 \
+-device e1000,vlan=18,id=net18,mac=52:54:00:86:05:e2,bus=pci.0,addr=0x18 \
+-net user,vlan=18,name=hostnet18 \
+-device e1000,vlan=19,id=net19,mac=52:54:00:8c:1c:c2,bus=pci.0,addr=0x19 \
+-net user,vlan=19,name=hostnet19 \
+-device e1000,vlan=20,id=net20,mac=52:54:00:48:58:92,bus=pci.0,addr=0x1a \
+-net user,vlan=20,name=hostnet20 \
+-device e1000,vlan=21,id=net21,mac=52:54:00:99:e5:bf,bus=pci.0,addr=0x1b \
+-net user,vlan=21,name=hostnet21 \
+-device e1000,vlan=22,id=net22,mac=52:54:00:b1:8c:25,bus=pci.0,addr=0x1c \
+-net user,vlan=22,name=hostnet22 \
+-device e1000,vlan=23,id=net23,mac=52:54:00:60:e0:d0,bus=pci.0,addr=0x1d \
+-net user,vlan=23,name=hostnet23 \
+-device e1000,vlan=24,id=net24,mac=52:54:00:37:00:6a,bus=pci.0,addr=0x1e \
+-net user,vlan=24,name=hostnet24 \
+-device e1000,vlan=25,id=net25,mac=52:54:00:c7:c8:ad,bus=pci.0,addr=0x1f \
+-net user,vlan=25,name=hostnet25 \
+-device e1000,vlan=26,id=net26,mac=52:54:00:4e:a7:cf,bus=pci.1,addr=0x1 \
+-net user,vlan=26,name=hostnet26 \
+-device e1000,vlan=27,id=net27,mac=52:54:00:00:79:69,bus=pci.1,addr=0x2 \
+-net user,vlan=27,name=hostnet27 \
+-device e1000,vlan=28,id=net28,mac=52:54:00:47:00:6f,bus=pci.1,addr=0x3 \
+-net user,vlan=28,name=hostnet28 \
+-device e1000,vlan=29,id=net29,mac=52:54:00:2a:8c:8b,bus=pci.1,addr=0x4 \
+-net user,vlan=29,name=hostnet29 \
+-device e1000,vlan=30,id=net30,mac=52:54:00:ec:d5:e3,bus=pci.1,addr=0x5 \
+-net user,vlan=30,name=hostnet30 \
+-device e1000,vlan=31,id=net31,mac=52:54:00:7e:6e:c8,bus=pci.1,addr=0x6 \
+-net user,vlan=31,name=hostnet31 \
+-vnc 127.0.0.1:0 \
+-k en-us \
+-vga cirrus \
+-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x6
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-pci-bridge.xml b/tests/qemuxml2argvdata/qemuxml2argv-pci-bridge.xml
index 683c269..2e8f539 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-pci-bridge.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-pci-bridge.xml
@@ -35,164 +35,131 @@
      <controller type='pci' index='0' model='pci-root'/>
      <controller type='pci' index='1' model='pci-bridge'/>
      <controller type='pci' index='2' model='pci-bridge'/>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:f1:95:51'/>
-      <source network='default'/>
        <model type='rtl8139'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:5c:c6:1a'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:39:97:ac'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:45:28:cb'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:ee:b9:a8'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:a9:f7:17'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:df:2b:f3'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:78:94:b4'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:6b:9b:06'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:17:df:bc'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:3b:d0:51'/>
-      <source network='default'/>
-      <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:8d:2d:17'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:a7:66:af'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:54:ab:d7'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:1f:99:90'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:c8:43:87'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:df:22:b2'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:d2:9a:47'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:86:05:e2'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:8c:1c:c2'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:48:58:92'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:99:e5:bf'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:b1:8c:25'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:60:e0:d0'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:37:00:6a'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:c7:c8:ad'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:4e:a7:cf'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:00:79:69'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:47:00:6f'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:2a:8c:8b'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:ec:d5:e3'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:7e:6e:c8'/>
-      <source network='default'/>
        <model type='e1000'/>
      </interface>
      <input type='mouse' bus='ps2'/>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-vcpu-placement-static.args b/tests/qemuxml2argvdata/qemuxml2argv-vcpu-placement-static.args
new file mode 100644
index 0000000..387ffd2
--- /dev/null
+++ b/tests/qemuxml2argvdata/qemuxml2argv-vcpu-placement-static.args
@@ -0,0 +1,20 @@
+LC_ALL=C \
+PATH=/bin \
+HOME=/home/test \
+USER=test \
+LOGNAME=test \
+QEMU_AUDIO_DRV=none \
+/usr/bin/qemu-system-x86_64 \
+-name dummy2 \
+-S \
+-M pc-q35-2.3 \
+-m 128 \
+-smp 2,maxcpus=6,sockets=6,cores=1,threads=1 \
+-object iothread,id=iothread1 \
+-object iothread,id=iothread2 \
+-uuid 4d92ec27-9ebf-400b-ae91-20c71c647c19 \
+-nographic \
+-nodefaults \
+-monitor unix:/tmp/lib/domain--1-dummy2/monitor.sock,server,nowait \
+-no-acpi \
+-boot c
diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c
index f55b04b..1298ac6 100644
--- a/tests/qemuxml2argvtest.c
+++ b/tests/qemuxml2argvtest.c
@@ -1393,23 +1393,29 @@ mymain(void)
              QEMU_CAPS_CHARDEV, QEMU_CAPS_NODEFCONFIG);
      DO_TEST("usb-controller-default-q35",
              QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_IOH3420,
-            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE, QEMU_CAPS_PCI_OHCI,
-            QEMU_CAPS_PIIX3_USB_UHCI, QEMU_CAPS_NEC_USB_XHCI);
+            QEMU_CAPS_PCI_OHCI,
+            QEMU_CAPS_PIIX3_USB_UHCI,
+            QEMU_CAPS_NEC_USB_XHCI);
      DO_TEST_FAILURE("usb-controller-default-unavailable-q35",
                      QEMU_CAPS_DEVICE_PCI_BRIDGE,
+                    QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
                      QEMU_CAPS_DEVICE_IOH3420,
-                    QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE, QEMU_CAPS_PCI_OHCI,
+                    QEMU_CAPS_PCI_OHCI,
                      QEMU_CAPS_NEC_USB_XHCI);
      DO_TEST("usb-controller-explicit-q35",
              QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_IOH3420,
-            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE, QEMU_CAPS_PCI_OHCI,
-            QEMU_CAPS_PIIX3_USB_UHCI, QEMU_CAPS_NEC_USB_XHCI);
+            QEMU_CAPS_PCI_OHCI,
+            QEMU_CAPS_PIIX3_USB_UHCI,
+            QEMU_CAPS_NEC_USB_XHCI);
      DO_TEST_FAILURE("usb-controller-explicit-unavailable-q35",
                      QEMU_CAPS_DEVICE_PCI_BRIDGE,
                      QEMU_CAPS_DEVICE_IOH3420,
-                    QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE, QEMU_CAPS_PCI_OHCI,
+                    QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+                    QEMU_CAPS_PCI_OHCI,
                      QEMU_CAPS_PIIX3_USB_UHCI);
      DO_TEST("usb-controller-xhci",
              QEMU_CAPS_CHARDEV, QEMU_CAPS_NODEFCONFIG, QEMU_CAPS_PIIX3_USB_UHCI,
@@ -1572,6 +1578,10 @@ mymain(void)
              QEMU_CAPS_OBJECT_IOTHREAD,
              QEMU_CAPS_OBJECT_MEMORY_RAM,
              QEMU_CAPS_OBJECT_MEMORY_FILE);
+    DO_TEST("vcpu-placement-static",
+            QEMU_CAPS_KVM,
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_OBJECT_IOTHREAD);
DO_TEST("numatune-memory", NONE);
      DO_TEST_PARSE_ERROR("numatune-memory-invalid-nodeset", NONE);
@@ -1682,10 +1692,11 @@ mymain(void)
              QEMU_CAPS_IDE_CD, QEMU_CAPS_BLOCKIO);
DO_TEST("video-device-pciaddr-default",
-            QEMU_CAPS_KVM, QEMU_CAPS_VNC,
+            QEMU_CAPS_KVM,
+            QEMU_CAPS_VNC,
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
-            QEMU_CAPS_DEVICE_QXL,
-            QEMU_CAPS_DEVICE_PCI_BRIDGE);
+            QEMU_CAPS_DEVICE_QXL);
      DO_TEST("video-vga-nodevice", QEMU_CAPS_DEVICE_VGA);
      DO_TEST("video-vga-device", QEMU_CAPS_DEVICE_VGA,
              QEMU_CAPS_DEVICE_VIDEO_PRIMARY);
@@ -1785,9 +1796,15 @@ mymain(void)
      DO_TEST_PARSE_ERROR("pci-slot-invalid", NONE);
      DO_TEST_PARSE_ERROR("pci-function-invalid", NONE);
- DO_TEST("pci-autoadd-addr", QEMU_CAPS_DEVICE_PCI_BRIDGE,
+    DO_TEST("pci-bridge",
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_VNC,
+            QEMU_CAPS_DEVICE_CIRRUS_VGA);
+    DO_TEST("pci-autoadd-addr",
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_CIRRUS_VGA);
-    DO_TEST("pci-autoadd-idx", QEMU_CAPS_DEVICE_PCI_BRIDGE,
+    DO_TEST("pci-autoadd-idx",
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_CIRRUS_VGA);
      DO_TEST("pci-autofill-addr", QEMU_CAPS_DEVICE_CIRRUS_VGA);
      DO_TEST("pci-many",
@@ -1796,16 +1813,19 @@ mymain(void)
      DO_TEST("pci-bridge-many-disks",
              QEMU_CAPS_DEVICE_PCI_BRIDGE);
      DO_TEST("pcie-root",
-            QEMU_CAPS_ICH9_AHCI,
              QEMU_CAPS_DEVICE_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
-            QEMU_CAPS_DEVICE_IOH3420);
+            QEMU_CAPS_DEVICE_IOH3420,
+            QEMU_CAPS_ICH9_AHCI,
+            QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
+            QEMU_CAPS_DEVICE_QXL);
      DO_TEST("q35",
              QEMU_CAPS_DEVICE_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_IOH3420,
              QEMU_CAPS_ICH9_AHCI,
-            QEMU_CAPS_PCI_MULTIFUNCTION, QEMU_CAPS_ICH9_USB_EHCI1,
+            QEMU_CAPS_PCI_MULTIFUNCTION,
+            QEMU_CAPS_ICH9_USB_EHCI1,
              QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
              QEMU_CAPS_DEVICE_QXL);
      DO_TEST_PARSE_ERROR("q35-dmi-bad-address1",
@@ -1832,7 +1852,8 @@ mymain(void)
              QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_IOH3420,
              QEMU_CAPS_ICH9_AHCI,
-            QEMU_CAPS_PCI_MULTIFUNCTION, QEMU_CAPS_ICH9_USB_EHCI1,
+            QEMU_CAPS_PCI_MULTIFUNCTION,
+            QEMU_CAPS_ICH9_USB_EHCI1,
              QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
              QEMU_CAPS_DEVICE_QXL);
      DO_TEST("q35-usb2-multi",
@@ -1840,7 +1861,8 @@ mymain(void)
              QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_IOH3420,
              QEMU_CAPS_ICH9_AHCI,
-            QEMU_CAPS_PCI_MULTIFUNCTION, QEMU_CAPS_ICH9_USB_EHCI1,
+            QEMU_CAPS_PCI_MULTIFUNCTION,
+            QEMU_CAPS_ICH9_USB_EHCI1,
              QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
              QEMU_CAPS_DEVICE_QXL);
      DO_TEST("q35-usb2-reorder",
@@ -1848,7 +1870,8 @@ mymain(void)
              QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_IOH3420,
              QEMU_CAPS_ICH9_AHCI,
-            QEMU_CAPS_PCI_MULTIFUNCTION, QEMU_CAPS_ICH9_USB_EHCI1,
+            QEMU_CAPS_PCI_MULTIFUNCTION,
+            QEMU_CAPS_ICH9_USB_EHCI1,
              QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
              QEMU_CAPS_DEVICE_QXL);
      /* verify that devices with pcie capability are assigned to a pcie slot */
@@ -2020,7 +2043,8 @@ mymain(void)
              QEMU_CAPS_DEVICE_X3130_UPSTREAM,
              QEMU_CAPS_DEVICE_XIO3130_DOWNSTREAM,
              QEMU_CAPS_ICH9_AHCI,
-            QEMU_CAPS_PCI_MULTIFUNCTION, QEMU_CAPS_ICH9_USB_EHCI1,
+            QEMU_CAPS_PCI_MULTIFUNCTION,
+            QEMU_CAPS_ICH9_USB_EHCI1,
              QEMU_CAPS_NEC_USB_XHCI);
      /* Make sure the user can always override libvirt's default device
       * placement policy by providing an explicit PCI address */
@@ -2190,7 +2214,8 @@ mymain(void)
              QEMU_CAPS_OBJECT_GPEX, QEMU_CAPS_DEVICE_PCI_BRIDGE,
              QEMU_CAPS_PCI_MULTIFUNCTION,
              QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
-            QEMU_CAPS_DEVICE_IOH3420);
+            QEMU_CAPS_DEVICE_IOH3420,
+            QEMU_CAPS_VIRTIO_SCSI);
      DO_TEST("aarch64-virt-2.6-virtio-pci-default",
              QEMU_CAPS_NODEFCONFIG, QEMU_CAPS_DTB,
              QEMU_CAPS_DEVICE_VIRTIO_MMIO,
@@ -2466,12 +2491,15 @@ mymain(void)
                          QEMU_CAPS_NODEFCONFIG, QEMU_CAPS_USB_HUB);
DO_TEST("acpi-table", NONE);
-    DO_TEST("intel-iommu", QEMU_CAPS_DEVICE_PCI_BRIDGE,
+    DO_TEST("intel-iommu",
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
-            QEMU_CAPS_DEVICE_IOH3420,
              QEMU_CAPS_DEVICE_INTEL_IOMMU);
-    DO_TEST("intel-iommu-machine", QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_MACHINE_OPT,
-            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE, QEMU_CAPS_MACHINE_IOMMU);
+    DO_TEST("intel-iommu-machine",
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_MACHINE_OPT,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+            QEMU_CAPS_MACHINE_IOMMU);
DO_TEST("cpu-hotplug-startup", QEMU_CAPS_QUERY_HOTPLUGGABLE_CPUS); diff --git a/tests/qemuxml2xmloutdata/qemuxml2xmlout-boot-floppy-q35.xml b/tests/qemuxml2xmloutdata/qemuxml2xmlout-boot-floppy-q35.xml
new file mode 100644
index 0000000..b94ad85
--- /dev/null
+++ b/tests/qemuxml2xmloutdata/qemuxml2xmlout-boot-floppy-q35.xml
@@ -0,0 +1,32 @@
+<domain type='qemu'>
+  <name>QEMUGuest1</name>
+  <uuid>c7a5fdbd-edaf-9455-926a-d65c16db1809</uuid>
+  <memory unit='KiB'>219100</memory>
+  <currentMemory unit='KiB'>219100</currentMemory>
+  <vcpu placement='static'>1</vcpu>
+  <os>
+    <type arch='x86_64' machine='pc-q35-2.4'>hvm</type>
+    <boot dev='fd'/>
+  </os>
+  <clock offset='utc'/>
+  <on_poweroff>destroy</on_poweroff>
+  <on_reboot>restart</on_reboot>
+  <on_crash>destroy</on_crash>
+  <devices>
+    <emulator>/usr/bin/qemu</emulator>
+    <disk type='file' device='floppy'>
+      <driver name='qemu' type='raw'/>
+      <source file='/tmp/firmware.img'/>
+      <target dev='fda' bus='fdc'/>
+      <address type='drive' controller='0' bus='0' target='0' unit='0'/>
+    </disk>
+    <controller type='sata' index='0'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
+    </controller>
+    <controller type='pci' index='0' model='pcie-root'/>
+    <controller type='fdc' index='0'/>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <memballoon model='none'/>
+  </devices>
+</domain>
diff --git a/tests/qemuxml2xmloutdata/qemuxml2xmlout-bootindex-floppy-q35.xml b/tests/qemuxml2xmloutdata/qemuxml2xmlout-bootindex-floppy-q35.xml
new file mode 100644
index 0000000..b94ad85
--- /dev/null
+++ b/tests/qemuxml2xmloutdata/qemuxml2xmlout-bootindex-floppy-q35.xml
@@ -0,0 +1,32 @@
+<domain type='qemu'>
+  <name>QEMUGuest1</name>
+  <uuid>c7a5fdbd-edaf-9455-926a-d65c16db1809</uuid>
+  <memory unit='KiB'>219100</memory>
+  <currentMemory unit='KiB'>219100</currentMemory>
+  <vcpu placement='static'>1</vcpu>
+  <os>
+    <type arch='x86_64' machine='pc-q35-2.4'>hvm</type>
+    <boot dev='fd'/>
+  </os>
+  <clock offset='utc'/>
+  <on_poweroff>destroy</on_poweroff>
+  <on_reboot>restart</on_reboot>
+  <on_crash>destroy</on_crash>
+  <devices>
+    <emulator>/usr/bin/qemu</emulator>
+    <disk type='file' device='floppy'>
+      <driver name='qemu' type='raw'/>
+      <source file='/tmp/firmware.img'/>
+      <target dev='fda' bus='fdc'/>
+      <address type='drive' controller='0' bus='0' target='0' unit='0'/>
+    </disk>
+    <controller type='sata' index='0'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
+    </controller>
+    <controller type='pci' index='0' model='pcie-root'/>
+    <controller type='fdc' index='0'/>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <memballoon model='none'/>
+  </devices>
+</domain>
diff --git a/tests/qemuxml2xmloutdata/qemuxml2xmlout-intel-iommu-machine.xml b/tests/qemuxml2xmloutdata/qemuxml2xmlout-intel-iommu-machine.xml
new file mode 100644
index 0000000..de921f6
--- /dev/null
+++ b/tests/qemuxml2xmloutdata/qemuxml2xmlout-intel-iommu-machine.xml
@@ -0,0 +1,26 @@
+<domain type='qemu'>
+  <name>QEMUGuest1</name>
+  <uuid>c7a5fdbd-edaf-9455-926a-d65c16db1809</uuid>
+  <memory unit='KiB'>219100</memory>
+  <currentMemory unit='KiB'>219100</currentMemory>
+  <vcpu placement='static'>1</vcpu>
+  <os>
+    <type arch='x86_64' machine='q35'>hvm</type>
+    <boot dev='hd'/>
+  </os>
+  <clock offset='utc'/>
+  <on_poweroff>destroy</on_poweroff>
+  <on_reboot>restart</on_reboot>
+  <on_crash>destroy</on_crash>
+  <devices>
+    <emulator>/usr/bin/qemu</emulator>
+    <controller type='pci' index='0' model='pcie-root'/>
+    <controller type='sata' index='0'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
+    </controller>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <memballoon model='none'/>
+    <iommu model='intel'/>
+  </devices>
+</domain>
diff --git a/tests/qemuxml2xmloutdata/qemuxml2xmlout-pci-bridge.xml b/tests/qemuxml2xmloutdata/qemuxml2xmlout-pci-bridge.xml
index 61de009..6769bac 100644
--- a/tests/qemuxml2xmloutdata/qemuxml2xmlout-pci-bridge.xml
+++ b/tests/qemuxml2xmloutdata/qemuxml2xmlout-pci-bridge.xml
@@ -43,195 +43,163 @@
        <target chassisNr='2'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
      </controller>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:f1:95:51'/>
-      <source network='default'/>
        <model type='rtl8139'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:5c:c6:1a'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:39:97:ac'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x08' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:45:28:cb'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x09' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:ee:b9:a8'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x0a' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:a9:f7:17'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x0b' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:df:2b:f3'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x0c' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:78:94:b4'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x0d' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:6b:9b:06'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x0e' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:17:df:bc'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x0f' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:3b:d0:51'/>
-      <source network='default'/>
-      <model type='e1000'/>
+      <model type='rtl8139'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x10' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:8d:2d:17'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x11' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:a7:66:af'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x12' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:54:ab:d7'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x13' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:1f:99:90'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x14' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:c8:43:87'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x15' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:df:22:b2'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x16' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:d2:9a:47'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x17' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:86:05:e2'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x18' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:8c:1c:c2'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x19' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:48:58:92'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x1a' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:99:e5:bf'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x1b' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:b1:8c:25'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x1c' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:60:e0:d0'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x1d' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:37:00:6a'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:c7:c8:ad'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:4e:a7:cf'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x01' slot='0x01' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:00:79:69'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x01' slot='0x02' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:47:00:6f'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x01' slot='0x03' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:2a:8c:8b'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x01' slot='0x04' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:ec:d5:e3'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x01' slot='0x05' function='0x0'/>
      </interface>
-    <interface type='network'>
+    <interface type='user'>
        <mac address='52:54:00:7e:6e:c8'/>
-      <source network='default'/>
        <model type='e1000'/>
        <address type='pci' domain='0x0000' bus='0x01' slot='0x06' function='0x0'/>
      </interface>
diff --git a/tests/qemuxml2xmloutdata/qemuxml2xmlout-pci-many.xml b/tests/qemuxml2xmloutdata/qemuxml2xmlout-pci-many.xml
new file mode 100644
index 0000000..375ff14
--- /dev/null
+++ b/tests/qemuxml2xmloutdata/qemuxml2xmlout-pci-many.xml
@@ -0,0 +1,214 @@
+<domain type='qemu'>
+  <name>fdr-br</name>
+  <uuid>3ec6cbe1-b5a2-4515-b800-31a61855df41</uuid>
+  <memory unit='KiB'>2097152</memory>
+  <currentMemory unit='KiB'>2097152</currentMemory>
+  <vcpu placement='static' cpuset='0-1'>2</vcpu>
+  <os>
+    <type arch='x86_64' machine='pc-1.2'>hvm</type>
+    <boot dev='hd'/>
+  </os>
+  <features>
+    <acpi/>
+    <apic/>
+    <pae/>
+  </features>
+  <clock offset='utc'/>
+  <on_poweroff>destroy</on_poweroff>
+  <on_reboot>restart</on_reboot>
+  <on_crash>restart</on_crash>
+  <devices>
+    <emulator>/usr/libexec/qemu-kvm</emulator>
+    <disk type='file' device='cdrom'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/iso/f18kde.iso'/>
+      <target dev='hdc' bus='ide'/>
+      <readonly/>
+      <address type='drive' controller='0' bus='1' target='0' unit='0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/test.img'/>
+      <target dev='vda' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/test1.img'/>
+      <target dev='vdb' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-a-a.img'/>
+      <target dev='vdaa' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-a-b.img'/>
+      <target dev='vdab' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-a-c.img'/>
+      <target dev='vdac' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x08' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-a-d.img'/>
+      <target dev='vdad' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x09' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-b-a.img'/>
+      <target dev='vdba' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x0a' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-b-b.img'/>
+      <target dev='vdbb' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x0b' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-b-c.img'/>
+      <target dev='vdbc' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x0c' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-b-d.img'/>
+      <target dev='vdbd' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x0d' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-c-a.img'/>
+      <target dev='vdca' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x0e' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-c-b.img'/>
+      <target dev='vdcb' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x0f' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-c-c.img'/>
+      <target dev='vdcc' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x10' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-c-d.img'/>
+      <target dev='vdcd' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x11' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-d-a.img'/>
+      <target dev='vdda' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x12' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-d-b.img'/>
+      <target dev='vddb' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x13' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-d-c.img'/>
+      <target dev='vddc' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x14' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-d-d.img'/>
+      <target dev='vddd' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x15' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-e-a.img'/>
+      <target dev='vdea' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x16' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-e-b.img'/>
+      <target dev='vdeb' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x17' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-e-c.img'/>
+      <target dev='vdec' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x18' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-e-d.img'/>
+      <target dev='vded' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x19' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-f-a.img'/>
+      <target dev='vdfa' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x1a' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-f-b.img'/>
+      <target dev='vdfb' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x1b' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-f-c.img'/>
+      <target dev='vdfc' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x1c' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-f-d.img'/>
+      <target dev='vdfd' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x1d' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-g-a.img'/>
+      <target dev='vdga' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
+    </disk>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='raw'/>
+      <source file='/var/lib/libvirt/images/disk-g-b.img'/>
+      <target dev='vdgb' bus='virtio'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x0'/>
+    </disk>
+    <controller type='usb' index='0'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
+    </controller>
+    <controller type='ide' index='0'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/>
+    </controller>
+    <controller type='pci' index='0' model='pci-root'/>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <video>
+      <model type='cirrus' vram='16384' heads='1' primary='yes'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
+    </video>
+    <memballoon model='virtio'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x06' function='0x0'/>
+    </memballoon>
+  </devices>
+</domain>
diff --git a/tests/qemuxml2xmloutdata/qemuxml2xmlout-video-device-pciaddr-default.xml b/tests/qemuxml2xmloutdata/qemuxml2xmlout-video-device-pciaddr-default.xml
new file mode 100644
index 0000000..9dbeaf3
--- /dev/null
+++ b/tests/qemuxml2xmloutdata/qemuxml2xmlout-video-device-pciaddr-default.xml
@@ -0,0 +1,51 @@
+<domain type='kvm'>
+  <name>QEMUGuest1</name>
+  <uuid>cdbebdfa-1d6d-65c3-be0f-fd74b978a773</uuid>
+  <memory unit='KiB'>1048576</memory>
+  <currentMemory unit='KiB'>1048576</currentMemory>
+  <vcpu placement='static'>1</vcpu>
+  <os>
+    <type arch='x86_64' machine='pc-0.15'>hvm</type>
+    <boot dev='hd'/>
+  </os>
+  <clock offset='utc'/>
+  <on_poweroff>destroy</on_poweroff>
+  <on_reboot>restart</on_reboot>
+  <on_crash>restart</on_crash>
+  <devices>
+    <emulator>/usr/bin/qemu</emulator>
+    <disk type='file' device='disk'>
+      <driver name='qemu' type='qcow2' cache='none'/>
+      <source file='/var/lib/libvirt/images/QEMUGuest1'/>
+      <target dev='hda' bus='ide'/>
+      <address type='drive' controller='0' bus='0' target='0' unit='0'/>
+    </disk>
+    <controller type='usb' index='0'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
+    </controller>
+    <controller type='ide' index='0'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/>
+    </controller>
+    <controller type='pci' index='0' model='pci-root'/>
+    <input type='mouse' bus='ps2'/>
+    <input type='keyboard' bus='ps2'/>
+    <graphics type='vnc' port='-1' autoport='yes' listen='127.0.0.1'>
+      <listen type='address' address='127.0.0.1'/>
+    </graphics>
+    <video>
+      <model type='qxl' ram='65536' vram='65536' vgamem='16384' heads='1' primary='yes'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/>
+    </video>
+    <video>
+      <model type='qxl' ram='65536' vram='65536' vgamem='16384' heads='1'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
+    </video>
+    <video>
+      <model type='qxl' ram='65536' vram='65536' vgamem='16384' heads='1'/>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/>
+    </video>
+    <memballoon model='virtio'>
+      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
+    </memballoon>
+  </devices>
+</domain>
diff --git a/tests/qemuxml2xmltest.c b/tests/qemuxml2xmltest.c
index 0702f58..225f999 100644
--- a/tests/qemuxml2xmltest.c
+++ b/tests/qemuxml2xmltest.c
@@ -371,6 +371,17 @@ mymain(void)
      DO_TEST("boot-cdrom", NONE);
      DO_TEST("boot-network", NONE);
      DO_TEST("boot-floppy", NONE);
+    DO_TEST("boot-floppy-q35",
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_IOH3420,
+            QEMU_CAPS_ICH9_AHCI);
+    DO_TEST("bootindex-floppy-q35",
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_IOH3420,
+            QEMU_CAPS_ICH9_AHCI, QEMU_CAPS_BOOT_MENU,
+            QEMU_CAPS_BOOTINDEX);
      DO_TEST("boot-multi", NONE);
      DO_TEST("boot-menu-enable-with-timeout", NONE);
      DO_TEST("boot-menu-disable", NONE);
@@ -566,7 +577,9 @@ mymain(void)
      DO_TEST("cputune-iothreadsched-zeropriority", NONE);
      DO_TEST("cputune-numatune", NONE);
      DO_TEST("vcpu-placement-static",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE);
+            QEMU_CAPS_KVM,
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_OBJECT_IOTHREAD);
DO_TEST("smp", NONE);
      DO_TEST("iothreads", NONE);
@@ -593,14 +606,18 @@ mymain(void)
      DO_TEST("usb-piix3-controller",
              QEMU_CAPS_PIIX3_USB_UHCI);
      DO_TEST("usb-controller-default-q35",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_IOH3420,
-            QEMU_CAPS_PCI_OHCI, QEMU_CAPS_PIIX3_USB_UHCI,
+            QEMU_CAPS_PCI_OHCI,
+            QEMU_CAPS_PIIX3_USB_UHCI,
              QEMU_CAPS_NEC_USB_XHCI);
      DO_TEST("usb-controller-explicit-q35",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_IOH3420,
-            QEMU_CAPS_PCI_OHCI, QEMU_CAPS_PIIX3_USB_UHCI,
+            QEMU_CAPS_PCI_OHCI,
+            QEMU_CAPS_PIIX3_USB_UHCI,
              QEMU_CAPS_NEC_USB_XHCI);
      DO_TEST("ppc64-usb-controller",
              QEMU_CAPS_PCI_OHCI);
@@ -669,45 +686,63 @@ mymain(void)
      DO_TEST("metadata-duplicate", NONE);
DO_TEST("pci-bridge",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE);
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_VNC,
+            QEMU_CAPS_DEVICE_CIRRUS_VGA);
+    DO_TEST("pci-many",
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_CIRRUS_VGA);
      DO_TEST("pci-bridge-many-disks",
              QEMU_CAPS_DEVICE_PCI_BRIDGE);
      DO_TEST("pci-autoadd-addr",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE);
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_CIRRUS_VGA);
      DO_TEST("pci-autoadd-idx",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE);
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_CIRRUS_VGA);
      DO_TEST("pci-autofill-addr", NONE);
DO_TEST("q35",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_IOH3420,
-            QEMU_CAPS_ICH9_AHCI, QEMU_CAPS_PCI_MULTIFUNCTION,
-            QEMU_CAPS_ICH9_USB_EHCI1, QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
+            QEMU_CAPS_ICH9_AHCI,
+            QEMU_CAPS_PCI_MULTIFUNCTION,
+            QEMU_CAPS_ICH9_USB_EHCI1,
+            QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
              QEMU_CAPS_DEVICE_QXL);
      DO_TEST("q35-usb2",
              QEMU_CAPS_DEVICE_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_IOH3420,
              QEMU_CAPS_ICH9_AHCI,
-            QEMU_CAPS_PCI_MULTIFUNCTION, QEMU_CAPS_ICH9_USB_EHCI1,
+            QEMU_CAPS_PCI_MULTIFUNCTION,
+            QEMU_CAPS_ICH9_USB_EHCI1,
              QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
              QEMU_CAPS_DEVICE_QXL);
      DO_TEST("q35-usb2-multi",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_IOH3420,
-            QEMU_CAPS_ICH9_AHCI, QEMU_CAPS_PCI_MULTIFUNCTION,
-            QEMU_CAPS_ICH9_USB_EHCI1, QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
+            QEMU_CAPS_ICH9_AHCI,
+            QEMU_CAPS_PCI_MULTIFUNCTION,
+            QEMU_CAPS_ICH9_USB_EHCI1,
+            QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
              QEMU_CAPS_DEVICE_QXL);
      DO_TEST("q35-usb2-reorder",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_IOH3420,
-            QEMU_CAPS_ICH9_AHCI, QEMU_CAPS_PCI_MULTIFUNCTION,
-            QEMU_CAPS_ICH9_USB_EHCI1, QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
+            QEMU_CAPS_ICH9_AHCI,
+            QEMU_CAPS_PCI_MULTIFUNCTION,
+            QEMU_CAPS_ICH9_USB_EHCI1,
+            QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
              QEMU_CAPS_DEVICE_QXL);
      DO_TEST("q35-pcie",
              QEMU_CAPS_VIRTIO_PCI_DISABLE_LEGACY,
              QEMU_CAPS_DEVICE_VIRTIO_RNG,
              QEMU_CAPS_OBJECT_RNG_RANDOM,
+            QEMU_CAPS_NETDEV,
              QEMU_CAPS_DEVICE_VIRTIO_NET,
              QEMU_CAPS_DEVICE_VIRTIO_GPU,
              QEMU_CAPS_VIRTIO_GPU_VIRGL,
@@ -731,6 +766,7 @@ mymain(void)
      DO_TEST("q35-virtio-pci",
              QEMU_CAPS_DEVICE_VIRTIO_RNG,
              QEMU_CAPS_OBJECT_RNG_RANDOM,
+            QEMU_CAPS_NETDEV,
              QEMU_CAPS_DEVICE_VIRTIO_NET,
              QEMU_CAPS_DEVICE_VIRTIO_GPU,
              QEMU_CAPS_VIRTIO_GPU_VIRGL,
@@ -820,6 +856,11 @@ mymain(void)
              QEMU_CAPS_NEC_USB_XHCI,
              QEMU_CAPS_DEVICE_VIDEO_PRIMARY);
      DO_TEST("q35-virt-manager-basic",
+            QEMU_CAPS_KVM,
+            QEMU_CAPS_RTC,
+            QEMU_CAPS_NO_KVM_PIT,
+            QEMU_CAPS_ICH9_DISABLE_S3,
+            QEMU_CAPS_ICH9_DISABLE_S4,
              QEMU_CAPS_VIRTIO_PCI_DISABLE_LEGACY,
              QEMU_CAPS_DEVICE_VIRTIO_RNG,
              QEMU_CAPS_OBJECT_RNG_RANDOM,
@@ -842,40 +883,64 @@ mymain(void)
              QEMU_CAPS_ICH9_USB_EHCI1,
              QEMU_CAPS_NEC_USB_XHCI,
              QEMU_CAPS_DEVICE_ICH9_INTEL_HDA,
-            QEMU_CAPS_DEVICE_VIDEO_PRIMARY);
+            QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
+            QEMU_CAPS_SPICE,
+            QEMU_CAPS_CHARDEV_SPICEVMC,
+            QEMU_CAPS_DEVICE_QXL,
+            QEMU_CAPS_HDA_DUPLEX,
+            QEMU_CAPS_USB_REDIR);
      DO_TEST("pcie-root",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
-            QEMU_CAPS_DEVICE_IOH3420, QEMU_CAPS_ICH9_AHCI,
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_IOH3420,
+            QEMU_CAPS_ICH9_AHCI,
              QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
              QEMU_CAPS_DEVICE_QXL);
      DO_TEST("pcie-root-port",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
-            QEMU_CAPS_DEVICE_IOH3420, QEMU_CAPS_ICH9_AHCI,
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_IOH3420,
+            QEMU_CAPS_ICH9_AHCI,
              QEMU_CAPS_PCI_MULTIFUNCTION,
              QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
              QEMU_CAPS_DEVICE_QXL);
      DO_TEST("pcie-switch-upstream-port",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
-            QEMU_CAPS_DEVICE_IOH3420, QEMU_CAPS_ICH9_AHCI,
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_IOH3420,
+            QEMU_CAPS_DEVICE_X3130_UPSTREAM,
+            QEMU_CAPS_ICH9_AHCI,
              QEMU_CAPS_PCI_MULTIFUNCTION,
              QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
              QEMU_CAPS_DEVICE_QXL);
      DO_TEST("pcie-switch-downstream-port",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
-            QEMU_CAPS_DEVICE_IOH3420, QEMU_CAPS_ICH9_AHCI,
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_IOH3420,
+            QEMU_CAPS_DEVICE_X3130_UPSTREAM,
+            QEMU_CAPS_DEVICE_XIO3130_DOWNSTREAM,
+            QEMU_CAPS_ICH9_AHCI,
              QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
              QEMU_CAPS_DEVICE_QXL);
      DO_TEST("pci-expander-bus",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_DEVICE_PXB);
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_PXB);
      DO_TEST("pcie-expander-bus",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
-            QEMU_CAPS_DEVICE_IOH3420, QEMU_CAPS_DEVICE_X3130_UPSTREAM,
-            QEMU_CAPS_DEVICE_XIO3130_DOWNSTREAM, QEMU_CAPS_DEVICE_PXB_PCIE);
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_IOH3420,
+            QEMU_CAPS_DEVICE_X3130_UPSTREAM,
+            QEMU_CAPS_DEVICE_XIO3130_DOWNSTREAM,
+            QEMU_CAPS_DEVICE_PXB_PCIE);
      DO_TEST("autoindex",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
-            QEMU_CAPS_DEVICE_IOH3420, QEMU_CAPS_DEVICE_X3130_UPSTREAM,
-            QEMU_CAPS_DEVICE_XIO3130_DOWNSTREAM, QEMU_CAPS_ICH9_AHCI,
-            QEMU_CAPS_PCI_MULTIFUNCTION, QEMU_CAPS_ICH9_USB_EHCI1,
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_IOH3420,
+            QEMU_CAPS_DEVICE_X3130_UPSTREAM,
+            QEMU_CAPS_DEVICE_XIO3130_DOWNSTREAM,
+            QEMU_CAPS_ICH9_AHCI,
+            QEMU_CAPS_PCI_MULTIFUNCTION,
+            QEMU_CAPS_ICH9_USB_EHCI1,
              QEMU_CAPS_NEC_USB_XHCI);
      /* Make sure the user can always override libvirt's default device
       * placement policy by providing an explicit PCI address */
@@ -944,9 +1009,11 @@ mymain(void)
      DO_TEST("pcihole64-gib", NONE);
      DO_TEST("pcihole64-none", NONE);
      DO_TEST("pcihole64-q35",
-            QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_IOH3420,
-            QEMU_CAPS_ICH9_AHCI, QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
+            QEMU_CAPS_ICH9_AHCI,
+            QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
              QEMU_CAPS_DEVICE_QXL,
              QEMU_CAPS_Q35_PCI_HOLE64_SIZE);
@@ -1049,6 +1116,12 @@ mymain(void) DO_TEST("acpi-table", NONE); + DO_TEST("video-device-pciaddr-default",
+            QEMU_CAPS_KVM,
+            QEMU_CAPS_VNC,
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_DEVICE_VIDEO_PRIMARY,
+            QEMU_CAPS_DEVICE_QXL);
      DO_TEST("video-qxl-heads", NONE);
      DO_TEST("video-qxl-noheads", NONE);
      DO_TEST("video-virtio-gpu-secondary", NONE);
@@ -1056,7 +1129,12 @@ mymain(void)
      DO_TEST("intel-iommu",
              QEMU_CAPS_DEVICE_PCI_BRIDGE,
              QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
-            QEMU_CAPS_DEVICE_IOH3420);
+            QEMU_CAPS_DEVICE_INTEL_IOMMU);
+    DO_TEST("intel-iommu-machine",
+            QEMU_CAPS_DEVICE_PCI_BRIDGE,
+            QEMU_CAPS_MACHINE_OPT,
+            QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE,
+            QEMU_CAPS_MACHINE_IOMMU);
qemuTestDriverFree(&driver);


--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]
  Powered by Linux