[PATCH 33/51] qemuxml2argvtest: Assume QEMU_CAPS_USB_HOST_HOSTDEVICE and QEMU_CAPS_DEVICE_QEMU_XHCI for fake-caps tests

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

 



Assume the two features modern qemus have to bring the test data closer
to the 'latest' real-caps versions.

Signed-off-by: Peter Krempa <pkrempa@xxxxxxxxxx>
---
 tests/qemuxml2argvdata/controller-order.args             | 2 +-
 tests/qemuxml2argvdata/pcie-expander-bus.args            | 2 ++
 tests/qemuxml2argvdata/pcie-root-port-model-generic.args | 1 +
 tests/qemuxml2argvdata/pcie-root-port-model-ioh3420.args | 1 +
 tests/qemuxml2argvdata/pcie-root-port.args               | 1 +
 tests/qemuxml2argvdata/pcie-root.args                    | 3 +++
 tests/qemuxml2argvdata/pcie-switch-downstream-port.args  | 1 +
 tests/qemuxml2argvdata/pcie-switch-upstream-port.args    | 2 ++
 tests/qemuxml2argvdata/pcihole64-q35.args                | 3 +++
 tests/qemuxml2argvdata/q35.args                          | 7 +++----
 tests/qemuxml2argvdata/usb1-usb2.args                    | 4 ++--
 tests/qemuxml2argvtest.c                                 | 4 ++++
 12 files changed, 24 insertions(+), 7 deletions(-)

diff --git a/tests/qemuxml2argvdata/controller-order.args b/tests/qemuxml2argvdata/controller-order.args
index 8f676e58fe..884e651b8e 100644
--- a/tests/qemuxml2argvdata/controller-order.args
+++ b/tests/qemuxml2argvdata/controller-order.args
@@ -49,7 +49,7 @@ XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain--1-fdr/.config \
 -device '{"driver":"cirrus-vga","id":"video0","bus":"pci.0","addr":"0x2"}' \
 -device '{"driver":"intel-hda","id":"sound0","bus":"pci.0","addr":"0x4"}' \
 -device '{"driver":"hda-duplex","id":"sound0-codec0","bus":"sound0.0","cad":0,"audiodev":"audio1"}' \
--device '{"driver":"usb-host","hostbus":14,"hostaddr":6,"id":"hostdev0","bus":"usb.0","port":"2"}' \
+-device '{"driver":"usb-host","hostdevice":"/dev/bus/usb/014/006","id":"hostdev0","bus":"usb.0","port":"2"}' \
 -device '{"driver":"virtio-balloon-pci","id":"balloon0","bus":"pci.0","addr":"0x6"}' \
 -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \
 -msg timestamp=on
diff --git a/tests/qemuxml2argvdata/pcie-expander-bus.args b/tests/qemuxml2argvdata/pcie-expander-bus.args
index 674beca027..3fb86c29c2 100644
--- a/tests/qemuxml2argvdata/pcie-expander-bus.args
+++ b/tests/qemuxml2argvdata/pcie-expander-bus.args
@@ -64,6 +64,8 @@ XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain--1-pcie-expander-bus-te/.config \
 -device '{"driver":"xio3130-downstream","port":29,"chassis":33,"id":"pci.33","bus":"pci.3","addr":"0x1d"}' \
 -device '{"driver":"xio3130-downstream","port":30,"chassis":34,"id":"pci.34","bus":"pci.3","addr":"0x1e"}' \
 -device '{"driver":"xio3130-downstream","port":31,"chassis":35,"id":"pci.35","bus":"pci.3","addr":"0x1f"}' \
+-device '{"driver":"pcie-root-port","port":8,"chassis":36,"id":"pci.36","bus":"pcie.0","addr":"0x1"}' \
+-device '{"driver":"qemu-xhci","id":"usb","bus":"pci.36","addr":"0x0"}' \
 -blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1","node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \
 -blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw","file":"libvirt-1-storage"}' \
 -device '{"driver":"ide-hd","bus":"ide.0","drive":"libvirt-1-format","id":"sata0-0-0","bootindex":1}' \
diff --git a/tests/qemuxml2argvdata/pcie-root-port-model-generic.args b/tests/qemuxml2argvdata/pcie-root-port-model-generic.args
index 86307c9bd8..dac9c0fd24 100644
--- a/tests/qemuxml2argvdata/pcie-root-port-model-generic.args
+++ b/tests/qemuxml2argvdata/pcie-root-port-model-generic.args
@@ -29,6 +29,7 @@ XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain--1-guest/.config \
 -device '{"driver":"pcie-root-port","port":8,"chassis":1,"id":"pci.1","bus":"pcie.0","multifunction":true,"addr":"0x1"}' \
 -device '{"driver":"pcie-root-port","port":9,"chassis":2,"id":"pci.2","bus":"pcie.0","addr":"0x1.0x1"}' \
 -device '{"driver":"ioh3420","port":10,"chassis":3,"id":"pci.3","bus":"pcie.0","addr":"0x1.0x2"}' \
+-device '{"driver":"qemu-xhci","id":"usb","bus":"pci.1","addr":"0x0"}' \
 -audiodev '{"id":"audio1","driver":"none"}' \
 -global ICH9-LPC.noreboot=off \
 -watchdog-action reset \
diff --git a/tests/qemuxml2argvdata/pcie-root-port-model-ioh3420.args b/tests/qemuxml2argvdata/pcie-root-port-model-ioh3420.args
index 430bedd7d8..e44f95a165 100644
--- a/tests/qemuxml2argvdata/pcie-root-port-model-ioh3420.args
+++ b/tests/qemuxml2argvdata/pcie-root-port-model-ioh3420.args
@@ -28,6 +28,7 @@ XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain--1-guest/.config \
 -boot strict=on \
 -device '{"driver":"pcie-root-port","port":8,"chassis":1,"id":"pci.1","bus":"pcie.0","multifunction":true,"addr":"0x1"}' \
 -device '{"driver":"ioh3420","port":9,"chassis":2,"id":"pci.2","bus":"pcie.0","addr":"0x1.0x1"}' \
+-device '{"driver":"qemu-xhci","id":"usb","bus":"pci.1","addr":"0x0"}' \
 -audiodev '{"id":"audio1","driver":"none"}' \
 -global ICH9-LPC.noreboot=off \
 -watchdog-action reset \
diff --git a/tests/qemuxml2argvdata/pcie-root-port.args b/tests/qemuxml2argvdata/pcie-root-port.args
index a48d65b8eb..27d3daff5b 100644
--- a/tests/qemuxml2argvdata/pcie-root-port.args
+++ b/tests/qemuxml2argvdata/pcie-root-port.args
@@ -28,6 +28,7 @@ XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain--1-q35-test/.config \
 -boot strict=on \
 -device '{"driver":"pcie-root-port","port":16,"chassis":1,"id":"pci.1","bus":"pcie.0","multifunction":true,"addr":"0x2"}' \
 -device '{"driver":"ioh3420","port":26,"chassis":40,"id":"pci.2","bus":"pcie.0","addr":"0x2.0x1"}' \
+-device '{"driver":"qemu-xhci","id":"usb","bus":"pci.1","addr":"0x0"}' \
 -blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1","node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \
 -blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw","file":"libvirt-1-storage"}' \
 -device '{"driver":"ide-hd","bus":"ide.0","drive":"libvirt-1-format","id":"sata0-0-0","bootindex":1}' \
diff --git a/tests/qemuxml2argvdata/pcie-root.args b/tests/qemuxml2argvdata/pcie-root.args
index 656cd80665..24bdf4b998 100644
--- a/tests/qemuxml2argvdata/pcie-root.args
+++ b/tests/qemuxml2argvdata/pcie-root.args
@@ -26,6 +26,9 @@ XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain--1-q35-test/.config \
 -rtc base=utc \
 -no-shutdown \
 -boot strict=on \
+-device '{"driver":"pcie-root-port","port":8,"chassis":1,"id":"pci.1","bus":"pcie.0","multifunction":true,"addr":"0x1"}' \
+-device '{"driver":"pcie-root-port","port":9,"chassis":2,"id":"pci.2","bus":"pcie.0","addr":"0x1.0x1"}' \
+-device '{"driver":"qemu-xhci","id":"usb","bus":"pci.1","addr":"0x0"}' \
 -audiodev '{"id":"audio1","driver":"none"}' \
 -global ICH9-LPC.noreboot=off \
 -watchdog-action reset \
diff --git a/tests/qemuxml2argvdata/pcie-switch-downstream-port.args b/tests/qemuxml2argvdata/pcie-switch-downstream-port.args
index 4e39017179..f5bc558d5b 100644
--- a/tests/qemuxml2argvdata/pcie-switch-downstream-port.args
+++ b/tests/qemuxml2argvdata/pcie-switch-downstream-port.args
@@ -36,6 +36,7 @@ XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain--1-q35-test/.config \
 -device '{"driver":"xio3130-downstream","port":4,"chassis":8,"id":"pci.8","bus":"pci.2","addr":"0x4"}' \
 -device '{"driver":"xio3130-downstream","port":5,"chassis":9,"id":"pci.9","bus":"pci.2","addr":"0x5"}' \
 -device '{"driver":"xio3130-downstream","port":6,"chassis":10,"id":"pci.10","bus":"pci.2","addr":"0x6"}' \
+-device '{"driver":"qemu-xhci","id":"usb","bus":"pci.4","addr":"0x0"}' \
 -blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1","node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \
 -blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw","file":"libvirt-1-storage"}' \
 -device '{"driver":"ide-hd","bus":"ide.0","drive":"libvirt-1-format","id":"sata0-0-0","bootindex":1}' \
diff --git a/tests/qemuxml2argvdata/pcie-switch-upstream-port.args b/tests/qemuxml2argvdata/pcie-switch-upstream-port.args
index 4b2b99ba0a..ed9e9b2ca0 100644
--- a/tests/qemuxml2argvdata/pcie-switch-upstream-port.args
+++ b/tests/qemuxml2argvdata/pcie-switch-upstream-port.args
@@ -30,6 +30,8 @@ XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain--1-q35-test/.config \
 -device '{"driver":"pcie-root-port","port":17,"chassis":2,"id":"pci.2","bus":"pcie.0","addr":"0x2.0x1"}' \
 -device '{"driver":"x3130-upstream","id":"pci.3","bus":"pci.1","addr":"0x0"}' \
 -device '{"driver":"x3130-upstream","id":"pci.4","bus":"pci.2","addr":"0x0"}' \
+-device '{"driver":"pcie-root-port","port":18,"chassis":5,"id":"pci.5","bus":"pcie.0","addr":"0x2.0x2"}' \
+-device '{"driver":"qemu-xhci","id":"usb","bus":"pci.5","addr":"0x0"}' \
 -blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1","node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \
 -blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw","file":"libvirt-1-storage"}' \
 -device '{"driver":"ide-hd","bus":"ide.0","drive":"libvirt-1-format","id":"sata0-0-0","bootindex":1}' \
diff --git a/tests/qemuxml2argvdata/pcihole64-q35.args b/tests/qemuxml2argvdata/pcihole64-q35.args
index 624cfc9264..91b70559f9 100644
--- a/tests/qemuxml2argvdata/pcihole64-q35.args
+++ b/tests/qemuxml2argvdata/pcihole64-q35.args
@@ -27,6 +27,9 @@ XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain--1-q35-test/.config \
 -no-shutdown \
 -boot strict=on \
 -global q35-pcihost.pci-hole64-size=1048576K \
+-device '{"driver":"pcie-root-port","port":16,"chassis":1,"id":"pci.1","bus":"pcie.0","multifunction":true,"addr":"0x2"}' \
+-device '{"driver":"pcie-root-port","port":17,"chassis":2,"id":"pci.2","bus":"pcie.0","addr":"0x2.0x1"}' \
+-device '{"driver":"qemu-xhci","id":"usb","bus":"pci.1","addr":"0x0"}' \
 -blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1","node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \
 -blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw","file":"libvirt-1-storage"}' \
 -device '{"driver":"ide-hd","bus":"ide.0","drive":"libvirt-1-format","id":"sata0-0-0","bootindex":1}' \
diff --git a/tests/qemuxml2argvdata/q35.args b/tests/qemuxml2argvdata/q35.args
index bd37012eb0..a8d711a42b 100644
--- a/tests/qemuxml2argvdata/q35.args
+++ b/tests/qemuxml2argvdata/q35.args
@@ -28,10 +28,9 @@ XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain--1-q35-test/.config \
 -global ICH9-LPC.disable_s3=1 \
 -global ICH9-LPC.disable_s4=0 \
 -boot strict=on \
--device '{"driver":"ich9-usb-ehci1","id":"usb","bus":"pcie.0","addr":"0x1d.0x7"}' \
--device '{"driver":"ich9-usb-uhci1","masterbus":"usb.0","firstport":0,"bus":"pcie.0","multifunction":true,"addr":"0x1d"}' \
--device '{"driver":"ich9-usb-uhci2","masterbus":"usb.0","firstport":2,"bus":"pcie.0","addr":"0x1d.0x1"}' \
--device '{"driver":"ich9-usb-uhci3","masterbus":"usb.0","firstport":4,"bus":"pcie.0","addr":"0x1d.0x2"}' \
+-device '{"driver":"pcie-root-port","port":16,"chassis":1,"id":"pci.1","bus":"pcie.0","multifunction":true,"addr":"0x2"}' \
+-device '{"driver":"pcie-root-port","port":17,"chassis":2,"id":"pci.2","bus":"pcie.0","addr":"0x2.0x1"}' \
+-device '{"driver":"qemu-xhci","id":"usb","bus":"pci.1","addr":"0x0"}' \
 -blockdev '{"driver":"host_device","filename":"/dev/HostVG/QEMUGuest1","node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \
 -blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw","file":"libvirt-1-storage"}' \
 -device '{"driver":"ide-hd","bus":"ide.0","drive":"libvirt-1-format","id":"sata0-0-0","bootindex":1}' \
diff --git a/tests/qemuxml2argvdata/usb1-usb2.args b/tests/qemuxml2argvdata/usb1-usb2.args
index cf84b7279e..e112a90ad3 100644
--- a/tests/qemuxml2argvdata/usb1-usb2.args
+++ b/tests/qemuxml2argvdata/usb1-usb2.args
@@ -38,8 +38,8 @@ XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.config \
 -device '{"driver":"usb-hub","id":"hub0","bus":"usb1.0","port":"1"}' \
 -device '{"driver":"usb-tablet","id":"input0","bus":"usb.0","port":"2"}' \
 -audiodev '{"id":"audio1","driver":"none"}' \
--device '{"driver":"usb-host","hostbus":14,"hostaddr":6,"id":"hostdev0","bus":"usb2.0","port":"1"}' \
--device '{"driver":"usb-host","hostbus":14,"hostaddr":7,"id":"hostdev1","bus":"usb2.0","port":"2"}' \
+-device '{"driver":"usb-host","hostdevice":"/dev/bus/usb/014/006","id":"hostdev0","bus":"usb2.0","port":"1"}' \
+-device '{"driver":"usb-host","hostdevice":"/dev/bus/usb/014/007","id":"hostdev1","bus":"usb2.0","port":"2"}' \
 -device '{"driver":"virtio-balloon-pci","id":"balloon0","bus":"pci.0","addr":"0x2"}' \
 -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \
 -msg timestamp=on
diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c
index 872a26c6dd..1774a50f3f 100644
--- a/tests/qemuxml2argvtest.c
+++ b/tests/qemuxml2argvtest.c
@@ -866,6 +866,8 @@ mymain(void)
                  QEMU_CAPS_DEVICE_PCIE_ROOT_PORT, \
                  QEMU_CAPS_CPU_MIGRATABLE, \
                  QEMU_CAPS_SMP_DIES, \
+                 QEMU_CAPS_USB_HOST_HOSTDEVICE, \
+                 QEMU_CAPS_DEVICE_QEMU_XHCI, \
                  __VA_ARGS__, \
                  QEMU_CAPS_LAST, \
                  ARG_END)
@@ -880,6 +882,8 @@ mymain(void)
                  QEMU_CAPS_DEVICE_PCIE_ROOT_PORT, \
                  QEMU_CAPS_CPU_MIGRATABLE, \
                  QEMU_CAPS_SMP_DIES, \
+                 QEMU_CAPS_USB_HOST_HOSTDEVICE, \
+                 QEMU_CAPS_DEVICE_QEMU_XHCI, \
                  QEMU_CAPS_LAST, \
                  ARG_END)

-- 
2.41.0




[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