qemu: always assume QEMU_CAPS_USB_REDIR_BOOTINDEX

Added by QEMU commit 65bb3a5 contained in v1.1.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
This commit is contained in:
Ján Tomko 2018-09-07 14:37:34 +02:00
parent 9eae152fcb
commit 40f3c23c0f
18 changed files with 3 additions and 26 deletions

View File

@ -1219,7 +1219,6 @@ static struct virQEMUCapsStringFlags virQEMUCapsDevicePropsPiix4PM[] = {
static struct virQEMUCapsStringFlags virQEMUCapsDevicePropsUSBRedir[] = {
{ "filter", QEMU_CAPS_USB_REDIR_FILTER },
{ "bootindex", QEMU_CAPS_USB_REDIR_BOOTINDEX },
};
static struct virQEMUCapsStringFlags virQEMUCapsDevicePropsUSBHost[] = {

View File

@ -210,7 +210,7 @@ typedef enum { /* virQEMUCapsFlags grouping marker for syntax-check */
/* 115 */
QEMU_CAPS_DRIVE_MIRROR, /* drive-mirror monitor command */
QEMU_CAPS_USB_REDIR_BOOTINDEX, /* usb-redir.bootindex */
X_QEMU_CAPS_USB_REDIR_BOOTINDEX, /* usb-redir.bootindex */
QEMU_CAPS_USB_HOST_BOOTINDEX, /* usb-host.bootindex */
QEMU_CAPS_DISK_SNAPSHOT, /* blockdev-snapshot-sync command */
QEMU_CAPS_DEVICE_QXL, /* -device qxl */

View File

@ -9482,15 +9482,8 @@ qemuBuildRedirdevDevStr(const virDomainDef *def,
}
}
if (dev->info.bootIndex) {
if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_USB_REDIR_BOOTINDEX)) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
_("USB redirection booting is not "
"supported by this version of QEMU"));
goto error;
}
if (dev->info.bootIndex)
virBufferAsprintf(&buf, ",bootindex=%u", dev->info.bootIndex);
}
if (qemuBuildDeviceAddressStr(&buf, def, &dev->info, qemuCaps) < 0)
goto error;

View File

@ -49,7 +49,6 @@
<flag name='block-commit'/>
<flag name='vnc'/>
<flag name='drive-mirror'/>
<flag name='usb-redir.bootindex'/>
<flag name='usb-host.bootindex'/>
<flag name='blockdev-snapshot-sync'/>
<flag name='qxl'/>

View File

@ -49,7 +49,6 @@
<flag name='block-commit'/>
<flag name='vnc'/>
<flag name='drive-mirror'/>
<flag name='usb-redir.bootindex'/>
<flag name='usb-host.bootindex'/>
<flag name='blockdev-snapshot-sync'/>
<flag name='qxl'/>

View File

@ -49,7 +49,6 @@
<flag name='block-commit'/>
<flag name='vnc'/>
<flag name='drive-mirror'/>
<flag name='usb-redir.bootindex'/>
<flag name='usb-host.bootindex'/>
<flag name='blockdev-snapshot-sync'/>
<flag name='qxl'/>

View File

@ -49,7 +49,6 @@
<flag name='block-commit'/>
<flag name='vnc'/>
<flag name='drive-mirror'/>
<flag name='usb-redir.bootindex'/>
<flag name='usb-host.bootindex'/>
<flag name='blockdev-snapshot-sync'/>
<flag name='qxl'/>

View File

@ -49,7 +49,6 @@
<flag name='block-commit'/>
<flag name='vnc'/>
<flag name='drive-mirror'/>
<flag name='usb-redir.bootindex'/>
<flag name='usb-host.bootindex'/>
<flag name='blockdev-snapshot-sync'/>
<flag name='qxl'/>

View File

@ -49,7 +49,6 @@
<flag name='block-commit'/>
<flag name='vnc'/>
<flag name='drive-mirror'/>
<flag name='usb-redir.bootindex'/>
<flag name='usb-host.bootindex'/>
<flag name='blockdev-snapshot-sync'/>
<flag name='qxl'/>

View File

@ -49,7 +49,6 @@
<flag name='block-commit'/>
<flag name='vnc'/>
<flag name='drive-mirror'/>
<flag name='usb-redir.bootindex'/>
<flag name='usb-host.bootindex'/>
<flag name='blockdev-snapshot-sync'/>
<flag name='qxl'/>

View File

@ -49,7 +49,6 @@
<flag name='block-commit'/>
<flag name='vnc'/>
<flag name='drive-mirror'/>
<flag name='usb-redir.bootindex'/>
<flag name='usb-host.bootindex'/>
<flag name='blockdev-snapshot-sync'/>
<flag name='qxl'/>

View File

@ -49,7 +49,6 @@
<flag name='block-commit'/>
<flag name='vnc'/>
<flag name='drive-mirror'/>
<flag name='usb-redir.bootindex'/>
<flag name='usb-host.bootindex'/>
<flag name='blockdev-snapshot-sync'/>
<flag name='qxl'/>

View File

@ -49,7 +49,6 @@
<flag name='block-commit'/>
<flag name='vnc'/>
<flag name='drive-mirror'/>
<flag name='usb-redir.bootindex'/>
<flag name='usb-host.bootindex'/>
<flag name='blockdev-snapshot-sync'/>
<flag name='qxl'/>

View File

@ -49,7 +49,6 @@
<flag name='block-commit'/>
<flag name='vnc'/>
<flag name='drive-mirror'/>
<flag name='usb-redir.bootindex'/>
<flag name='usb-host.bootindex'/>
<flag name='blockdev-snapshot-sync'/>
<flag name='qxl'/>

View File

@ -49,7 +49,6 @@
<flag name='block-commit'/>
<flag name='vnc'/>
<flag name='drive-mirror'/>
<flag name='usb-redir.bootindex'/>
<flag name='usb-host.bootindex'/>
<flag name='blockdev-snapshot-sync'/>
<flag name='qxl'/>

View File

@ -49,7 +49,6 @@
<flag name='block-commit'/>
<flag name='vnc'/>
<flag name='drive-mirror'/>
<flag name='usb-redir.bootindex'/>
<flag name='usb-host.bootindex'/>
<flag name='blockdev-snapshot-sync'/>
<flag name='qxl'/>

View File

@ -49,7 +49,6 @@
<flag name='block-commit'/>
<flag name='vnc'/>
<flag name='drive-mirror'/>
<flag name='usb-redir.bootindex'/>
<flag name='usb-host.bootindex'/>
<flag name='blockdev-snapshot-sync'/>
<flag name='qxl'/>

View File

@ -1547,8 +1547,7 @@ mymain(void)
QEMU_CAPS_USB_HUB,
QEMU_CAPS_ICH9_USB_EHCI1,
QEMU_CAPS_USB_REDIR,
QEMU_CAPS_SPICE,
QEMU_CAPS_USB_REDIR_BOOTINDEX);
QEMU_CAPS_SPICE);
DO_TEST("usb-redir-filter",
QEMU_CAPS_USB_HUB,
QEMU_CAPS_ICH9_USB_EHCI1,