[Spice-devel] RFC: spice plans for usb-redir + needed spice-server API extensions

Hans de Goede hdegoede at redhat.com
Wed Jul 20 04:38:48 PDT 2011


Hi,

On 07/19/2011 05:46 PM, Gerd Hoffmann wrote:
> Hi,
>
>> 3) spice server asks qemu to dynamically create a new spicevmc chardev
>> + usb-redir device couple (this is the part that needs the API extension).
>
> That isn't going to fly. Then you'll have magic usb devices on the usb bus libvirt doesn't know about. Which can cause trouble in various corner cases, such as libvirt wanting to hotplug a usb device into a usb port which has been taken by a usb-redir device.
>
> I think we have to create usb-redir devices when creating the virtual machine, so we have virtual usb ports available to the spice client, which then can "plug" devices in there for forwarding.

Ok, that was my first idea actually (precreated chardev + usb-redir device combos),
as that is how the smartcard stuff does things. But I thought doing it dynamically
would be more elegant. But now that you mention it I remember having discussions
about this before and how qemu should not dynamically create devices outside
of libvirt's control.

So using pre-created devices waiting to be plugged it is, that is actually a lot
easier to code up :)

Regards,

Hans


More information about the Spice-devel mailing list