Re: [Spice-devel] Questions about experimental Spice compositor rebase

2016-02-28 Thread Yury Shvedov
Hi, Fabio! Your patient interest to this project make me to perform the attempt to continue it. Now, I'm trying another way. 1. Compile old sources (old weston) with new version of spice and wayland - done 2. Make it work if possible 3. Compile with new version of weston (perform merge) 4.

Re: [Spice-devel] Questions about experimental Spice compositor rebase

2016-02-28 Thread Fabio Fantoni
Il 27/02/2016 19:02, Fabio Fantoni ha scritto: Hi, long time ago I saw an interesting project for weston, the spice compositor: https://github.com/ein-shved/compositor-spice It is now abandoned because the developer has been involved in another project. As no other has continued it, despite m

Re: [Spice-devel] Some Grammar patches

2016-02-28 Thread Uri Lublin
On 02/27/2016 03:22 PM, Victor Toso wrote: Hi, On Fri, Feb 26, 2016 at 01:00:35PM -0500, Ryan wrote: While reading the spec, some small grammar issues made it sounds funky — I fixed some of them here: https://github.com/Fuzion24/usbredir/commit/b3593f0f464aa9dc5150d38ff3e401cd25488f1b.patch T

[Spice-devel] [PATCH v6 03/14] win-usb-dev: Track device redirection operations in progress

2016-02-28 Thread Dmitry Fleytman
From: Kirill Moizik This commit introduces redirecting property of GUdevClient This property indicates when a redirection operation is in progress on a device. It's set back to FALSE once the device is fully redirected to the guest. Signed-off-by: Kirill Moizik Signed-off-by: Dmitry Fleytman

[Spice-devel] [PATCH v6 14/14] UsbDeviceManager: Make synchronous disconnect method static

2016-02-28 Thread Dmitry Fleytman
From: Dmitry Fleytman Synchronous disconnection is not a part of public interface anymore. Signed-off-by: Dmitry Fleytman --- src/map-file | 1 - src/usb-device-manager.c | 15 --- src/usb-device-manager.h | 3 --- 3 files changed, 8 insertions(+), 11 deletions(-) di

[Spice-devel] [PATCH v6 11/14] UsbDeviceWidget: Show info bar during redirection flows

2016-02-28 Thread Dmitry Fleytman
From: Kirill Moizik Signed-off-by: Kirill Moizik Signed-off-by: Dmitry Fleytman --- src/map-file | 1 + src/usb-device-manager.c | 23 +++ src/usb-device-manager.h | 2 ++ src/usb-device-widget.c | 7 +++ 4 files changed, 33 insertions(+) diff --git a/s

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

2016-02-28 Thread Dmitry Fleytman
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 pr

[Spice-devel] [PATCH v6 02/14] usbredir: Introduce mutex for device (dis)connection

2016-02-28 Thread Dmitry Fleytman
From: Kirill Moizik This commit introduces channel mutex to allow usage of channel objects in mutithreaded environments. This mutex will be used by future commits to protect thread unsafe usbredir functions and data structures. Signed-off-by: Kirill Moizik Signed-off-by: Dmitry Fleytman ---

[Spice-devel] [PATCH v6 05/14] usbredir: Protect data accessed by asynchronous redirection flows

2016-02-28 Thread Dmitry Fleytman
From: Kirill Moizik This commit adds locking to ensure thread safety required after start/stop redirection flows moved to separate threads. This is done in preparation to following commits that will introduce actual multithreaded access to corresponding routines. Signed-off-by: Kirill Moizik Si

[Spice-devel] [PATCH v6 13/14] UsbDeviceWidget: Use asynchronous disconnect API

2016-02-28 Thread Dmitry Fleytman
From: Kirill Moizik Signed-off-by: Kirill Moizik Signed-off-by: Dmitry Fleytman --- src/usb-device-widget.c | 33 - 1 file changed, 24 insertions(+), 9 deletions(-) diff --git a/src/usb-device-widget.c b/src/usb-device-widget.c index 56bdeaf..3166225 100644 ---

[Spice-devel] [PATCH v6 07/14] UsbDeviceManager: Track device redirection operations in progress

2016-02-28 Thread Dmitry Fleytman
From: Kirill Moizik During device connection, unwanted hotplug events may happen. We need to ignore those therefore we track redirection operations in progress. See also comment to commit "Do not process USB hotplug events while redirection is in progress" that introduces corresponding filtering

[Spice-devel] [PATCH v6 08/14] UsbDeviceManager: Implement asynchronous disconnect device flow

2016-02-28 Thread Dmitry Fleytman
From: Kirill Moizik This commit introduces functions for asynchronous disconnection flows. Following commits will make use of those. Thread safety is ensured the same way it was done for connection flow in previous commits. Disconnect logic is protected by the same locks that protect connect/usb

[Spice-devel] [PATCH v6 09/14] UsbDeviceManager: Track device disconnection operations in progress

2016-02-28 Thread Dmitry Fleytman
From: Kirill Moizik During device disconnection, unwanted hotplug events may happen. We need to ignore those therefore we track disconnection operations in progress. See also comment to commit "Do not process USB hotplug events while redirection is in progress" that introduces corresponding filt

[Spice-devel] [PATCH v6 10/14] usbredir: Disconnect USB device asynchronously

2016-02-28 Thread Dmitry Fleytman
From: Kirill Moizik Signed-off-by: Kirill Moizik Signed-off-by: Dmitry Fleytman --- src/channel-usbredir.c | 38 +++--- 1 file changed, 31 insertions(+), 7 deletions(-) diff --git a/src/channel-usbredir.c b/src/channel-usbredir.c index ebf9fce..3a10823 100644 -

[Spice-devel] [PATCH v6 01/14] win-usb-dev: Fix device (un)plug notification handler

2016-02-28 Thread Dmitry Fleytman
This patch fixes device list change notification handing logic for cases when more than one device being plugged or unplugged simultaneously. The simplest way to reproduce the problematic scenario is (un)plugging of a usb HUB with a few devices inserted. Signed-off-by: Dmitry Fleytman --- src/w

[Spice-devel] [PATCH v6 04/14] GUdevClient: Do not process USB hotplug events while redirection is in progress

2016-02-28 Thread Dmitry Fleytman
From: Kirill Moizik USB redirection flow on Windows includes a number of reset requests issued to the port that hosts the device deing redirected. Each port reset emulates device removal and reinsertion and produces corresponding hotplug events and a number of device list updates on different le

[Spice-devel] [PATCH v6 12/14] UsbDeviceWidget: Consider asynchronous redirection flows

2016-02-28 Thread Dmitry Fleytman
From: Kirill Moizik Gray out redirection controls while there are asynchronous redirection flows in progress. Signed-off-by: Kirill Moizik Signed-off-by: Dmitry Fleytman --- src/usb-device-widget.c | 38 -- 1 file changed, 20 insertions(+), 18 deletions(-)

[Spice-devel] [PATCH v6 06/14] usbredir: Spawn a different thread for device redirection flow

2016-02-28 Thread Dmitry Fleytman
From: Kirill Moizik On Windows when using usbdk, opening and closing USB device handle, i.e. calling libusb_open()/libusb_unref_device() can block for a few seconds (3-5 second more specifically on patch author's HW). libusb_open() is called by spice_usbredir_channel_open_device(). libusb_unref

Re: [Spice-devel] [PATCH v5 13/13] UsbDeviceManager: Make synchronous disconnect method static

2016-02-28 Thread Dmitry Fleytman
> On 21 Feb 2016, at 12:33 PM, Dmitry Fleytman wrote: > > >> On 11 Feb 2016, at 01:30 AM, Jonathon Jongsma > > wrote: >> >> This breaks public API. I don't think we want to do that. We could deprecate >> it >> somehow though. > > Hi Jonathon, > > How do we deprec

Re: [Spice-devel] [PATCH v5 12/13] UsbDeviceWidget: Use asynchronous disconnect API

2016-02-28 Thread Dmitry Fleytman
> On 11 Feb 2016, at 01:28 AM, Jonathon Jongsma wrote: > > On Thu, 2015-10-29 at 17:27 +0200, Dmitry Fleytman wrote: >> From: Kirill Moizik >> >> Signed-off-by: Kirill Moizik >> Signed-off-by: Dmitry Fleytman >> --- >> src/usb-device-widget.c | 24 +++- >> 1 file changed,

Re: [Spice-devel] [PATCH v5 11/13] UsbDeviceWidget: Consider asynchronous redirection flows

2016-02-28 Thread Dmitry Fleytman
> On 11 Feb 2016, at 01:00 AM, Jonathon Jongsma wrote: > > On Thu, 2015-10-29 at 17:27 +0200, Dmitry Fleytman wrote: >> From: Kirill Moizik >> >> Gray out redirection controls while there are >> asynchronous redirection flows in progress. >> >> Signed-off-by: Kirill Moizik >> Signed-off-by:

Re: [Spice-devel] [PATCH v5 10/13] UsbDeviceWidget: Show info bar during redirection flows

2016-02-28 Thread Dmitry Fleytman
> On 11 Feb 2016, at 24:52 AM, Jonathon Jongsma wrote: > > On Thu, 2015-10-29 at 17:27 +0200, Dmitry Fleytman wrote: >> From: Kirill Moizik >> >> Signed-off-by: Kirill Moizik >> Signed-off-by: Dmitry Fleytman >> --- >> src/map-file | 1 + >> src/usb-device-manager.c | 23

Re: [Spice-devel] [PATCH v5 09/13] usbredir: Disconnect USB device asynchronously

2016-02-28 Thread Dmitry Fleytman
> On 11 Feb 2016, at 24:41 AM, Jonathon Jongsma wrote: > > On Thu, 2015-10-29 at 17:27 +0200, Dmitry Fleytman wrote: >> From: Kirill Moizik >> >> Signed-off-by: Kirill Moizik >> Signed-off-by: Dmitry Fleytman >> --- >> src/channel-usbredir.c | 36 +--- >> src/m

Re: [Spice-devel] [PATCH v5 07/13] UsbDeviceManager: Implement asynchronous disconnect device flow

2016-02-28 Thread Dmitry Fleytman
> On 11 Feb 2016, at 01:24 AM, Jonathon Jongsma wrote: > > On Wed, 2016-02-10 at 16:36 -0600, Jonathon Jongsma wrote: >> On Thu, 2015-10-29 at 17:27 +0200, Dmitry Fleytman wrote: >> >>> From: Kirill Moizik >>> >>> This commit introduces functions for asynchronous disconnection flows. >>> Foll

Re: [Spice-devel] [PATCH v5 06/13] UsbDeviceManager: Track device redirection operations in progress

2016-02-28 Thread Dmitry Fleytman
> On 10 Feb 2016, at 23:48 PM, Jonathon Jongsma wrote: > > On Thu, 2015-10-29 at 17:27 +0200, Dmitry Fleytman wrote: >> From: Kirill Moizik >> >> During device connection, unwanted hotplug events may happen. >> We need to ignore those therefore we track redirection operations >> in progress. >

Re: [Spice-devel] [PATCH v5 05/13] usbredir: Spawn a different thread for device redirection flow

2016-02-28 Thread Dmitry Fleytman
> On 9 Feb 2016, at 23:43 PM, Jonathon Jongsma wrote: > > On Thu, 2015-10-29 at 17:27 +0200, Dmitry Fleytman wrote: >> From: Kirill Moizik >> >> On Windows when using usbdk, opening and closing USB device handle, >> i.e. calling libusb_open()/libusb_unref_device() can block for a few >> second

Re: [Spice-devel] [PATCH v5 04/13] usbredir: Protect data accessed by asynchronous redirection flows

2016-02-28 Thread Dmitry Fleytman
> On 9 Feb 2016, at 18:40 PM, Jonathon Jongsma wrote: > > On Thu, 2015-10-29 at 17:27 +0200, Dmitry Fleytman wrote: >> From: Kirill Moizik >> >> This commit adds locking to ensure thread safety required >> after start/stop redirection flows moved to separate threads. >> >> Signed-off-by: Kiri

Re: [Spice-devel] [PATCH v5 03/13] GUdevClient: Do not process USB hotplug events while redirection is in progress

2016-02-28 Thread Dmitry Fleytman
> On 9 Feb 2016, at 24:56 AM, Jonathon Jongsma wrote: > > On Thu, 2015-10-29 at 17:27 +0200, Dmitry Fleytman wrote: >> From: Kirill Moizik >> >> USB redirection flow on Windows includes a number of reset requests issued >> to the port that hosts the device deing redirected. >> >> Each port re

Re: [Spice-devel] [PATCH v5 02/13] win-usb-dev: Track device redirection operations in progress

2016-02-28 Thread Dmitry Fleytman
> On 8 Feb 2016, at 19:24 PM, Jonathon Jongsma wrote: > > On Thu, 2015-10-29 at 17:27 +0200, Dmitry Fleytman wrote: >> From: Kirill Moizik >> >> This commit introduces redirecting property of GUdevClient >> >> This property indicates when a redirection operation >> is in progress on a device.

Re: [Spice-devel] [PATCH v5 01/13] Usbredir channel: Introduce mutex for USB redirection

2016-02-28 Thread Dmitry Fleytman
> On 9 Feb 2016, at 17:14 PM, Jonathon Jongsma wrote: > > On Thu, 2015-10-29 at 17:26 +0200, Dmitry Fleytman wrote: >> From: Kirill Moizik >> >> This commit introduces channel mutex to allow usage of >> channel objects in mutithreaded environments. >> >> This mutex will be used to protect non

Re: [Spice-devel] [PATCH v7 06/10] usbdk: Load hide rules for auto-redirected devices

2016-02-28 Thread Dmitry Fleytman
> On 21 Feb 2016, at 09:28 AM, Dmitry Fleytman wrote: > >> >> On 19 Feb 2016, at 23:31 PM, Jonathon Jongsma > > wrote: >> >> On Thu, 2016-02-11 at 18:04 +0200, Dmitry Fleytman wrote: >>> Hide rules order UsbDk to avoid showing specific USB >>> devices to Windows PnP