Skip to content
  • iordan iordanov's avatar
    Implemented the ability to allocate SpiceUsbDevice instances · 9a0cec4b
    iordan iordanov authored and Frediano Ziglio's avatar Frediano Ziglio committed
    
    by passing an open file descriptor in order to support the modern
    Android USB device permissioning scheme.
    
    During the process, a handle obtained by a call to
    libusb_wrap_sys_device() is stored in the SpiceUsbDevice instance.
    
    A call to libusb_open() is skipped if there is already a handle
    present in the SpiceUsbDevice instance.
    
    Finally, on Android, the option LIBUSB_OPTION_NO_DEVICE_DISCOVERY
    must be set prior to the call to libusb_init() as per libusb
    documentation.
    
    Acked-by: default avatarFrediano Ziglio <freddy77@gmail.com>
    9a0cec4b