Re: [Spice-devel] [spice-gtk 3/9] usb-redir: Prepare for creation of emulated CD drive

2019-07-25 Thread Victor Toso
On Thu, Jul 25, 2019 at 06:59:39PM +0300, Yuri Benditovich wrote: > On Thu, Jul 25, 2019 at 1:33 PM Victor Toso wrote: > > > > On Wed, Jul 24, 2019 at 01:53:45PM +0300, Yuri Benditovich wrote: > > > Added command-line option for shared CD devices and respective > > > property in usb-device-manager

Re: [Spice-devel] [spice-gtk 2/9] usb-redir: device error signal without device object

2019-07-25 Thread Yuri Benditovich
On Thu, Jul 25, 2019 at 8:46 PM Frediano Ziglio wrote: > > > > > > > On Thu, Jul 25, 2019 at 12:01 PM Frediano Ziglio > > > wrote: > > > > > > > > > > > > > > Add ability to indicate error to external modules via > > > > > 'device error' signal when real SpiceUsbDevice is not passed. > > > > > Th

[Spice-devel] [PATCH v3 fixup1 x11spice 2/3] Simplify the expression of argument parsing.

2019-07-25 Thread Jeremy White
This fixes a bug with --config=handling. Removed old testing code as obsolete instead of updating unused code. Signed-off-by: Jeremy White --- v2: Simplify even further. v3: Add a commit message about the removal of unused code, do not group static and public functions --- src/main.c|

Re: [Spice-devel] [PATCH x11spice v2 0/3] Add cache for SHM segments

2019-07-25 Thread Brendan Shanks
> On Jul 16, 2019, at 7:16 PM, Brendan Shanks wrote: > > Add a cache to x11spice for SHM segments. > > v2 should address Frediano's comments: style, use of G_N_ELEMENTS, > using unsigned types for width/height/size, creating a separate struct > to hold all the segment-specific variables, and re

Re: [Spice-devel] [spice-gtk 2/9] usb-redir: device error signal without device object

2019-07-25 Thread Frediano Ziglio
> > > > On Thu, Jul 25, 2019 at 12:01 PM Frediano Ziglio > > wrote: > > > > > > > > > > > Add ability to indicate error to external modules via > > > > 'device error' signal when real SpiceUsbDevice is not passed. > > > > This is needed to indicate error during creation of emulated > > > > device

Re: [Spice-devel] [spice-gtk 3/9] usb-redir: Prepare for creation of emulated CD drive

2019-07-25 Thread Yuri Benditovich
On Thu, Jul 25, 2019 at 1:33 PM Victor Toso wrote: > > On Wed, Jul 24, 2019 at 01:53:45PM +0300, Yuri Benditovich wrote: > > Added command-line option for shared CD devices and respective > > property in usb-device-manager. > > > > Signed-off-by: Yuri Benditovich > > --- > > src/spice-option.c

Re: [Spice-devel] [spice-gtk 3/9] usb-redir: Prepare for creation of emulated CD drive

2019-07-25 Thread Frediano Ziglio
> > On Thu, Jul 25, 2019 at 1:32 PM Victor Toso wrote: > > > > Hi, > > > > On Thu, Jul 25, 2019 at 05:09:17AM -0400, Frediano Ziglio wrote: > > > > > > > > Added command-line option for shared CD devices and respective > > > > property in usb-device-manager. > > > > > > > > Signed-off-by: Yuri Be

Re: [Spice-devel] [spice-gtk 3/9] usb-redir: Prepare for creation of emulated CD drive

2019-07-25 Thread Yuri Benditovich
On Thu, Jul 25, 2019 at 1:32 PM Victor Toso wrote: > > Hi, > > On Thu, Jul 25, 2019 at 05:09:17AM -0400, Frediano Ziglio wrote: > > > > > > Added command-line option for shared CD devices and respective > > > property in usb-device-manager. > > > > > > Signed-off-by: Yuri Benditovich > > > --- >

Re: [Spice-devel] [spice-gtk 3/9] usb-redir: Prepare for creation of emulated CD drive

2019-07-25 Thread Yuri Benditovich
On Thu, Jul 25, 2019 at 12:09 PM Frediano Ziglio wrote: > > > > > Added command-line option for shared CD devices and respective > > property in usb-device-manager. > > > > Signed-off-by: Yuri Benditovich > > --- > > src/spice-option.c | 15 +++ > > src/usb-device-manager.c | 3

Re: [Spice-devel] [spice-gtk 1/9] usb-redir: define interfaces to support emulated devices

2019-07-25 Thread Yuri Benditovich
On Thu, Jul 25, 2019 at 11:57 AM Frediano Ziglio wrote: > > > > > SpiceUsbBackendDevice structure is extended to support > > additional kind of device that is emulated by Spice-GTK > > and not present locally (and does not have libusb_device), > > such device has instead pointer to SpiceUsbEmulate

[Spice-devel] [PATCH spice-gtk 3/3] usb-device-manager: Use SpiceUsbBackendDevice directly instead of SpiceUsbDevice

2019-07-25 Thread Frediano Ziglio
They were the same structure. Signed-off-by: Frediano Ziglio --- src/usb-backend.c| 6 +++--- src/usb-backend.h| 6 +++--- src/usb-device-manager.c | 42 +++- 3 files changed, 17 insertions(+), 37 deletions(-) diff --git a/src/usb-backend.c

[Spice-devel] [PATCH spice-gtk 1/3] usb-backend: Cache isochronous value

2019-07-25 Thread Frediano Ziglio
Allows to remove _SpiceUsbDevice structure. _SpiceUsbDevice is only caching this value from SpiceUsbBackendDevice. Signed-off-by: Frediano Ziglio --- src/usb-backend.c | 9 + 1 file changed, 9 insertions(+) diff --git a/src/usb-backend.c b/src/usb-backend.c index 9ac8595c..7e0e4a8a 1006

[Spice-devel] [PATCH spice-gtk 2/3] usb-device-manager: Remove isochronous field from _SpiceUsbDevice

2019-07-25 Thread Frediano Ziglio
Report directly value from SpiceUsbBackendDevice. Signed-off-by: Frediano Ziglio --- src/usb-device-manager.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/usb-device-manager.c b/src/usb-device-manager.c index a530be9e..bf1c23bd 100644 --- a/src/usb-device-manager.c

Re: [Spice-devel] [spice-gtk v3] spice-option: warn on command line failures of usbredir

2019-07-25 Thread Frediano Ziglio
> > From: Victor Toso > > As spice_usb_device_manager_get() can fail for different reasons, we > should ignore and continue but at least give a warning" > > Signed-off-by: Victor Toso Acked > --- > src/spice-option.c | 24 > 1 file changed, 20 insertions(+), 4 delet

Re: [Spice-devel] [spice-gtk 5/9] usb-redir: do not use spice_usb_acl_helper for emulated devices

2019-07-25 Thread Yuri Benditovich
On Thu, Jul 25, 2019 at 12:17 PM Frediano Ziglio wrote: > > > > > Signed-off-by: Yuri Benditovich > > --- > > src/channel-usbredir.c | 29 ++--- > > 1 file changed, 14 insertions(+), 15 deletions(-) > > > > diff --git a/src/channel-usbredir.c b/src/channel-usbredir.c > >

Re: [Spice-devel] [PATCH] gpu: drm: qxl: Fix possible null-pointer dereferences in qxl_crtc_atomic_flush()

2019-07-25 Thread Daniel Vetter
On Thu, Jul 25, 2019 at 06:21:27PM +0800, Jia-Ju Bai wrote: > In qxl_crtc_atomic_flush(), there is an if statement on line 376 to > check whether crtc->state is NULL: > if (crtc->state && crtc->state->event) > > When crtc->state is NULL and qxl_crtc_update_monitors_config() is call, > qxl_crt

[Spice-devel] [spice-gtk v3] spice-option: warn on command line failures of usbredir

2019-07-25 Thread Victor Toso
From: Victor Toso As spice_usb_device_manager_get() can fail for different reasons, we should ignore and continue but at least give a warning" Signed-off-by: Victor Toso --- src/spice-option.c | 24 1 file changed, 20 insertions(+), 4 deletions(-) diff --git a/src/spi

Re: [Spice-devel] [spice-gtk 2/9] usb-redir: device error signal without device object

2019-07-25 Thread Frediano Ziglio
> > On Thu, Jul 25, 2019 at 12:01 PM Frediano Ziglio wrote: > > > > > > > > Add ability to indicate error to external modules via > > > 'device error' signal when real SpiceUsbDevice is not passed. > > > This is needed to indicate error during creation of emulated > > > device, when the device is

Re: [Spice-devel] [spice-gtk 2/9] usb-redir: device error signal without device object

2019-07-25 Thread Yuri Benditovich
On Thu, Jul 25, 2019 at 12:01 PM Frediano Ziglio wrote: > > > > > Add ability to indicate error to external modules via > > 'device error' signal when real SpiceUsbDevice is not passed. > > This is needed to indicate error during creation of emulated > > device, when the device is not created yet.

Re: [Spice-devel] [spice-gtk v2] spice-option: warn on command line failures of usbredir

2019-07-25 Thread Victor Toso
Hi, On Thu, Jul 25, 2019 at 12:42:51PM +0200, Victor Toso wrote: > From: Victor Toso > > As spice_usb_device_manager_get() can fail for different reasons, we > should silently ignore it and its error. And I forgot to fix the typo again, but I did locally :) > > Signed-off-by: Victor Toso > -

Re: [Spice-devel] [spice-gtk v2] spice-option: warn on command line failures of usbredir

2019-07-25 Thread Frediano Ziglio
> > From: Victor Toso > > As spice_usb_device_manager_get() can fail for different reasons, we > should silently ignore it and its error. > The first comment I made was about this sentence, the code is doing the opposite of what you stated here. The subject is correct (you give a warning), but

Re: [Spice-devel] [spice-gtk 4/9] usb-redir: device description for emulated devices

2019-07-25 Thread Victor Toso
Hi, On Wed, Jul 24, 2019 at 01:53:46PM +0300, Yuri Benditovich wrote: > Ability to retrieve device description for emulated USB > device, defined by implementation. For example, for shared > CD the implementation may use basename of ISO file. > > Signed-off-by: Yuri Benditovich > --- > src/usb-

[Spice-devel] [spice-gtk v2] spice-option: warn on command line failures of usbredir

2019-07-25 Thread Victor Toso
From: Victor Toso As spice_usb_device_manager_get() can fail for different reasons, we should silently ignore it and its error. Signed-off-by: Victor Toso --- src/spice-option.c | 24 1 file changed, 20 insertions(+), 4 deletions(-) diff --git a/src/spice-option.c b/s

Re: [Spice-devel] [spice-gtk] spice-option: warn on command line failures of usbredir

2019-07-25 Thread Victor Toso
Hi, On Thu, Jul 25, 2019 at 06:32:28AM -0400, Frediano Ziglio wrote: > > > > From: Victor Toso > > > > As spice_usb_device_manager_get() can fail for different reasons, we > > should silently ignore it and its error. Sorry, this was a typo. I meant we should not silently ignore the error. > >

Re: [Spice-devel] [spice-gtk 3/9] usb-redir: Prepare for creation of emulated CD drive

2019-07-25 Thread Victor Toso
Hi, On Thu, Jul 25, 2019 at 05:09:17AM -0400, Frediano Ziglio wrote: > > > > Added command-line option for shared CD devices and respective > > property in usb-device-manager. > > > > Signed-off-by: Yuri Benditovich > > --- > > src/spice-option.c | 15 +++ > > src/usb-device-

Re: [Spice-devel] [spice-gtk 3/9] usb-redir: Prepare for creation of emulated CD drive

2019-07-25 Thread Victor Toso
On Wed, Jul 24, 2019 at 01:53:45PM +0300, Yuri Benditovich wrote: > Added command-line option for shared CD devices and respective > property in usb-device-manager. > > Signed-off-by: Yuri Benditovich > --- > src/spice-option.c | 15 +++ > src/usb-device-manager.c | 33

Re: [Spice-devel] [spice-gtk] spice-option: warn on command line failures of usbredir

2019-07-25 Thread Frediano Ziglio
> > From: Victor Toso > > As spice_usb_device_manager_get() can fail for different reasons, we > should silently ignore it and its error. > > Signed-off-by: Victor Toso > --- > src/spice-option.c | 18 ++ > 1 file changed, 14 insertions(+), 4 deletions(-) > > diff --git a/src

[Spice-devel] [PATCH] gpu: drm: qxl: Fix possible null-pointer dereferences in qxl_crtc_atomic_flush()

2019-07-25 Thread Jia-Ju Bai
In qxl_crtc_atomic_flush(), there is an if statement on line 376 to check whether crtc->state is NULL: if (crtc->state && crtc->state->event) When crtc->state is NULL and qxl_crtc_update_monitors_config() is call, qxl_crtc_update_monitors_config() uses crtc->state on line 326: if (crtc->s

[Spice-devel] [spice-gtk] spice-option: warn on command line failures of usbredir

2019-07-25 Thread Victor Toso
From: Victor Toso As spice_usb_device_manager_get() can fail for different reasons, we should silently ignore it and its error. Signed-off-by: Victor Toso --- src/spice-option.c | 18 ++ 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/src/spice-option.c b/src/spi

Re: [Spice-devel] [spice-gtk 5/9] usb-redir: do not use spice_usb_acl_helper for emulated devices

2019-07-25 Thread Frediano Ziglio
> > Signed-off-by: Yuri Benditovich > --- > src/channel-usbredir.c | 29 ++--- > 1 file changed, 14 insertions(+), 15 deletions(-) > > diff --git a/src/channel-usbredir.c b/src/channel-usbredir.c > index 8d4cd66..961a464 100644 > --- a/src/channel-usbredir.c > +++ b/src/

Re: [Spice-devel] [spice-gtk 3/9] usb-redir: Prepare for creation of emulated CD drive

2019-07-25 Thread Frediano Ziglio
> > Added command-line option for shared CD devices and respective > property in usb-device-manager. > > Signed-off-by: Yuri Benditovich > --- > src/spice-option.c | 15 +++ > src/usb-device-manager.c | 33 + > 2 files changed, 48 insertions(+)

Re: [Spice-devel] [spice-gtk 2/9] usb-redir: device error signal without device object

2019-07-25 Thread Frediano Ziglio
> > Add ability to indicate error to external modules via > 'device error' signal when real SpiceUsbDevice is not passed. > This is needed to indicate error during creation of emulated > device, when the device is not created yet. For that we > allocate temporary SpiceUsbDevice structure with back

Re: [Spice-devel] [spice-gtk 1/9] usb-redir: define interfaces to support emulated devices

2019-07-25 Thread Frediano Ziglio
> > SpiceUsbBackendDevice structure is extended to support > additional kind of device that is emulated by Spice-GTK > and not present locally (and does not have libusb_device), > such device has instead pointer to SpiceUsbEmulatedDevice > abstract structure. Specific implementation of such device

Re: [Spice-devel] [spice-gtk 1/9] usb-redir: define interfaces to support emulated devices

2019-07-25 Thread Yuri Benditovich
On Thu, Jul 25, 2019 at 11:08 AM Victor Toso wrote: > > Hi, > > On Wed, Jul 24, 2019 at 01:53:43PM +0300, Yuri Benditovich wrote: > > SpiceUsbBackendDevice structure is extended to support > > additional kind of device that is emulated by Spice-GTK > > and not present locally (and does not have li

Re: [Spice-devel] [spice-gtk 1/9] usb-redir: define interfaces to support emulated devices

2019-07-25 Thread Victor Toso
Hi, On Wed, Jul 24, 2019 at 01:53:43PM +0300, Yuri Benditovich wrote: > SpiceUsbBackendDevice structure is extended to support > additional kind of device that is emulated by Spice-GTK > and not present locally (and does not have libusb_device), > such device has instead pointer to SpiceUsbEmulate

Re: [Spice-devel] [PATCH spice-server 1/2] test-websocket: Some Windows compatibility

2019-07-25 Thread Frediano Ziglio
ping the series > > Don't call close but socket_close. > > Signed-off-by: Frediano Ziglio > --- > server/tests/test-websocket.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > Currently the executable cannot run on Windows but it does not hurt > to make the source more compati

Re: [Spice-devel] [PATCH v2 fixup1 x11spice 2/3] Simplify the expression of argument parsing.

2019-07-25 Thread Frediano Ziglio
> > This fixes a bug with --config=handling. > > Signed-off-by: Jeremy White > --- > v2: Simplify even further. > --- > src/main.c| 8 + > src/options.c | 96 --- > src/options.h | 5 +-- > 3 files changed, 47 insertions(+), 62 deletions