[Spice-devel] [PATCH v7 00/14] Make start and stop usb redirection asynchronous

Dmitry Fleytman dmitry at daynix.com
Tue Mar 8 14:05:47 UTC 2016


Changes since v6:

- changes and fixes as suggested by Jonathon. Jonathon, thanks for the review.
- reworked patch that fixes device list handling in case of multiple device state change
- synchronous disconnection method deprecated but left in the public interface

Changes since v5:

- changes and simplifications as suggested by Jonathon
- added patch that fixes device list handling in case of multiple device state change
- there is still an open question regarding the last patch - should we drop it or mark public function as deprecated instead of making private

Changes since v4:

- changes and simplifications as suggested by Christophe
- rebased to the latest master

Changes since v3:

- changes as suggested by Christophe
- minor patch set reordering and beautifications

Changes since v2:

- remove spice_g_udev_handle_device_change api
- cosmetic changes
- set redirection state at usbdevice manager level
- remove set_redirecton and set_sensitive_all
- check for redirection state at check_can_redirect
- expose mutex to guard all critical sections

Changes since v1:

- fix trailing whitespace
- fix linux build with usb redirection
- fix linux build without ussb redirection
- set redirecting state as gobject property
- separate commit for widget manipulations
- commit messages fixes

This patch series makes start/stop USB redirection flows run in their own threads.
It solves spice-gtk freeze problems since start and stop redirection are time consuming operations.
This series include new api exposure, threads syncronization and new usb redirection widget behavior.
When redirection starts/ends widget will turn inactive/active.

Dmitry Fleytman (2):
  win-usb-dev: Fix device (un)plug notification handler
  UsbDeviceManager: Deprecate synchronous disconnection method

Kirill Moizik (12):
  usbredir: Introduce mutex for device (dis)connection
  win-usb-dev: Track device redirection operations in progress
  GUdevClient: Do not process USB hotplug events while redirection is in
    progress
  usbredir: Protect data accessed by asynchronous redirection flows
  usbredir: Spawn a different thread for device redirection flow
  UsbDeviceManager: Track device redirection operations in progress
  UsbDeviceManager: Implement asynchronous disconnect device flow
  UsbDeviceManager: Track device disconnection operations in progress
  usbredir: Disconnect USB device asynchronously
  UsbDeviceWidget: Show info bar during redirection flows
  UsbDeviceWidget: Consider asynchronous redirection flows
  UsbDeviceWidget: Use asynchronous disconnect API

 src/channel-usbredir-priv.h |  13 +++
 src/channel-usbredir.c      | 154 ++++++++++++++++++++++++++++++----
 src/map-file                |   3 +
 src/usb-device-manager.c    | 199 ++++++++++++++++++++++++++++++++++++++++----
 src/usb-device-manager.h    |  16 ++++
 src/usb-device-widget.c     |  85 +++++++++++++------
 src/win-usb-dev.c           | 167 +++++++++++++++++++++++--------------
 7 files changed, 515 insertions(+), 122 deletions(-)

-- 
2.5.0



More information about the Spice-devel mailing list