]> git.ipfire.org Git - thirdparty/libvirt.git/commit
qemu: Add enough USB hubs to accomodate all devices
authorJán Tomko <jtomko@redhat.com>
Fri, 27 Jan 2017 13:06:29 +0000 (14:06 +0100)
committerJán Tomko <jtomko@redhat.com>
Tue, 31 Jan 2017 12:09:08 +0000 (13:09 +0100)
commit3ac97c2dedd2a4715d06cf506be3727df32e79eb
treeefc1c91974793524daa3a46653b9ba408e5593ce
parent077c6d450fb1fae324d88412f37268458b2f924a
qemu: Add enough USB hubs to accomodate all devices

Commit 815d98a started auto-adding one hub if there are more USB devices
than available USB ports.

This was a strange choice, since there might be even more devices.
Before USB address allocation was implemented in libvirt, QEMU
automatically added a new USB hub if the old one was full.

Adjust the logic to try adding as many hubs as will be needed
to plug in all the specified devices.

https://bugzilla.redhat.com/show_bug.cgi?id=1410188
src/qemu/qemu_domain_address.c
tests/qemuxml2argvdata/qemuxml2argv-usb-hub-autoadd-deluxe.args [new file with mode: 0644]
tests/qemuxml2argvdata/qemuxml2argv-usb-hub-autoadd-deluxe.xml [new file with mode: 0644]
tests/qemuxml2argvtest.c