[PATCH 4/6] tests: Reduce usage of legacy PCI controllers on PCIe machines

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

 



Up until a while ago, libvirt would automatically add a legacy
PCI controllers combo (dmi-to-pci-bridge + pci-bridge) to any
PCIe machine type (x86_64/q35 and aarch64/virt).

As a result, a number of input and output files in the test
suite ended up containing the legacy PCI controllers, even
though they are not needed or in any way relevant to the
feature being tested.

Get rid of most of the occurrences. Most of the time, this
just means removing the controllers from the input file and
regenerating the output files; in a few instances, some
minor tweaking is performed on the input file, most notably
removing the memory balloon: as memory balloon support was
not the scope of the test being changed, there is no loss
of test coverage from doing so.

Several occurrences of the legacy PCI controllers remain in
the test suite, both because removing their usage would have
required even more tweaking, and because we still want to
have coverage of this perfectly valid combination.
---
 .../qemuxml2argv-boot-floppy-q35.args              |   5 +-
 .../qemuxml2argv-boot-floppy-q35.xml               |  10 +-
 .../qemuxml2argv-bootindex-floppy-q35.args         |   5 +-
 .../qemuxml2argv-bootindex-floppy-q35.xml          |  10 +-
 .../qemuxml2argv-intel-iommu-machine.args          |   5 +-
 .../qemuxml2argv-intel-iommu-machine.xml           |  13 +-
 .../qemuxml2argvdata/qemuxml2argv-intel-iommu.args |   5 +-
 .../qemuxml2argvdata/qemuxml2argv-intel-iommu.xml  |  13 +-
 .../qemuxml2argv-pcie-expander-bus-bad-bus.xml     |  18 +-
 .../qemuxml2argv-pcie-expander-bus.args            | 136 ++++++-------
 .../qemuxml2argv-pcie-expander-bus.xml             |  85 ++++----
 .../qemuxml2argv-pcie-root-port-too-many.xml       |   6 +-
 .../qemuxml2argv-pcie-root-port.args               |   6 +-
 .../qemuxml2argv-pcie-root-port.xml                |   6 +-
 .../qemuxml2argv-pcie-switch-downstream-port.args  |  22 +-
 .../qemuxml2argv-pcie-switch-downstream-port.xml   |  18 +-
 .../qemuxml2argv-pcie-switch-upstream-port.args    |  10 +-
 .../qemuxml2argv-pcie-switch-upstream-port.xml     |  10 +-
 .../qemuxml2argv-pcihole64-q35.args                |   2 -
 .../qemuxml2argv-pcihole64-q35.xml                 |   2 -
 .../qemuxml2argv-q35-dmi-bad-address1.xml          |   5 +-
 .../qemuxml2argv-q35-dmi-bad-address2.xml          |  21 +-
 .../qemuxml2argv-q35-wrong-root.xml                |   7 -
 tests/qemuxml2argvdata/qemuxml2argv-q35.args       |   2 -
 tests/qemuxml2argvdata/qemuxml2argv-q35.xml        |   7 -
 .../qemuxml2argv-usb-controller-default-q35.args   |   2 -
 .../qemuxml2argv-usb-controller-default-q35.xml    |   5 -
 .../qemuxml2argv-usb-controller-explicit-q35.args  |   2 -
 .../qemuxml2argv-usb-controller-explicit-q35.xml   |   5 -
 .../qemuxml2argv-vcpu-placement-static.xml         |   6 -
 .../qemuxml2xmlout-intel-iommu.xml                 |  13 +-
 .../qemuxml2xmlout-pcie-expander-bus.xml           | 225 ++++++++++-----------
 .../qemuxml2xmlout-pcie-root-port.xml              |  15 +-
 .../qemuxml2xmlout-pcie-switch-downstream-port.xml |  61 +++---
 .../qemuxml2xmlout-pcie-switch-upstream-port.xml   |  25 +--
 .../qemuxml2xmlout-pcihole64-q35.xml               |   9 -
 tests/qemuxml2xmloutdata/qemuxml2xmlout-q35.xml    |   9 -
 .../qemuxml2xmlout-usb-controller-default-q35.xml  |   9 -
 .../qemuxml2xmlout-usb-controller-explicit-q35.xml |   9 -
 .../qemuxml2xmlout-vcpu-placement-static.xml       |   9 -
 40 files changed, 300 insertions(+), 533 deletions(-)

diff --git a/tests/qemuxml2argvdata/qemuxml2argv-boot-floppy-q35.args b/tests/qemuxml2argvdata/qemuxml2argv-boot-floppy-q35.args
index b9c6126..caaf758 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-boot-floppy-q35.args
+++ b/tests/qemuxml2argvdata/qemuxml2argv-boot-floppy-q35.args
@@ -16,8 +16,5 @@ QEMU_AUDIO_DRV=none \
 -monitor unix:/tmp/lib/domain--1-QEMUGuest1/monitor.sock,server,nowait \
 -no-acpi \
 -boot a \
--device i82801b11-bridge,id=pci.1,bus=pcie.0,addr=0x1e \
--device pci-bridge,chassis_nr=2,id=pci.2,bus=pci.1,addr=0x1 \
 -drive file=/tmp/firmware.img,format=raw,if=none,id=drive-fdc0-0-0 \
--device isa-fdc,driveA=drive-fdc0-0-0 \
--device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x3
+-device isa-fdc,driveA=drive-fdc0-0-0
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-boot-floppy-q35.xml b/tests/qemuxml2argvdata/qemuxml2argv-boot-floppy-q35.xml
index 70d3262..b94ad85 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-boot-floppy-q35.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-boot-floppy-q35.xml
@@ -24,17 +24,9 @@
       <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
     </controller>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <address type='pci' domain='0x0000' bus='0x01' slot='0x01' function='0x0'/>
-    </controller>
     <controller type='fdc' index='0'/>
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
-    <memballoon model='virtio'>
-      <address type='pci' domain='0x0000' bus='0x02' slot='0x03' function='0x0'/>
-    </memballoon>
+    <memballoon model='none'/>
   </devices>
 </domain>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-bootindex-floppy-q35.args b/tests/qemuxml2argvdata/qemuxml2argv-bootindex-floppy-q35.args
index 8bcdc1f..10ae65e 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-bootindex-floppy-q35.args
+++ b/tests/qemuxml2argvdata/qemuxml2argv-bootindex-floppy-q35.args
@@ -15,8 +15,5 @@ QEMU_AUDIO_DRV=none \
 -nodefaults \
 -monitor unix:/tmp/lib/domain--1-QEMUGuest1/monitor.sock,server,nowait \
 -no-acpi \
--device i82801b11-bridge,id=pci.1,bus=pcie.0,addr=0x1e \
--device pci-bridge,chassis_nr=2,id=pci.2,bus=pci.1,addr=0x1 \
 -drive file=/tmp/firmware.img,format=raw,if=none,id=drive-fdc0-0-0 \
--device isa-fdc,driveA=drive-fdc0-0-0,bootindexA=1 \
--device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x3
+-device isa-fdc,driveA=drive-fdc0-0-0,bootindexA=1
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-bootindex-floppy-q35.xml b/tests/qemuxml2argvdata/qemuxml2argv-bootindex-floppy-q35.xml
index 70d3262..b94ad85 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-bootindex-floppy-q35.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-bootindex-floppy-q35.xml
@@ -24,17 +24,9 @@
       <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
     </controller>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <address type='pci' domain='0x0000' bus='0x01' slot='0x01' function='0x0'/>
-    </controller>
     <controller type='fdc' index='0'/>
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
-    <memballoon model='virtio'>
-      <address type='pci' domain='0x0000' bus='0x02' slot='0x03' function='0x0'/>
-    </memballoon>
+    <memballoon model='none'/>
   </devices>
 </domain>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-intel-iommu-machine.args b/tests/qemuxml2argvdata/qemuxml2argv-intel-iommu-machine.args
index 9221b79..91e37e3 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-intel-iommu-machine.args
+++ b/tests/qemuxml2argvdata/qemuxml2argv-intel-iommu-machine.args
@@ -15,7 +15,4 @@ QEMU_AUDIO_DRV=none \
 -nodefaults \
 -monitor unix:/tmp/lib/domain--1-QEMUGuest1/monitor.sock,server,nowait \
 -no-acpi \
--boot c \
--device i82801b11-bridge,id=pci.1,bus=pcie.0,addr=0x1e \
--device pci-bridge,chassis_nr=2,id=pci.2,bus=pci.1,addr=0x0 \
--device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x1
+-boot c
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-intel-iommu-machine.xml b/tests/qemuxml2argvdata/qemuxml2argv-intel-iommu-machine.xml
index b5b2b51..de921f6 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-intel-iommu-machine.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-intel-iommu-machine.xml
@@ -15,23 +15,12 @@
   <devices>
     <emulator>/usr/bin/qemu</emulator>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
-      <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='2'/>
-      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
-    </controller>
     <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='virtio'>
-      <address type='pci' domain='0x0000' bus='0x02' slot='0x01' function='0x0'/>
-    </memballoon>
+    <memballoon model='none'/>
     <iommu model='intel'/>
   </devices>
 </domain>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-intel-iommu.args b/tests/qemuxml2argvdata/qemuxml2argv-intel-iommu.args
index fc64405..dfc2183 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-intel-iommu.args
+++ b/tests/qemuxml2argvdata/qemuxml2argv-intel-iommu.args
@@ -16,7 +16,4 @@ QEMU_AUDIO_DRV=none \
 -monitor unix:/tmp/lib/domain--1-QEMUGuest1/monitor.sock,server,nowait \
 -no-acpi \
 -boot c \
--device intel-iommu \
--device i82801b11-bridge,id=pci.1,bus=pcie.0,addr=0x1e \
--device pci-bridge,chassis_nr=2,id=pci.2,bus=pci.1,addr=0x0 \
--device virtio-balloon-pci,id=balloon0,bus=pci.2,addr=0x1
+-device intel-iommu
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-intel-iommu.xml b/tests/qemuxml2argvdata/qemuxml2argv-intel-iommu.xml
index b5b2b51..de921f6 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-intel-iommu.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-intel-iommu.xml
@@ -15,23 +15,12 @@
   <devices>
     <emulator>/usr/bin/qemu</emulator>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
-      <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='2'/>
-      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
-    </controller>
     <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='virtio'>
-      <address type='pci' domain='0x0000' bus='0x02' slot='0x01' function='0x0'/>
-    </memballoon>
+    <memballoon model='none'/>
     <iommu model='intel'/>
   </devices>
 </domain>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-pcie-expander-bus-bad-bus.xml b/tests/qemuxml2argvdata/qemuxml2argv-pcie-expander-bus-bad-bus.xml
index 0305f35..4f4b0e6 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-pcie-expander-bus-bad-bus.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-pcie-expander-bus-bad-bus.xml
@@ -27,21 +27,9 @@
       <address type='drive' controller='0' bus='0' target='0' unit='0'/>
     </disk>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='56'/>
-    </controller>
-    <controller type='pci' index='3' model='pcie-root-port'>
-      <target busNr='220'>
-        <node>1</node>
-      </target>
-      <address type='pci' bus='0x00'/>
-    </controller>
-    <controller type='pci' index='4' model='pcie-expander-bus'>
-      <address type='pci' bus='3'/>
+    <controller type='pci' index='1' model='pcie-root-port'/>
+    <controller type='pci' index='2' model='pcie-expander-bus'>
+      <address type='pci' bus='1'/>
     </controller>
     <memballoon model='none'/>
   </devices>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-pcie-expander-bus.args b/tests/qemuxml2argvdata/qemuxml2argv-pcie-expander-bus.args
index 7ce957c..92199ee 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-pcie-expander-bus.args
+++ b/tests/qemuxml2argvdata/qemuxml2argv-pcie-expander-bus.args
@@ -19,106 +19,104 @@ QEMU_AUDIO_DRV=none \
 nowait \
 -no-acpi \
 -boot c \
--device i82801b11-bridge,id=pci.1,bus=pcie.0,addr=0x1e \
--device pci-bridge,chassis_nr=56,id=pci.2,bus=pci.1,addr=0x0 \
--device pxb-pcie,bus_nr=254,id=pci.3,numa_node=0,bus=pcie.0,addr=0x4 \
--device ioh3420,port=0x0,chassis=4,id=pci.4,bus=pci.3,addr=0x0 \
--device x3130-upstream,id=pci.5,bus=pci.4,addr=0x0 \
--device xio3130-downstream,port=0x0,chassis=6,id=pci.6,bus=pci.5,addr=0x0 \
--device xio3130-downstream,port=0x1,chassis=7,id=pci.7,bus=pci.5,addr=0x1 \
--device xio3130-downstream,port=0x2,chassis=8,id=pci.8,bus=pci.5,addr=0x2 \
--device xio3130-downstream,port=0x3,chassis=9,id=pci.9,bus=pci.5,addr=0x3 \
--device xio3130-downstream,port=0x4,chassis=10,id=pci.10,bus=pci.5,addr=0x4 \
--device xio3130-downstream,port=0x5,chassis=11,id=pci.11,bus=pci.5,addr=0x5 \
--device xio3130-downstream,port=0x6,chassis=12,id=pci.12,bus=pci.5,addr=0x6 \
--device xio3130-downstream,port=0x7,chassis=13,id=pci.13,bus=pci.5,addr=0x7 \
--device xio3130-downstream,port=0x8,chassis=14,id=pci.14,bus=pci.5,addr=0x8 \
--device xio3130-downstream,port=0x9,chassis=15,id=pci.15,bus=pci.5,addr=0x9 \
--device xio3130-downstream,port=0xa,chassis=16,id=pci.16,bus=pci.5,addr=0xa \
--device xio3130-downstream,port=0xb,chassis=17,id=pci.17,bus=pci.5,addr=0xb \
--device xio3130-downstream,port=0xc,chassis=18,id=pci.18,bus=pci.5,addr=0xc \
--device xio3130-downstream,port=0xd,chassis=19,id=pci.19,bus=pci.5,addr=0xd \
--device xio3130-downstream,port=0xe,chassis=20,id=pci.20,bus=pci.5,addr=0xe \
--device xio3130-downstream,port=0xf,chassis=21,id=pci.21,bus=pci.5,addr=0xf \
--device xio3130-downstream,port=0x10,chassis=22,id=pci.22,bus=pci.5,addr=0x10 \
--device xio3130-downstream,port=0x11,chassis=23,id=pci.23,bus=pci.5,addr=0x11 \
--device xio3130-downstream,port=0x12,chassis=24,id=pci.24,bus=pci.5,addr=0x12 \
--device xio3130-downstream,port=0x13,chassis=25,id=pci.25,bus=pci.5,addr=0x13 \
--device xio3130-downstream,port=0x14,chassis=26,id=pci.26,bus=pci.5,addr=0x14 \
--device xio3130-downstream,port=0x15,chassis=27,id=pci.27,bus=pci.5,addr=0x15 \
--device xio3130-downstream,port=0x16,chassis=28,id=pci.28,bus=pci.5,addr=0x16 \
--device xio3130-downstream,port=0x17,chassis=29,id=pci.29,bus=pci.5,addr=0x17 \
--device xio3130-downstream,port=0x18,chassis=30,id=pci.30,bus=pci.5,addr=0x18 \
--device xio3130-downstream,port=0x19,chassis=31,id=pci.31,bus=pci.5,addr=0x19 \
--device xio3130-downstream,port=0x1a,chassis=32,id=pci.32,bus=pci.5,addr=0x1a \
--device xio3130-downstream,port=0x1b,chassis=33,id=pci.33,bus=pci.5,addr=0x1b \
--device xio3130-downstream,port=0x1c,chassis=34,id=pci.34,bus=pci.5,addr=0x1c \
--device xio3130-downstream,port=0x1d,chassis=35,id=pci.35,bus=pci.5,addr=0x1d \
--device xio3130-downstream,port=0x1e,chassis=36,id=pci.36,bus=pci.5,addr=0x1e \
--device xio3130-downstream,port=0x1f,chassis=37,id=pci.37,bus=pci.5,addr=0x1f \
+-device pxb-pcie,bus_nr=254,id=pci.1,numa_node=0,bus=pcie.0,addr=0x4 \
+-device ioh3420,port=0x0,chassis=2,id=pci.2,bus=pci.1,addr=0x0 \
+-device x3130-upstream,id=pci.3,bus=pci.2,addr=0x0 \
+-device xio3130-downstream,port=0x0,chassis=4,id=pci.4,bus=pci.3,addr=0x0 \
+-device xio3130-downstream,port=0x1,chassis=5,id=pci.5,bus=pci.3,addr=0x1 \
+-device xio3130-downstream,port=0x2,chassis=6,id=pci.6,bus=pci.3,addr=0x2 \
+-device xio3130-downstream,port=0x3,chassis=7,id=pci.7,bus=pci.3,addr=0x3 \
+-device xio3130-downstream,port=0x4,chassis=8,id=pci.8,bus=pci.3,addr=0x4 \
+-device xio3130-downstream,port=0x5,chassis=9,id=pci.9,bus=pci.3,addr=0x5 \
+-device xio3130-downstream,port=0x6,chassis=10,id=pci.10,bus=pci.3,addr=0x6 \
+-device xio3130-downstream,port=0x7,chassis=11,id=pci.11,bus=pci.3,addr=0x7 \
+-device xio3130-downstream,port=0x8,chassis=12,id=pci.12,bus=pci.3,addr=0x8 \
+-device xio3130-downstream,port=0x9,chassis=13,id=pci.13,bus=pci.3,addr=0x9 \
+-device xio3130-downstream,port=0xa,chassis=14,id=pci.14,bus=pci.3,addr=0xa \
+-device xio3130-downstream,port=0xb,chassis=15,id=pci.15,bus=pci.3,addr=0xb \
+-device xio3130-downstream,port=0xc,chassis=16,id=pci.16,bus=pci.3,addr=0xc \
+-device xio3130-downstream,port=0xd,chassis=17,id=pci.17,bus=pci.3,addr=0xd \
+-device xio3130-downstream,port=0xe,chassis=18,id=pci.18,bus=pci.3,addr=0xe \
+-device xio3130-downstream,port=0xf,chassis=19,id=pci.19,bus=pci.3,addr=0xf \
+-device xio3130-downstream,port=0x10,chassis=20,id=pci.20,bus=pci.3,addr=0x10 \
+-device xio3130-downstream,port=0x11,chassis=21,id=pci.21,bus=pci.3,addr=0x11 \
+-device xio3130-downstream,port=0x12,chassis=22,id=pci.22,bus=pci.3,addr=0x12 \
+-device xio3130-downstream,port=0x13,chassis=23,id=pci.23,bus=pci.3,addr=0x13 \
+-device xio3130-downstream,port=0x14,chassis=24,id=pci.24,bus=pci.3,addr=0x14 \
+-device xio3130-downstream,port=0x15,chassis=25,id=pci.25,bus=pci.3,addr=0x15 \
+-device xio3130-downstream,port=0x16,chassis=26,id=pci.26,bus=pci.3,addr=0x16 \
+-device xio3130-downstream,port=0x17,chassis=27,id=pci.27,bus=pci.3,addr=0x17 \
+-device xio3130-downstream,port=0x18,chassis=28,id=pci.28,bus=pci.3,addr=0x18 \
+-device xio3130-downstream,port=0x19,chassis=29,id=pci.29,bus=pci.3,addr=0x19 \
+-device xio3130-downstream,port=0x1a,chassis=30,id=pci.30,bus=pci.3,addr=0x1a \
+-device xio3130-downstream,port=0x1b,chassis=31,id=pci.31,bus=pci.3,addr=0x1b \
+-device xio3130-downstream,port=0x1c,chassis=32,id=pci.32,bus=pci.3,addr=0x1c \
+-device xio3130-downstream,port=0x1d,chassis=33,id=pci.33,bus=pci.3,addr=0x1d \
+-device xio3130-downstream,port=0x1e,chassis=34,id=pci.34,bus=pci.3,addr=0x1e \
+-device xio3130-downstream,port=0x1f,chassis=35,id=pci.35,bus=pci.3,addr=0x1f \
 -drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-sata0-0-0 \
 -device ide-drive,bus=ide.0,drive=drive-sata0-0-0,id=sata0-0-0 \
--device rtl8139,vlan=0,id=net0,mac=52:54:00:f1:95:51,bus=pci.6,addr=0x0 \
+-device rtl8139,vlan=0,id=net0,mac=52:54:00:f1:95:51,bus=pci.4,addr=0x0 \
 -net user,vlan=0,name=hostnet0 \
--device e1000,vlan=1,id=net1,mac=52:54:00:5c:c6:1a,bus=pci.7,addr=0x0 \
+-device e1000,vlan=1,id=net1,mac=52:54:00:5c:c6:1a,bus=pci.5,addr=0x0 \
 -net user,vlan=1,name=hostnet1 \
--device e1000,vlan=2,id=net2,mac=52:54:00:39:97:ac,bus=pci.8,addr=0x0 \
+-device e1000,vlan=2,id=net2,mac=52:54:00:39:97:ac,bus=pci.6,addr=0x0 \
 -net user,vlan=2,name=hostnet2 \
--device e1000,vlan=3,id=net3,mac=52:54:00:ee:b9:a8,bus=pci.9,addr=0x0 \
+-device e1000,vlan=3,id=net3,mac=52:54:00:ee:b9:a8,bus=pci.7,addr=0x0 \
 -net user,vlan=3,name=hostnet3 \
--device e1000,vlan=4,id=net4,mac=52:54:00:a9:f7:17,bus=pci.10,addr=0x0 \
+-device e1000,vlan=4,id=net4,mac=52:54:00:a9:f7:17,bus=pci.8,addr=0x0 \
 -net user,vlan=4,name=hostnet4 \
--device e1000,vlan=5,id=net5,mac=52:54:00:df:2b:f3,bus=pci.11,addr=0x0 \
+-device e1000,vlan=5,id=net5,mac=52:54:00:df:2b:f3,bus=pci.9,addr=0x0 \
 -net user,vlan=5,name=hostnet5 \
--device e1000,vlan=6,id=net6,mac=52:54:00:78:94:b4,bus=pci.12,addr=0x0 \
+-device e1000,vlan=6,id=net6,mac=52:54:00:78:94:b4,bus=pci.10,addr=0x0 \
 -net user,vlan=6,name=hostnet6 \
--device e1000,vlan=7,id=net7,mac=52:54:00:6b:9b:06,bus=pci.13,addr=0x0 \
+-device e1000,vlan=7,id=net7,mac=52:54:00:6b:9b:06,bus=pci.11,addr=0x0 \
 -net user,vlan=7,name=hostnet7 \
--device e1000,vlan=8,id=net8,mac=52:54:00:17:df:bc,bus=pci.14,addr=0x0 \
+-device e1000,vlan=8,id=net8,mac=52:54:00:17:df:bc,bus=pci.12,addr=0x0 \
 -net user,vlan=8,name=hostnet8 \
--device e1000,vlan=9,id=net9,mac=52:54:00:3b:d0:51,bus=pci.15,addr=0x0 \
+-device e1000,vlan=9,id=net9,mac=52:54:00:3b:d0:51,bus=pci.13,addr=0x0 \
 -net user,vlan=9,name=hostnet9 \
--device e1000,vlan=10,id=net10,mac=52:54:00:8d:2d:17,bus=pci.16,addr=0x0 \
+-device e1000,vlan=10,id=net10,mac=52:54:00:8d:2d:17,bus=pci.14,addr=0x0 \
 -net user,vlan=10,name=hostnet10 \
--device e1000,vlan=11,id=net11,mac=52:54:00:a7:66:af,bus=pci.17,addr=0x0 \
+-device e1000,vlan=11,id=net11,mac=52:54:00:a7:66:af,bus=pci.15,addr=0x0 \
 -net user,vlan=11,name=hostnet11 \
--device e1000,vlan=12,id=net12,mac=52:54:00:54:ab:d7,bus=pci.18,addr=0x0 \
+-device e1000,vlan=12,id=net12,mac=52:54:00:54:ab:d7,bus=pci.16,addr=0x0 \
 -net user,vlan=12,name=hostnet12 \
--device e1000,vlan=13,id=net13,mac=52:54:00:1f:99:90,bus=pci.19,addr=0x0 \
+-device e1000,vlan=13,id=net13,mac=52:54:00:1f:99:90,bus=pci.17,addr=0x0 \
 -net user,vlan=13,name=hostnet13 \
--device e1000,vlan=14,id=net14,mac=52:54:00:c8:43:87,bus=pci.20,addr=0x0 \
+-device e1000,vlan=14,id=net14,mac=52:54:00:c8:43:87,bus=pci.18,addr=0x0 \
 -net user,vlan=14,name=hostnet14 \
--device e1000,vlan=15,id=net15,mac=52:54:00:df:22:b2,bus=pci.21,addr=0x0 \
+-device e1000,vlan=15,id=net15,mac=52:54:00:df:22:b2,bus=pci.19,addr=0x0 \
 -net user,vlan=15,name=hostnet15 \
--device e1000,vlan=16,id=net16,mac=52:54:00:d2:9a:47,bus=pci.22,addr=0x0 \
+-device e1000,vlan=16,id=net16,mac=52:54:00:d2:9a:47,bus=pci.20,addr=0x0 \
 -net user,vlan=16,name=hostnet16 \
--device e1000,vlan=17,id=net17,mac=52:54:00:86:05:e2,bus=pci.23,addr=0x0 \
+-device e1000,vlan=17,id=net17,mac=52:54:00:86:05:e2,bus=pci.21,addr=0x0 \
 -net user,vlan=17,name=hostnet17 \
--device e1000,vlan=18,id=net18,mac=52:54:00:8c:1c:c2,bus=pci.24,addr=0x0 \
+-device e1000,vlan=18,id=net18,mac=52:54:00:8c:1c:c2,bus=pci.22,addr=0x0 \
 -net user,vlan=18,name=hostnet18 \
--device e1000,vlan=19,id=net19,mac=52:54:00:48:58:92,bus=pci.25,addr=0x0 \
+-device e1000,vlan=19,id=net19,mac=52:54:00:48:58:92,bus=pci.23,addr=0x0 \
 -net user,vlan=19,name=hostnet19 \
--device e1000,vlan=20,id=net20,mac=52:54:00:99:e5:bf,bus=pci.26,addr=0x0 \
+-device e1000,vlan=20,id=net20,mac=52:54:00:99:e5:bf,bus=pci.24,addr=0x0 \
 -net user,vlan=20,name=hostnet20 \
--device e1000,vlan=21,id=net21,mac=52:54:00:b1:8c:25,bus=pci.27,addr=0x0 \
+-device e1000,vlan=21,id=net21,mac=52:54:00:b1:8c:25,bus=pci.25,addr=0x0 \
 -net user,vlan=21,name=hostnet21 \
--device e1000,vlan=22,id=net22,mac=52:54:00:60:e0:d0,bus=pci.28,addr=0x0 \
+-device e1000,vlan=22,id=net22,mac=52:54:00:60:e0:d0,bus=pci.26,addr=0x0 \
 -net user,vlan=22,name=hostnet22 \
--device e1000,vlan=23,id=net23,mac=52:54:00:37:00:6a,bus=pci.29,addr=0x0 \
+-device e1000,vlan=23,id=net23,mac=52:54:00:37:00:6a,bus=pci.27,addr=0x0 \
 -net user,vlan=23,name=hostnet23 \
--device e1000,vlan=24,id=net24,mac=52:54:00:c7:c8:ad,bus=pci.30,addr=0x0 \
+-device e1000,vlan=24,id=net24,mac=52:54:00:c7:c8:ad,bus=pci.28,addr=0x0 \
 -net user,vlan=24,name=hostnet24 \
--device e1000,vlan=25,id=net25,mac=52:54:00:4e:a7:cf,bus=pci.31,addr=0x0 \
+-device e1000,vlan=25,id=net25,mac=52:54:00:4e:a7:cf,bus=pci.29,addr=0x0 \
 -net user,vlan=25,name=hostnet25 \
--device e1000,vlan=26,id=net26,mac=52:54:00:00:79:69,bus=pci.32,addr=0x0 \
+-device e1000,vlan=26,id=net26,mac=52:54:00:00:79:69,bus=pci.30,addr=0x0 \
 -net user,vlan=26,name=hostnet26 \
--device e1000,vlan=27,id=net27,mac=52:54:00:47:00:6f,bus=pci.33,addr=0x0 \
+-device e1000,vlan=27,id=net27,mac=52:54:00:47:00:6f,bus=pci.31,addr=0x0 \
 -net user,vlan=27,name=hostnet27 \
--device e1000,vlan=28,id=net28,mac=52:54:00:2a:8c:8b,bus=pci.34,addr=0x0 \
+-device e1000,vlan=28,id=net28,mac=52:54:00:2a:8c:8b,bus=pci.32,addr=0x0 \
 -net user,vlan=28,name=hostnet28 \
--device e1000,vlan=29,id=net29,mac=52:54:00:ec:d5:e3,bus=pci.35,addr=0x0 \
+-device e1000,vlan=29,id=net29,mac=52:54:00:ec:d5:e3,bus=pci.33,addr=0x0 \
 -net user,vlan=29,name=hostnet29 \
--device e1000,vlan=30,id=net30,mac=52:54:00:7e:6e:c8,bus=pci.36,addr=0x0 \
+-device e1000,vlan=30,id=net30,mac=52:54:00:7e:6e:c8,bus=pci.34,addr=0x0 \
 -net user,vlan=30,name=hostnet30 \
--device e1000,vlan=31,id=net31,mac=52:54:00:7e:6d:c9,bus=pci.37,addr=0x0 \
+-device e1000,vlan=31,id=net31,mac=52:54:00:7e:6d:c9,bus=pci.35,addr=0x0 \
 -net user,vlan=31,name=hostnet31
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-pcie-expander-bus.xml b/tests/qemuxml2argvdata/qemuxml2argv-pcie-expander-bus.xml
index 72681ce..80f2ea6 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-pcie-expander-bus.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-pcie-expander-bus.xml
@@ -27,29 +27,24 @@
       <address type='drive' controller='0' bus='0' target='0' unit='0'/>
     </disk>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='56'/>
-    </controller>
-    <controller type='pci' index='3' model='pcie-expander-bus'>
+    <controller type='pci' index='1' model='pcie-expander-bus'>
       <model name='pxb-pcie'/>
       <target busNr='254'>
         <node>0</node>
       </target>
       <address type='pci' bus='0x00' slot='4'/>
     </controller>
-    <controller type='pci' index='4' model='pcie-root-port'>
+    <controller type='pci' index='2' model='pcie-root-port'>
       <target busNr='220'>
         <node>1</node>
       </target>
-      <address type='pci' bus='0x03'/>
+      <address type='pci' bus='0x01'/>
     </controller>
-    <controller type='pci' index='5' model='pcie-switch-upstream-port'>
-      <address type='pci' bus='0x04'/>
+    <controller type='pci' index='3' model='pcie-switch-upstream-port'>
+      <address type='pci' bus='0x02'/>
     </controller>
+    <controller type='pci' index='4' model='pcie-switch-downstream-port'/>
+    <controller type='pci' index='5' model='pcie-switch-downstream-port'/>
     <controller type='pci' index='6' model='pcie-switch-downstream-port'/>
     <controller type='pci' index='7' model='pcie-switch-downstream-port'/>
     <controller type='pci' index='8' model='pcie-switch-downstream-port'/>
@@ -80,167 +75,165 @@
     <controller type='pci' index='33' model='pcie-switch-downstream-port'/>
     <controller type='pci' index='34' model='pcie-switch-downstream-port'/>
     <controller type='pci' index='35' model='pcie-switch-downstream-port'/>
-    <controller type='pci' index='36' model='pcie-switch-downstream-port'/>
-    <controller type='pci' index='37' model='pcie-switch-downstream-port'/>
     <interface type='user'>
       <mac address='52:54:00:f1:95:51'/>
       <model type='rtl8139'/>
-      <address type='pci' bus='6'/>
+      <address type='pci' bus='4'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:5c:c6:1a'/>
       <model type='e1000'/>
-      <address type='pci' bus='07'/>
+      <address type='pci' bus='5'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:39:97:ac'/>
       <model type='e1000'/>
-      <address type='pci' bus='8'/>
+      <address type='pci' bus='6'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:ee:b9:a8'/>
       <model type='e1000'/>
-      <address type='pci' bus='9'/>
+      <address type='pci' bus='7'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:a9:f7:17'/>
       <model type='e1000'/>
-      <address type='pci' bus='10'/>
+      <address type='pci' bus='8'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:df:2b:f3'/>
       <model type='e1000'/>
-      <address type='pci' bus='11'/>
+      <address type='pci' bus='9'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:78:94:b4'/>
       <model type='e1000'/>
-      <address type='pci' bus='12'/>
+      <address type='pci' bus='10'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:6b:9b:06'/>
       <model type='e1000'/>
-      <address type='pci' bus='13'/>
+      <address type='pci' bus='11'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:17:df:bc'/>
       <model type='e1000'/>
-      <address type='pci' bus='14'/>
+      <address type='pci' bus='12'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:3b:d0:51'/>
       <model type='e1000'/>
-      <address type='pci' bus='15'/>
+      <address type='pci' bus='13'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:8d:2d:17'/>
       <model type='e1000'/>
-      <address type='pci' bus='16'/>
+      <address type='pci' bus='14'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:a7:66:af'/>
       <model type='e1000'/>
-      <address type='pci' bus='17'/>
+      <address type='pci' bus='15'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:54:ab:d7'/>
       <model type='e1000'/>
-      <address type='pci' bus='18'/>
+      <address type='pci' bus='16'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:1f:99:90'/>
       <model type='e1000'/>
-      <address type='pci' bus='19'/>
+      <address type='pci' bus='17'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:c8:43:87'/>
       <model type='e1000'/>
-      <address type='pci' bus='20'/>
+      <address type='pci' bus='18'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:df:22:b2'/>
       <model type='e1000'/>
-      <address type='pci' bus='21'/>
+      <address type='pci' bus='19'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:d2:9a:47'/>
       <model type='e1000'/>
-      <address type='pci' bus='22'/>
+      <address type='pci' bus='20'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:86:05:e2'/>
       <model type='e1000'/>
-      <address type='pci' bus='23'/>
+      <address type='pci' bus='21'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:8c:1c:c2'/>
       <model type='e1000'/>
-      <address type='pci' bus='24'/>
+      <address type='pci' bus='22'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:48:58:92'/>
       <model type='e1000'/>
-      <address type='pci' bus='25'/>
+      <address type='pci' bus='23'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:99:e5:bf'/>
       <model type='e1000'/>
-      <address type='pci' bus='26'/>
+      <address type='pci' bus='24'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:b1:8c:25'/>
       <model type='e1000'/>
-      <address type='pci' bus='27'/>
+      <address type='pci' bus='25'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:60:e0:d0'/>
       <model type='e1000'/>
-      <address type='pci' bus='28'/>
+      <address type='pci' bus='26'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:37:00:6a'/>
       <model type='e1000'/>
-      <address type='pci' bus='29'/>
+      <address type='pci' bus='27'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:c7:c8:ad'/>
       <model type='e1000'/>
-      <address type='pci' bus='30'/>
+      <address type='pci' bus='28'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:4e:a7:cf'/>
       <model type='e1000'/>
-      <address type='pci' bus='31'/>
+      <address type='pci' bus='29'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:00:79:69'/>
       <model type='e1000'/>
-      <address type='pci' bus='32'/>
+      <address type='pci' bus='30'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:47:00:6f'/>
       <model type='e1000'/>
-      <address type='pci' bus='33'/>
+      <address type='pci' bus='31'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:2a:8c:8b'/>
       <model type='e1000'/>
-      <address type='pci' bus='34'/>
+      <address type='pci' bus='32'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:ec:d5:e3'/>
       <model type='e1000'/>
-      <address type='pci' bus='35'/>
+      <address type='pci' bus='33'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:7e:6e:c8'/>
       <model type='e1000'/>
-      <address type='pci' bus='36'/>
+      <address type='pci' bus='34'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:7e:6d:c9'/>
       <model type='e1000'/>
-      <address type='pci' bus='37'/>
+      <address type='pci' bus='35'/>
     </interface>
     <memballoon model='none'/>
   </devices>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-pcie-root-port-too-many.xml b/tests/qemuxml2argvdata/qemuxml2argv-pcie-root-port-too-many.xml
index 98be1cd..5234e3b 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-pcie-root-port-too-many.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-pcie-root-port-too-many.xml
@@ -20,8 +20,8 @@
       <address type='drive' controller='0' bus='0' target='0' unit='0'/>
     </disk>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'/>
-    <controller type='pci' index='2' model='pci-bridge'/>
+    <controller type='pci' index='1' model='pcie-root-port'/>
+    <controller type='pci' index='2' model='pcie-root-port'/>
     <controller type='pci' index='3' model='pcie-root-port'/>
     <controller type='pci' index='4' model='pcie-root-port'/>
     <controller type='pci' index='5' model='pcie-root-port'/>
@@ -49,8 +49,6 @@
     <controller type='pci' index='27' model='pcie-root-port'/>
     <controller type='pci' index='28' model='pcie-root-port'/>
     <controller type='pci' index='29' model='pcie-root-port'/>
-    <controller type='pci' index='30' model='pcie-root-port'/>
-    <controller type='pci' index='31' model='pcie-root-port'/>
     <controller type='sata' index='0'/>
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-pcie-root-port.args b/tests/qemuxml2argvdata/qemuxml2argv-pcie-root-port.args
index 9a71281..4e852ff 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-pcie-root-port.args
+++ b/tests/qemuxml2argvdata/qemuxml2argv-pcie-root-port.args
@@ -16,11 +16,9 @@ QEMU_AUDIO_DRV=none \
 -monitor unix:/tmp/lib/domain--1-q35-test/monitor.sock,server,nowait \
 -no-acpi \
 -boot c \
--device i82801b11-bridge,id=pci.1,bus=pcie.0,addr=0x1e \
--device pci-bridge,chassis_nr=2,id=pci.2,bus=pci.1,addr=0x0 \
--device ioh3420,port=0x10,chassis=3,id=pci.3,bus=pcie.0,multifunction=on,\
+-device ioh3420,port=0x10,chassis=1,id=pci.1,bus=pcie.0,multifunction=on,\
 addr=0x2 \
--device ioh3420,port=0x1a,chassis=40,id=pci.4,bus=pcie.0,addr=0x2.0x1 \
+-device ioh3420,port=0x1a,chassis=40,id=pci.2,bus=pcie.0,addr=0x2.0x1 \
 -drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-sata0-0-0 \
 -device ide-drive,bus=ide.0,drive=drive-sata0-0-0,id=sata0-0-0 \
 -device qxl-vga,id=video0,ram_size=67108864,vram_size=33554432,bus=pcie.0,\
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-pcie-root-port.xml b/tests/qemuxml2argvdata/qemuxml2argv-pcie-root-port.xml
index 795f8dd..7ecc4a6 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-pcie-root-port.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-pcie-root-port.xml
@@ -20,10 +20,8 @@
       <address type='drive' controller='0' bus='0' target='0' unit='0'/>
     </disk>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'/>
-    <controller type='pci' index='2' model='pci-bridge'/>
-    <controller type='pci' index='3' model='pcie-root-port'/>
-    <controller type='pci' index='4' model='pcie-root-port'>
+    <controller type='pci' index='1' model='pcie-root-port'/>
+    <controller type='pci' index='2' model='pcie-root-port'>
       <model name='ioh3420'/>
       <target chassis='40' port='0x1a'/>
     </controller>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-pcie-switch-downstream-port.args b/tests/qemuxml2argvdata/qemuxml2argv-pcie-switch-downstream-port.args
index 3b3e80d..1102b38 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-pcie-switch-downstream-port.args
+++ b/tests/qemuxml2argvdata/qemuxml2argv-pcie-switch-downstream-port.args
@@ -16,18 +16,16 @@ QEMU_AUDIO_DRV=none \
 -monitor unix:/tmp/lib/domain--1-q35-test/monitor.sock,server,nowait \
 -no-acpi \
 -boot c \
--device i82801b11-bridge,id=pci.1,bus=pcie.0,addr=0x1e \
--device pci-bridge,chassis_nr=2,id=pci.2,bus=pci.1,addr=0x0 \
--device ioh3420,port=0x10,chassis=3,id=pci.3,bus=pcie.0,addr=0x2 \
--device x3130-upstream,id=pci.4,bus=pci.3,addr=0x0 \
--device xio3130-downstream,port=0x0,chassis=5,id=pci.5,bus=pci.4,addr=0x0 \
--device xio3130-downstream,port=0x1,chassis=6,id=pci.6,bus=pci.4,addr=0x1 \
--device xio3130-downstream,port=0x2,chassis=7,id=pci.7,bus=pci.4,addr=0x2 \
--device xio3130-downstream,port=0x27,chassis=30,id=pci.8,bus=pci.4,addr=0x3 \
--device x3130-upstream,id=pci.9,bus=pci.5,addr=0x0 \
--device xio3130-downstream,port=0x4,chassis=10,id=pci.10,bus=pci.4,addr=0x4 \
--device xio3130-downstream,port=0x5,chassis=11,id=pci.11,bus=pci.4,addr=0x5 \
--device xio3130-downstream,port=0x6,chassis=12,id=pci.12,bus=pci.4,addr=0x6 \
+-device ioh3420,port=0x10,chassis=1,id=pci.1,bus=pcie.0,addr=0x2 \
+-device x3130-upstream,id=pci.2,bus=pci.1,addr=0x0 \
+-device xio3130-downstream,port=0x0,chassis=3,id=pci.3,bus=pci.2,addr=0x0 \
+-device xio3130-downstream,port=0x1,chassis=4,id=pci.4,bus=pci.2,addr=0x1 \
+-device xio3130-downstream,port=0x2,chassis=5,id=pci.5,bus=pci.2,addr=0x2 \
+-device xio3130-downstream,port=0x27,chassis=30,id=pci.6,bus=pci.2,addr=0x3 \
+-device x3130-upstream,id=pci.7,bus=pci.3,addr=0x0 \
+-device xio3130-downstream,port=0x4,chassis=8,id=pci.8,bus=pci.2,addr=0x4 \
+-device xio3130-downstream,port=0x5,chassis=9,id=pci.9,bus=pci.2,addr=0x5 \
+-device xio3130-downstream,port=0x6,chassis=10,id=pci.10,bus=pci.2,addr=0x6 \
 -drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-sata0-0-0 \
 -device ide-drive,bus=ide.0,drive=drive-sata0-0-0,id=sata0-0-0 \
 -device qxl-vga,id=video0,ram_size=67108864,vram_size=33554432,bus=pcie.0,\
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-pcie-switch-downstream-port.xml b/tests/qemuxml2argvdata/qemuxml2argv-pcie-switch-downstream-port.xml
index b781675..578cc87 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-pcie-switch-downstream-port.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-pcie-switch-downstream-port.xml
@@ -20,21 +20,19 @@
       <address type='drive' controller='0' bus='0' target='0' unit='0'/>
     </disk>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'/>
-    <controller type='pci' index='2' model='pci-bridge'/>
-    <controller type='pci' index='3' model='pcie-root-port'/>
-    <controller type='pci' index='4' model='pcie-switch-upstream-port'/>
+    <controller type='pci' index='1' model='pcie-root-port'/>
+    <controller type='pci' index='2' model='pcie-switch-upstream-port'/>
+    <controller type='pci' index='3' model='pcie-switch-downstream-port'/>
+    <controller type='pci' index='4' model='pcie-switch-downstream-port'/>
     <controller type='pci' index='5' model='pcie-switch-downstream-port'/>
-    <controller type='pci' index='6' model='pcie-switch-downstream-port'/>
-    <controller type='pci' index='7' model='pcie-switch-downstream-port'/>
-    <controller type='pci' index='8' model='pcie-switch-downstream-port'>
+    <controller type='pci' index='6' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
       <target chassis='30' port='0x27'/>
     </controller>
-    <controller type='pci' index='9' model='pcie-switch-upstream-port'/>
+    <controller type='pci' index='7' model='pcie-switch-upstream-port'/>
+    <controller type='pci' index='8' model='pcie-switch-downstream-port'/>
+    <controller type='pci' index='9' model='pcie-switch-downstream-port'/>
     <controller type='pci' index='10' model='pcie-switch-downstream-port'/>
-    <controller type='pci' index='11' model='pcie-switch-downstream-port'/>
-    <controller type='pci' index='12' model='pcie-switch-downstream-port'/>
     <controller type='sata' index='0'/>
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-pcie-switch-upstream-port.args b/tests/qemuxml2argvdata/qemuxml2argv-pcie-switch-upstream-port.args
index 10aedd5..05db65b 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-pcie-switch-upstream-port.args
+++ b/tests/qemuxml2argvdata/qemuxml2argv-pcie-switch-upstream-port.args
@@ -16,13 +16,11 @@ QEMU_AUDIO_DRV=none \
 -monitor unix:/tmp/lib/domain--1-q35-test/monitor.sock,server,nowait \
 -no-acpi \
 -boot c \
--device i82801b11-bridge,id=pci.1,bus=pcie.0,addr=0x1e \
--device pci-bridge,chassis_nr=2,id=pci.2,bus=pci.1,addr=0x0 \
--device ioh3420,port=0x10,chassis=3,id=pci.3,bus=pcie.0,multifunction=on,\
+-device ioh3420,port=0x10,chassis=1,id=pci.1,bus=pcie.0,multifunction=on,\
 addr=0x2 \
--device ioh3420,port=0x11,chassis=4,id=pci.4,bus=pcie.0,addr=0x2.0x1 \
--device x3130-upstream,id=pci.5,bus=pci.3,addr=0x0 \
--device x3130-upstream,id=pci.6,bus=pci.4,addr=0x0 \
+-device ioh3420,port=0x11,chassis=2,id=pci.2,bus=pcie.0,addr=0x2.0x1 \
+-device x3130-upstream,id=pci.3,bus=pci.1,addr=0x0 \
+-device x3130-upstream,id=pci.4,bus=pci.2,addr=0x0 \
 -drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-sata0-0-0 \
 -device ide-drive,bus=ide.0,drive=drive-sata0-0-0,id=sata0-0-0 \
 -device qxl-vga,id=video0,ram_size=67108864,vram_size=33554432,bus=pcie.0,\
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-pcie-switch-upstream-port.xml b/tests/qemuxml2argvdata/qemuxml2argv-pcie-switch-upstream-port.xml
index 4205f8a..4caf229 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-pcie-switch-upstream-port.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-pcie-switch-upstream-port.xml
@@ -20,12 +20,10 @@
       <address type='drive' controller='0' bus='0' target='0' unit='0'/>
     </disk>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'/>
-    <controller type='pci' index='2' model='pci-bridge'/>
-    <controller type='pci' index='3' model='pcie-root-port'/>
-    <controller type='pci' index='4' model='pcie-root-port'/>
-    <controller type='pci' index='5' model='pcie-switch-upstream-port'/>
-    <controller type='pci' index='6' model='pcie-switch-upstream-port'>
+    <controller type='pci' index='1' model='pcie-root-port'/>
+    <controller type='pci' index='2' model='pcie-root-port'/>
+    <controller type='pci' index='3' model='pcie-switch-upstream-port'/>
+    <controller type='pci' index='4' model='pcie-switch-upstream-port'>
       <model name='x3130-upstream'/>
     </controller>
     <controller type='sata' index='0'/>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-pcihole64-q35.args b/tests/qemuxml2argvdata/qemuxml2argv-pcihole64-q35.args
index ee9f699..179a7c5 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-pcihole64-q35.args
+++ b/tests/qemuxml2argvdata/qemuxml2argv-pcihole64-q35.args
@@ -17,8 +17,6 @@ QEMU_AUDIO_DRV=none \
 -no-acpi \
 -boot c \
 -global q35-pcihost.pci-hole64-size=1048576K \
--device i82801b11-bridge,id=pci.1,bus=pcie.0,addr=0x1e \
--device pci-bridge,chassis_nr=2,id=pci.2,bus=pci.1,addr=0x0 \
 -drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-sata0-0-0 \
 -device ide-drive,bus=ide.0,drive=drive-sata0-0-0,id=sata0-0-0 \
 -device qxl-vga,id=video0,ram_size=67108864,vram_size=33554432,bus=pcie.0,\
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-pcihole64-q35.xml b/tests/qemuxml2argvdata/qemuxml2argv-pcihole64-q35.xml
index a967bf4..9367384 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-pcihole64-q35.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-pcihole64-q35.xml
@@ -22,8 +22,6 @@
     <controller type='pci' index='0' model='pcie-root'>
       <pcihole64 unit='KiB'>1048576</pcihole64>
     </controller>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'/>
-    <controller type='pci' index='2' model='pci-bridge'/>
     <controller type='sata' index='0'/>
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-q35-dmi-bad-address1.xml b/tests/qemuxml2argvdata/qemuxml2argv-q35-dmi-bad-address1.xml
index e23c874..05e23d9 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-q35-dmi-bad-address1.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-q35-dmi-bad-address1.xml
@@ -22,9 +22,8 @@
       <model name='pci-bridge'/>
       <target chassisNr='56'/>
     </controller>
-    <controller type='pci' index='3' model='pcie-root-port'/>
-    <controller type='pci' index='4' model='dmi-to-pci-bridge'>
-      <address type='pci' bus='2' slot='3'/>
+    <controller type='pci' index='2' model='dmi-to-pci-bridge'>
+      <address type='pci' bus='2'/>
     </controller>
     <memballoon model='none'/>
   </devices>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-q35-dmi-bad-address2.xml b/tests/qemuxml2argvdata/qemuxml2argv-q35-dmi-bad-address2.xml
index c3c1b6a..7796e52 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-q35-dmi-bad-address2.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-q35-dmi-bad-address2.xml
@@ -14,26 +14,11 @@
   <on_crash>destroy</on_crash>
   <devices>
     <emulator>/usr/libexec/qemu-kvm</emulator>
-    <disk type='block' device='disk'>
-      <source dev='/dev/HostVG/QEMUGuest1'/>
-      <target dev='sda' bus='sata'/>
-      <address type='drive' controller='0' bus='0' target='0' unit='0'/>
-    </disk>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
+    <controller type='pci' index='1' model='pcie-root-port'/>
+    <controller type='pci' index='2' model='dmi-to-pci-bridge'>
+      <address type='pci' bus='1'/>
     </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='56'/>
-    </controller>
-    <controller type='pci' index='3' model='pcie-root-port'/>
-    <controller type='pci' index='4' model='dmi-to-pci-bridge'>
-      <address type='pci' bus='3'/>
-    </controller>
-    <video>
-      <model type='qxl' ram='65536' vram='32768' vgamem='8192' heads='1'/>
-    </video>
     <memballoon model='none'/>
   </devices>
 </domain>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-q35-wrong-root.xml b/tests/qemuxml2argvdata/qemuxml2argv-q35-wrong-root.xml
index 836de52..8d9f27d 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-q35-wrong-root.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-q35-wrong-root.xml
@@ -15,13 +15,6 @@
   <devices>
     <emulator>/usr/bin/qemu-kvm</emulator>
     <controller type='pci' index='0' model='pci-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='56'/>
-    </controller>
     <memballoon model='none'/>
   </devices>
 </domain>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-q35.args b/tests/qemuxml2argvdata/qemuxml2argv-q35.args
index 733a4dc..e572e8c 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-q35.args
+++ b/tests/qemuxml2argvdata/qemuxml2argv-q35.args
@@ -16,8 +16,6 @@ QEMU_AUDIO_DRV=none \
 -monitor unix:/tmp/lib/domain--1-q35-test/monitor.sock,server,nowait \
 -no-acpi \
 -boot c \
--device i82801b11-bridge,id=pci.1,bus=pcie.0,addr=0x1e \
--device pci-bridge,chassis_nr=56,id=pci.2,bus=pci.1,addr=0x0 \
 -device ich9-usb-ehci1,id=usb,bus=pcie.0,addr=0x1d.0x7 \
 -device ich9-usb-uhci1,masterbus=usb.0,firstport=0,bus=pcie.0,multifunction=on,\
 addr=0x1d \
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-q35.xml b/tests/qemuxml2argvdata/qemuxml2argv-q35.xml
index 0c3da85..85e72cd 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-q35.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-q35.xml
@@ -20,13 +20,6 @@
       <address type='drive' controller='0' bus='0' target='0' unit='0'/>
     </disk>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='56'/>
-    </controller>
     <video>
       <model type='qxl' ram='65536' vram='32768' vgamem='8192' heads='1'/>
     </video>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-usb-controller-default-q35.args b/tests/qemuxml2argvdata/qemuxml2argv-usb-controller-default-q35.args
index f45400d..36237d6 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-usb-controller-default-q35.args
+++ b/tests/qemuxml2argvdata/qemuxml2argv-usb-controller-default-q35.args
@@ -16,6 +16,4 @@ QEMU_AUDIO_DRV=none \
 -monitor unix:/tmp/lib/domain--1-q35-test/monitor.sock,server,nowait \
 -no-acpi \
 -boot c \
--device i82801b11-bridge,id=pci.1,bus=pcie.0,addr=0x1e \
--device pci-bridge,chassis_nr=56,id=pci.2,bus=pci.1,addr=0x0 \
 -device piix3-usb-uhci,id=usb,bus=pcie.0,addr=0x1
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-usb-controller-default-q35.xml b/tests/qemuxml2argvdata/qemuxml2argv-usb-controller-default-q35.xml
index 5f949d6..9c2a234 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-usb-controller-default-q35.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-usb-controller-default-q35.xml
@@ -15,11 +15,6 @@
   <devices>
     <emulator>/usr/libexec/qemu-kvm</emulator>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'/>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='56'/>
-    </controller>
     <controller type='usb' index='0'>
       <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x0'/>
     </controller>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-usb-controller-explicit-q35.args b/tests/qemuxml2argvdata/qemuxml2argv-usb-controller-explicit-q35.args
index 92a4ee3..6ea531f 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-usb-controller-explicit-q35.args
+++ b/tests/qemuxml2argvdata/qemuxml2argv-usb-controller-explicit-q35.args
@@ -16,6 +16,4 @@ QEMU_AUDIO_DRV=none \
 -monitor unix:/tmp/lib/domain--1-q35-test/monitor.sock,server,nowait \
 -no-acpi \
 -boot c \
--device i82801b11-bridge,id=pci.1,bus=pcie.0,addr=0x1e \
--device pci-bridge,chassis_nr=56,id=pci.2,bus=pci.1,addr=0x0 \
 -device nec-usb-xhci,id=usb,bus=pcie.0,addr=0x1
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-usb-controller-explicit-q35.xml b/tests/qemuxml2argvdata/qemuxml2argv-usb-controller-explicit-q35.xml
index f6d95b4..c0827f2 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-usb-controller-explicit-q35.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-usb-controller-explicit-q35.xml
@@ -15,11 +15,6 @@
   <devices>
     <emulator>/usr/libexec/qemu-kvm</emulator>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'/>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='56'/>
-    </controller>
     <controller type='usb' index='0' model='nec-xhci'>
       <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x0'/>
     </controller>
diff --git a/tests/qemuxml2argvdata/qemuxml2argv-vcpu-placement-static.xml b/tests/qemuxml2argvdata/qemuxml2argv-vcpu-placement-static.xml
index 9cd00c0..a777f50 100644
--- a/tests/qemuxml2argvdata/qemuxml2argv-vcpu-placement-static.xml
+++ b/tests/qemuxml2argvdata/qemuxml2argv-vcpu-placement-static.xml
@@ -26,12 +26,6 @@
       <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
     </controller>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <address type='pci' domain='0x0000' bus='0x01' slot='0x01' function='0x0'/>
-    </controller>
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
     <memballoon model='none'/>
diff --git a/tests/qemuxml2xmloutdata/qemuxml2xmlout-intel-iommu.xml b/tests/qemuxml2xmloutdata/qemuxml2xmlout-intel-iommu.xml
index b5b2b51..de921f6 100644
--- a/tests/qemuxml2xmloutdata/qemuxml2xmlout-intel-iommu.xml
+++ b/tests/qemuxml2xmloutdata/qemuxml2xmlout-intel-iommu.xml
@@ -15,23 +15,12 @@
   <devices>
     <emulator>/usr/bin/qemu</emulator>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
-      <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='2'/>
-      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
-    </controller>
     <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='virtio'>
-      <address type='pci' domain='0x0000' bus='0x02' slot='0x01' function='0x0'/>
-    </memballoon>
+    <memballoon model='none'/>
     <iommu model='intel'/>
   </devices>
 </domain>
diff --git a/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcie-expander-bus.xml b/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcie-expander-bus.xml
index 7a37870..377ced2 100644
--- a/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcie-expander-bus.xml
+++ b/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcie-expander-bus.xml
@@ -27,192 +27,183 @@
       <address type='drive' controller='0' bus='0' target='0' unit='0'/>
     </disk>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
-      <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='56'/>
-      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
-    </controller>
-    <controller type='pci' index='3' model='pcie-expander-bus'>
+    <controller type='pci' index='1' model='pcie-expander-bus'>
       <model name='pxb-pcie'/>
       <target busNr='254'>
         <node>0</node>
       </target>
       <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
     </controller>
-    <controller type='pci' index='4' model='pcie-root-port'>
+    <controller type='pci' index='2' model='pcie-root-port'>
       <model name='ioh3420'/>
-      <target chassis='4' port='0x0' busNr='220'>
+      <target chassis='2' port='0x0' busNr='220'>
         <node>1</node>
       </target>
-      <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
     </controller>
-    <controller type='pci' index='5' model='pcie-switch-upstream-port'>
+    <controller type='pci' index='3' model='pcie-switch-upstream-port'>
       <model name='x3130-upstream'/>
-      <address type='pci' domain='0x0000' bus='0x04' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x02' slot='0x00' function='0x0'/>
+    </controller>
+    <controller type='pci' index='4' model='pcie-switch-downstream-port'>
+      <model name='xio3130-downstream'/>
+      <target chassis='4' port='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x0'/>
+    </controller>
+    <controller type='pci' index='5' model='pcie-switch-downstream-port'>
+      <model name='xio3130-downstream'/>
+      <target chassis='5' port='0x1'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x01' function='0x0'/>
     </controller>
     <controller type='pci' index='6' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='6' port='0x0'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x00' function='0x0'/>
+      <target chassis='6' port='0x2'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x02' function='0x0'/>
     </controller>
     <controller type='pci' index='7' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='7' port='0x1'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x01' function='0x0'/>
+      <target chassis='7' port='0x3'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x03' function='0x0'/>
     </controller>
     <controller type='pci' index='8' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='8' port='0x2'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x02' function='0x0'/>
+      <target chassis='8' port='0x4'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x04' function='0x0'/>
     </controller>
     <controller type='pci' index='9' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='9' port='0x3'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x03' function='0x0'/>
+      <target chassis='9' port='0x5'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x05' function='0x0'/>
     </controller>
     <controller type='pci' index='10' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='10' port='0x4'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x04' function='0x0'/>
+      <target chassis='10' port='0x6'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x06' function='0x0'/>
     </controller>
     <controller type='pci' index='11' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='11' port='0x5'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x05' function='0x0'/>
+      <target chassis='11' port='0x7'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x07' function='0x0'/>
     </controller>
     <controller type='pci' index='12' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='12' port='0x6'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x06' function='0x0'/>
+      <target chassis='12' port='0x8'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x08' function='0x0'/>
     </controller>
     <controller type='pci' index='13' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='13' port='0x7'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x07' function='0x0'/>
+      <target chassis='13' port='0x9'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x09' function='0x0'/>
     </controller>
     <controller type='pci' index='14' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='14' port='0x8'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x08' function='0x0'/>
+      <target chassis='14' port='0xa'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x0a' function='0x0'/>
     </controller>
     <controller type='pci' index='15' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='15' port='0x9'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x09' function='0x0'/>
+      <target chassis='15' port='0xb'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x0b' function='0x0'/>
     </controller>
     <controller type='pci' index='16' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='16' port='0xa'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x0a' function='0x0'/>
+      <target chassis='16' port='0xc'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x0c' function='0x0'/>
     </controller>
     <controller type='pci' index='17' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='17' port='0xb'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x0b' function='0x0'/>
+      <target chassis='17' port='0xd'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x0d' function='0x0'/>
     </controller>
     <controller type='pci' index='18' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='18' port='0xc'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x0c' function='0x0'/>
+      <target chassis='18' port='0xe'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x0e' function='0x0'/>
     </controller>
     <controller type='pci' index='19' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='19' port='0xd'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x0d' function='0x0'/>
+      <target chassis='19' port='0xf'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x0f' function='0x0'/>
     </controller>
     <controller type='pci' index='20' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='20' port='0xe'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x0e' function='0x0'/>
+      <target chassis='20' port='0x10'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x10' function='0x0'/>
     </controller>
     <controller type='pci' index='21' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='21' port='0xf'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x0f' function='0x0'/>
+      <target chassis='21' port='0x11'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x11' function='0x0'/>
     </controller>
     <controller type='pci' index='22' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='22' port='0x10'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x10' function='0x0'/>
+      <target chassis='22' port='0x12'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x12' function='0x0'/>
     </controller>
     <controller type='pci' index='23' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='23' port='0x11'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x11' function='0x0'/>
+      <target chassis='23' port='0x13'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x13' function='0x0'/>
     </controller>
     <controller type='pci' index='24' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='24' port='0x12'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x12' function='0x0'/>
+      <target chassis='24' port='0x14'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x14' function='0x0'/>
     </controller>
     <controller type='pci' index='25' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='25' port='0x13'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x13' function='0x0'/>
+      <target chassis='25' port='0x15'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x15' function='0x0'/>
     </controller>
     <controller type='pci' index='26' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='26' port='0x14'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x14' function='0x0'/>
+      <target chassis='26' port='0x16'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x16' function='0x0'/>
     </controller>
     <controller type='pci' index='27' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='27' port='0x15'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x15' function='0x0'/>
+      <target chassis='27' port='0x17'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x17' function='0x0'/>
     </controller>
     <controller type='pci' index='28' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='28' port='0x16'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x16' function='0x0'/>
+      <target chassis='28' port='0x18'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x18' function='0x0'/>
     </controller>
     <controller type='pci' index='29' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='29' port='0x17'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x17' function='0x0'/>
+      <target chassis='29' port='0x19'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x19' function='0x0'/>
     </controller>
     <controller type='pci' index='30' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='30' port='0x18'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x18' function='0x0'/>
+      <target chassis='30' port='0x1a'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x1a' function='0x0'/>
     </controller>
     <controller type='pci' index='31' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='31' port='0x19'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x19' function='0x0'/>
+      <target chassis='31' port='0x1b'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x1b' function='0x0'/>
     </controller>
     <controller type='pci' index='32' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='32' port='0x1a'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x1a' function='0x0'/>
+      <target chassis='32' port='0x1c'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x1c' function='0x0'/>
     </controller>
     <controller type='pci' index='33' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='33' port='0x1b'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x1b' function='0x0'/>
+      <target chassis='33' port='0x1d'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x1d' function='0x0'/>
     </controller>
     <controller type='pci' index='34' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='34' port='0x1c'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x1c' function='0x0'/>
+      <target chassis='34' port='0x1e'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x1e' function='0x0'/>
     </controller>
     <controller type='pci' index='35' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='35' port='0x1d'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x1d' function='0x0'/>
-    </controller>
-    <controller type='pci' index='36' model='pcie-switch-downstream-port'>
-      <model name='xio3130-downstream'/>
-      <target chassis='36' port='0x1e'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x1e' function='0x0'/>
-    </controller>
-    <controller type='pci' index='37' model='pcie-switch-downstream-port'>
-      <model name='xio3130-downstream'/>
-      <target chassis='37' port='0x1f'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x1f' function='0x0'/>
+      <target chassis='35' port='0x1f'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x1f' function='0x0'/>
     </controller>
     <controller type='sata' index='0'>
       <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
@@ -220,162 +211,162 @@
     <interface type='user'>
       <mac address='52:54:00:f1:95:51'/>
       <model type='rtl8139'/>
-      <address type='pci' domain='0x0000' bus='0x06' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x04' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:5c:c6:1a'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x07' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x05' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:39:97:ac'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x08' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x06' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:ee:b9:a8'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x09' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x07' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:a9:f7:17'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x0a' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x08' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:df:2b:f3'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x0b' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x09' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:78:94:b4'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x0c' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x0a' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:6b:9b:06'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x0d' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x0b' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:17:df:bc'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x0e' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x0c' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:3b:d0:51'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x0f' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x0d' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:8d:2d:17'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x10' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x0e' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:a7:66:af'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x11' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x0f' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:54:ab:d7'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x12' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x10' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:1f:99:90'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x13' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x11' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:c8:43:87'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x14' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x12' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:df:22:b2'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x15' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x13' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:d2:9a:47'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x16' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x14' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:86:05:e2'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x17' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x15' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:8c:1c:c2'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x18' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x16' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:48:58:92'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x19' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x17' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:99:e5:bf'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x1a' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x18' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:b1:8c:25'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x1b' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x19' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:60:e0:d0'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x1c' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x1a' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:37:00:6a'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x1d' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x1b' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:c7:c8:ad'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x1e' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x1c' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:4e:a7:cf'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x1f' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x1d' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:00:79:69'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x20' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x1e' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:47:00:6f'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x21' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x1f' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:2a:8c:8b'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x22' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x20' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:ec:d5:e3'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x23' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x21' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:7e:6e:c8'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x24' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x22' slot='0x00' function='0x0'/>
     </interface>
     <interface type='user'>
       <mac address='52:54:00:7e:6d:c9'/>
       <model type='e1000'/>
-      <address type='pci' domain='0x0000' bus='0x25' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x23' slot='0x00' function='0x0'/>
     </interface>
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
diff --git a/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcie-root-port.xml b/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcie-root-port.xml
index 5c1ebef..5775eb9 100644
--- a/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcie-root-port.xml
+++ b/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcie-root-port.xml
@@ -20,21 +20,12 @@
       <address type='drive' controller='0' bus='0' target='0' unit='0'/>
     </disk>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
-      <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='2'/>
-      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
-    </controller>
-    <controller type='pci' index='3' model='pcie-root-port'>
+    <controller type='pci' index='1' model='pcie-root-port'>
       <model name='ioh3420'/>
-      <target chassis='3' port='0x10'/>
+      <target chassis='1' port='0x10'/>
       <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0' multifunction='on'/>
     </controller>
-    <controller type='pci' index='4' model='pcie-root-port'>
+    <controller type='pci' index='2' model='pcie-root-port'>
       <model name='ioh3420'/>
       <target chassis='40' port='0x1a'/>
       <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x1'/>
diff --git a/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcie-switch-downstream-port.xml b/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcie-switch-downstream-port.xml
index beb6ca8..a80316c 100644
--- a/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcie-switch-downstream-port.xml
+++ b/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcie-switch-downstream-port.xml
@@ -20,62 +20,53 @@
       <address type='drive' controller='0' bus='0' target='0' unit='0'/>
     </disk>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
-      <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='2'/>
-      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
-    </controller>
-    <controller type='pci' index='3' model='pcie-root-port'>
+    <controller type='pci' index='1' model='pcie-root-port'>
       <model name='ioh3420'/>
-      <target chassis='3' port='0x10'/>
+      <target chassis='1' port='0x10'/>
       <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
     </controller>
-    <controller type='pci' index='4' model='pcie-switch-upstream-port'>
+    <controller type='pci' index='2' model='pcie-switch-upstream-port'>
       <model name='x3130-upstream'/>
-      <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
     </controller>
-    <controller type='pci' index='5' model='pcie-switch-downstream-port'>
+    <controller type='pci' index='3' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='5' port='0x0'/>
-      <address type='pci' domain='0x0000' bus='0x04' slot='0x00' function='0x0'/>
+      <target chassis='3' port='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x02' slot='0x00' function='0x0'/>
     </controller>
-    <controller type='pci' index='6' model='pcie-switch-downstream-port'>
+    <controller type='pci' index='4' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='6' port='0x1'/>
-      <address type='pci' domain='0x0000' bus='0x04' slot='0x01' function='0x0'/>
+      <target chassis='4' port='0x1'/>
+      <address type='pci' domain='0x0000' bus='0x02' slot='0x01' function='0x0'/>
     </controller>
-    <controller type='pci' index='7' model='pcie-switch-downstream-port'>
+    <controller type='pci' index='5' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='7' port='0x2'/>
-      <address type='pci' domain='0x0000' bus='0x04' slot='0x02' function='0x0'/>
+      <target chassis='5' port='0x2'/>
+      <address type='pci' domain='0x0000' bus='0x02' slot='0x02' function='0x0'/>
     </controller>
-    <controller type='pci' index='8' model='pcie-switch-downstream-port'>
+    <controller type='pci' index='6' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
       <target chassis='30' port='0x27'/>
-      <address type='pci' domain='0x0000' bus='0x04' slot='0x03' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x02' slot='0x03' function='0x0'/>
     </controller>
-    <controller type='pci' index='9' model='pcie-switch-upstream-port'>
+    <controller type='pci' index='7' model='pcie-switch-upstream-port'>
       <model name='x3130-upstream'/>
-      <address type='pci' domain='0x0000' bus='0x05' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x0'/>
     </controller>
-    <controller type='pci' index='10' model='pcie-switch-downstream-port'>
+    <controller type='pci' index='8' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='10' port='0x4'/>
-      <address type='pci' domain='0x0000' bus='0x04' slot='0x04' function='0x0'/>
+      <target chassis='8' port='0x4'/>
+      <address type='pci' domain='0x0000' bus='0x02' slot='0x04' function='0x0'/>
     </controller>
-    <controller type='pci' index='11' model='pcie-switch-downstream-port'>
+    <controller type='pci' index='9' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='11' port='0x5'/>
-      <address type='pci' domain='0x0000' bus='0x04' slot='0x05' function='0x0'/>
+      <target chassis='9' port='0x5'/>
+      <address type='pci' domain='0x0000' bus='0x02' slot='0x05' function='0x0'/>
     </controller>
-    <controller type='pci' index='12' model='pcie-switch-downstream-port'>
+    <controller type='pci' index='10' model='pcie-switch-downstream-port'>
       <model name='xio3130-downstream'/>
-      <target chassis='12' port='0x6'/>
-      <address type='pci' domain='0x0000' bus='0x04' slot='0x06' function='0x0'/>
+      <target chassis='10' port='0x6'/>
+      <address type='pci' domain='0x0000' bus='0x02' slot='0x06' function='0x0'/>
     </controller>
     <controller type='sata' index='0'>
       <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
diff --git a/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcie-switch-upstream-port.xml b/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcie-switch-upstream-port.xml
index f35ebf7..b35be3c 100644
--- a/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcie-switch-upstream-port.xml
+++ b/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcie-switch-upstream-port.xml
@@ -20,32 +20,23 @@
       <address type='drive' controller='0' bus='0' target='0' unit='0'/>
     </disk>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
-      <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='2'/>
-      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
-    </controller>
-    <controller type='pci' index='3' model='pcie-root-port'>
+    <controller type='pci' index='1' model='pcie-root-port'>
       <model name='ioh3420'/>
-      <target chassis='3' port='0x10'/>
+      <target chassis='1' port='0x10'/>
       <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0' multifunction='on'/>
     </controller>
-    <controller type='pci' index='4' model='pcie-root-port'>
+    <controller type='pci' index='2' model='pcie-root-port'>
       <model name='ioh3420'/>
-      <target chassis='4' port='0x11'/>
+      <target chassis='2' port='0x11'/>
       <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x1'/>
     </controller>
-    <controller type='pci' index='5' model='pcie-switch-upstream-port'>
+    <controller type='pci' index='3' model='pcie-switch-upstream-port'>
       <model name='x3130-upstream'/>
-      <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
     </controller>
-    <controller type='pci' index='6' model='pcie-switch-upstream-port'>
+    <controller type='pci' index='4' model='pcie-switch-upstream-port'>
       <model name='x3130-upstream'/>
-      <address type='pci' domain='0x0000' bus='0x04' slot='0x00' function='0x0'/>
+      <address type='pci' domain='0x0000' bus='0x02' slot='0x00' function='0x0'/>
     </controller>
     <controller type='sata' index='0'>
       <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
diff --git a/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcihole64-q35.xml b/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcihole64-q35.xml
index dad7d1a..03a4e8e 100644
--- a/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcihole64-q35.xml
+++ b/tests/qemuxml2xmloutdata/qemuxml2xmlout-pcihole64-q35.xml
@@ -22,15 +22,6 @@
     <controller type='pci' index='0' model='pcie-root'>
       <pcihole64 unit='KiB'>1048576</pcihole64>
     </controller>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
-      <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='2'/>
-      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
-    </controller>
     <controller type='sata' index='0'>
       <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
     </controller>
diff --git a/tests/qemuxml2xmloutdata/qemuxml2xmlout-q35.xml b/tests/qemuxml2xmloutdata/qemuxml2xmlout-q35.xml
index 58c7fab..e3d4fa0 100644
--- a/tests/qemuxml2xmloutdata/qemuxml2xmlout-q35.xml
+++ b/tests/qemuxml2xmloutdata/qemuxml2xmlout-q35.xml
@@ -20,15 +20,6 @@
       <address type='drive' controller='0' bus='0' target='0' unit='0'/>
     </disk>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
-      <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='56'/>
-      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
-    </controller>
     <controller type='usb' index='0' model='ich9-ehci1'>
       <address type='pci' domain='0x0000' bus='0x00' slot='0x1d' function='0x7'/>
     </controller>
diff --git a/tests/qemuxml2xmloutdata/qemuxml2xmlout-usb-controller-default-q35.xml b/tests/qemuxml2xmloutdata/qemuxml2xmlout-usb-controller-default-q35.xml
index 456fd54..b4f94b6 100644
--- a/tests/qemuxml2xmloutdata/qemuxml2xmlout-usb-controller-default-q35.xml
+++ b/tests/qemuxml2xmloutdata/qemuxml2xmlout-usb-controller-default-q35.xml
@@ -15,15 +15,6 @@
   <devices>
     <emulator>/usr/libexec/qemu-kvm</emulator>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
-      <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='56'/>
-      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
-    </controller>
     <controller type='usb' index='0' model='piix3-uhci'>
       <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x0'/>
     </controller>
diff --git a/tests/qemuxml2xmloutdata/qemuxml2xmlout-usb-controller-explicit-q35.xml b/tests/qemuxml2xmloutdata/qemuxml2xmlout-usb-controller-explicit-q35.xml
index db92c22..8baaee4 100644
--- a/tests/qemuxml2xmloutdata/qemuxml2xmlout-usb-controller-explicit-q35.xml
+++ b/tests/qemuxml2xmloutdata/qemuxml2xmlout-usb-controller-explicit-q35.xml
@@ -15,15 +15,6 @@
   <devices>
     <emulator>/usr/libexec/qemu-kvm</emulator>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
-      <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='56'/>
-      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
-    </controller>
     <controller type='usb' index='0' model='nec-xhci'>
       <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x0'/>
     </controller>
diff --git a/tests/qemuxml2xmloutdata/qemuxml2xmlout-vcpu-placement-static.xml b/tests/qemuxml2xmloutdata/qemuxml2xmlout-vcpu-placement-static.xml
index c6471e3..a777f50 100644
--- a/tests/qemuxml2xmloutdata/qemuxml2xmlout-vcpu-placement-static.xml
+++ b/tests/qemuxml2xmloutdata/qemuxml2xmlout-vcpu-placement-static.xml
@@ -26,15 +26,6 @@
       <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
     </controller>
     <controller type='pci' index='0' model='pcie-root'/>
-    <controller type='pci' index='1' model='dmi-to-pci-bridge'>
-      <model name='i82801b11-bridge'/>
-      <address type='pci' domain='0x0000' bus='0x00' slot='0x1e' function='0x0'/>
-    </controller>
-    <controller type='pci' index='2' model='pci-bridge'>
-      <model name='pci-bridge'/>
-      <target chassisNr='2'/>
-      <address type='pci' domain='0x0000' bus='0x01' slot='0x01' function='0x0'/>
-    </controller>
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
     <memballoon model='none'/>
-- 
2.7.4

--
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