Re: [Spice-devel] [PATCH 3/5] zap dead qxl chunk code

2010-08-26 Thread Alexander Larsson
On Fri, 2010-08-27 at 08:49 +0200, Gerd Hoffmann wrote: > On 08/27/10 08:41, Alexander Larsson wrote: > > On Fri, 2010-08-27 at 00:09 +0200, Gerd Hoffmann wrote: > >> Signed-off-by: Gerd Hoffmann > >> --- > >> server/red_worker.c | 29 - > >> 1 files changed, 0 inse

Re: [Spice-devel] [PATCH 2/5] qxl parser: add cursor parsing

2010-08-26 Thread Alexander Larsson
On Fri, 2010-08-27 at 08:51 +0200, Gerd Hoffmann wrote: > On 08/27/10 08:38, Alexander Larsson wrote: > > On Fri, 2010-08-27 at 00:09 +0200, Gerd Hoffmann wrote: > >> > >> +red->data_size = qxl->data_size; > >> +size = red_get_data_chunks_ptr(slots, group_id, > >> +

Re: [Spice-devel] [PATCH 2/5] qxl parser: add cursor parsing

2010-08-26 Thread Gerd Hoffmann
On 08/27/10 08:38, Alexander Larsson wrote: On Fri, 2010-08-27 at 00:09 +0200, Gerd Hoffmann wrote: +red->data_size = qxl->data_size; +size = red_get_data_chunks_ptr(slots, group_id, + get_memslot_id(slots, addr), +&chunks,&qxl->chunk); +data = red_

Re: [Spice-devel] [PATCH 3/5] zap dead qxl chunk code

2010-08-26 Thread Gerd Hoffmann
On 08/27/10 08:41, Alexander Larsson wrote: On Fri, 2010-08-27 at 00:09 +0200, Gerd Hoffmann wrote: Signed-off-by: Gerd Hoffmann --- server/red_worker.c | 29 - 1 files changed, 0 insertions(+), 29 deletions(-) Actually, you can get rid of BufDescriptor->type,

Re: [Spice-devel] [PATCH 3/5] zap dead qxl chunk code

2010-08-26 Thread Alexander Larsson
On Fri, 2010-08-27 at 00:09 +0200, Gerd Hoffmann wrote: > Signed-off-by: Gerd Hoffmann > --- > server/red_worker.c | 29 - > 1 files changed, 0 insertions(+), 29 deletions(-) Actually, you can get rid of BufDescriptor->type, slot_id, and group_id too. -- =-=-=-=-=

Re: [Spice-devel] [PATCH 5/5] fix red_cursur_flush segfault

2010-08-26 Thread Alexander Larsson
On Fri, 2010-08-27 at 00:09 +0200, Gerd Hoffmann wrote: > Signed-off-by: Gerd Hoffmann > --- > server/red_worker.c |4 +++- > 1 files changed, 3 insertions(+), 1 deletions(-) Ack -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Alexander Larsson

Re: [Spice-devel] [PATCH 4/5] zap dead typedefs

2010-08-26 Thread Alexander Larsson
On Fri, 2010-08-27 at 00:09 +0200, Gerd Hoffmann wrote: > Signed-off-by: Gerd Hoffmann > --- > server/red_worker.c |5 - > 1 files changed, 0 insertions(+), 5 deletions(-) > > diff --git a/server/red_worker.c b/server/red_worker.c > index 17bbf6f..1975597 100644 > --- a/server/red_worker

Re: [Spice-devel] [PATCH 3/5] zap dead qxl chunk code

2010-08-26 Thread Alexander Larsson
On Fri, 2010-08-27 at 00:09 +0200, Gerd Hoffmann wrote: > Signed-off-by: Gerd Hoffmann > --- > server/red_worker.c | 29 - > 1 files changed, 0 insertions(+), 29 deletions(-) Ack -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Alexa

Re: [Spice-devel] [PATCH 2/5] qxl parser: add cursor parsing

2010-08-26 Thread Alexander Larsson
On Fri, 2010-08-27 at 00:09 +0200, Gerd Hoffmann wrote: > > +red->data_size = qxl->data_size; > +size = red_get_data_chunks_ptr(slots, group_id, > + get_memslot_id(slots, addr), > + &chunks, &qxl->chunk); > +data = red

Re: [Spice-devel] [PATCH 1/5] qxl parser: complete QXL_SURFACE_CMD_CREATE parsing

2010-08-26 Thread Alexander Larsson
On Fri, 2010-08-27 at 00:09 +0200, Gerd Hoffmann wrote: > Signed-off-by: Gerd Hoffmann > --- > server/red_parse_qxl.c |5 - > server/red_parse_qxl.h |2 +- > server/red_worker.c|3 +-- > 3 files changed, 6 insertions(+), 4 deletions(-) Ack -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

[Spice-devel] [PATCH 2/5] qxl parser: add cursor parsing

2010-08-26 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- server/red_parse_qxl.c | 46 +++- server/red_parse_qxl.h |2 +- server/red_worker.c| 59 +++ 3 files changed, 59 insertions(+), 48 deletions(-) diff --git a/server/red_parse_

[Spice-devel] [PATCH 5/5] fix red_cursur_flush segfault

2010-08-26 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- server/red_worker.c |4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/server/red_worker.c b/server/red_worker.c index 1975597..ec9f6bb 100644 --- a/server/red_worker.c +++ b/server/red_worker.c @@ -9574,7 +9574,7 @@ static LocalCursor *_

[Spice-devel] [PATCH 3/5] zap dead qxl chunk code

2010-08-26 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- server/red_worker.c | 29 - 1 files changed, 0 insertions(+), 29 deletions(-) diff --git a/server/red_worker.c b/server/red_worker.c index f525f17..17bbf6f 100644 --- a/server/red_worker.c +++ b/server/red_worker.c @@ -222,7 +222,6

[Spice-devel] [PATCH 4/5] zap dead typedefs

2010-08-26 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- server/red_worker.c |5 - 1 files changed, 0 insertions(+), 5 deletions(-) diff --git a/server/red_worker.c b/server/red_worker.c index 17bbf6f..1975597 100644 --- a/server/red_worker.c +++ b/server/red_worker.c @@ -522,11 +522,6 @@ typedef struct FreeLi

[Spice-devel] [PATCH 1/5] qxl parser: complete QXL_SURFACE_CMD_CREATE parsing

2010-08-26 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- server/red_parse_qxl.c |5 - server/red_parse_qxl.h |2 +- server/red_worker.c|3 +-- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/server/red_parse_qxl.c b/server/red_parse_qxl.c index 127141c..fb46bd8 100644 --- a/server/red

[Spice-devel] [PATCH 2/2] server: red_send_image() - append image data to right marshaller

2010-08-26 Thread alexl
From: Alexander Larsson The actual bitmap data was added to the main marshaller rather than the submarshaller that pointed to the SpiceImage part. This made us send too short messages failing demarshalling in the client. --- server/red_worker.c |3 ++- 1 files changed, 2 insertions(+), 1 del

[Spice-devel] [PATCH 1/2] server: red_send_image() initialize bitmap.flags

2010-08-26 Thread alexl
From: Alexander Larsson We're currently sending this to the network based on random memory. --- server/red_worker.c |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/server/red_worker.c b/server/red_worker.c index 27d9491..da7e8e8 100644 --- a/server/red_worker.c +++ b/ser

[Spice-devel] [PATCH 0/2] Fix yonits demarshaller failure

2010-08-26 Thread alexl
From: Alexander Larsson Yonit found a demarshaller failure and managed to track it down to some error in red_send_image() when comp_succeeded was FALSE. There were to small bugs causing this. Alexander Larsson (2): server: red_send_image() initialize bitmap.flags server: red_send_image() - a

Re: [Spice-devel] [PATCH 1/2] server: Don't send stream frames that are identical to the last one

2010-08-26 Thread Yonit Halperin
On 08/25/2010 11:49 AM, al...@redhat.com wrote: From: Alexander Larsson This happens e.g. with the vlc player when paused, as it still draws a continuous stream of frames (bug #28817). It may also help slightly if a video contains identical frames in a row for other reasons. We detect frame equ

Re: [Spice-devel] [PATCH 2/2] Detect played silence and stop audio stream after 1 second

2010-08-26 Thread Yonit Halperin
On 08/25/2010 11:49 AM, al...@redhat.com wrote: From: Alexander Larsson VLC sends silence when paused (bug #28817), which causes a lot of unnecessary network traffic. We detect such silence and shut down the clients audio stream (even though the audio is still active in the server), re-enabling

Re: [Spice-devel] [PATCH 2/3] server: really wait for a surface to be destroyed, when calling destroy_surface_wait

2010-08-26 Thread Alexander Larsson
On Thu, 2010-08-26 at 17:28 +0300, Yonit Halperin wrote: > On 08/26/2010 05:25 PM, Alexander Larsson wrote: > red_push doesn't send one item at a time, but rather pushes till it > blocks (due to socket block or missing acks). So if the item is still in > the pipe, it means that channel->send_data

Re: [Spice-devel] [PATCH 1/3] server: consider also PIPE_ITEM_UPGRADE when searching for drawables in red_clear_surface_drawables_from_pipe

2010-08-26 Thread Alexander Larsson
On Thu, 2010-08-26 at 17:00 +0300, Yonit Halperin wrote: > On 08/26/2010 04:58 PM, Alexander Larsson wrote: > > On Thu, 2010-08-26 at 12:41 +0300, Yonit Halperin wrote: > >> --- > >> server/red_worker.c | 36 +++- > >> 1 files changed, 19 insertions(+), 17 delet

Re: [Spice-devel] [PATCH v3] spice-{vmc,vdi}: implement subtype

2010-08-26 Thread Alexander Larsson
On Thu, 2010-08-26 at 10:28 -0400, Alon Levy wrote: > v3 changes: > subtype is now a field of SpiceCharDeviceInstance > > btw, there shouldn't be a newline added before vdi_port_interface, > but I can't get git diff to admit there isn't one there. I'll make > sure there isn't one in the committed

Re: [Spice-devel] [PATCH 2/3] server: really wait for a surface to be destroyed, when calling destroy_surface_wait

2010-08-26 Thread Yonit Halperin
On 08/26/2010 05:25 PM, Alexander Larsson wrote: On Thu, 2010-08-26 at 12:41 +0300, Yonit Halperin wrote: Waiting till all the pipe items that are dependent on the surface will be sent. This was probably the cause for freedesktop bug #29750. --- server/red_worker.c | 84 +

Re: [Spice-devel] [PATCH v3] server: add subtype to SpiceCharDeviceInterface, use for vdagent

2010-08-26 Thread Alexander Larsson
On Thu, 2010-08-26 at 10:12 -0400, Alon Levy wrote: > v3 changes: > subtype now part of SpiceCharDeviceInstance, not a method of S.C.D.Interface Ack ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/li

[Spice-devel] [PATCH v3] spice-{vmc,vdi}: implement subtype

2010-08-26 Thread Alon Levy
v3 changes: subtype is now a field of SpiceCharDeviceInstance btw, there shouldn't be a newline added before vdi_port_interface, but I can't get git diff to admit there isn't one there. I'll make sure there isn't one in the committed version. --- hw/spice-vdi.c |2 ++ hw/spice-vmc.c | 39

Re: [Spice-devel] [PATCH 3/3] server: cleanups in destorying surfaces code

2010-08-26 Thread Alexander Larsson
On Thu, 2010-08-26 at 12:41 +0300, Yonit Halperin wrote: > --- > server/red_worker.c | 51 > ++- > 1 files changed, 22 insertions(+), 29 deletions(-) Ack ___ Spice-devel mailing list Spice-devel@list

Re: [Spice-devel] [PATCH 2/3] server: really wait for a surface to be destroyed, when calling destroy_surface_wait

2010-08-26 Thread Alexander Larsson
On Thu, 2010-08-26 at 12:41 +0300, Yonit Halperin wrote: > Waiting till all the pipe items that are dependent on the surface will be > sent. > This was probably the cause for freedesktop bug #29750. > --- > server/red_worker.c | 84 +- > 1 files c

[Spice-devel] [PATCH v3] server: add subtype to SpiceCharDeviceInterface, use for vdagent

2010-08-26 Thread Alon Levy
v3 changes: subtype now part of SpiceCharDeviceInstance, not a method of S.C.D.Interface --- server/reds.c | 55 +- server/spice-experimental.h |2 + 2 files changed, 50 insertions(+), 7 deletions(-) diff --git a/server/reds.c b/server

Re: [Spice-devel] [PATCH 2/2] spice-{vmc,vdi}: implement subtype

2010-08-26 Thread Alon Levy
- "Alexander Larsson" wrote: > On Thu, 2010-08-26 at 04:46 -0400, Alon Levy wrote: > > --- > > hw/spice-vdi.c |6 ++ > > hw/spice-vmc.c | 47 > +++ > > 2 files changed, 53 insertions(+), 0 deletions(-) > > > > diff --git a/hw/spice-vdi.

Re: [Spice-devel] [PATCH 1/3] server: consider also PIPE_ITEM_UPGRADE when searching for drawables in red_clear_surface_drawables_from_pipe

2010-08-26 Thread Yonit Halperin
On 08/26/2010 04:58 PM, Alexander Larsson wrote: On Thu, 2010-08-26 at 12:41 +0300, Yonit Halperin wrote: --- server/red_worker.c | 36 +++- 1 files changed, 19 insertions(+), 17 deletions(-) Don't you also need to check for ImageItems with the same surfac

Re: [Spice-devel] [PATCH 1/3] server: consider also PIPE_ITEM_UPGRADE when searching for drawables in red_clear_surface_drawables_from_pipe

2010-08-26 Thread Alexander Larsson
On Thu, 2010-08-26 at 12:41 +0300, Yonit Halperin wrote: > --- > server/red_worker.c | 36 +++- > 1 files changed, 19 insertions(+), 17 deletions(-) Don't you also need to check for ImageItems with the same surface_id?

Re: [Spice-devel] [PATCH 2/2] spice-{vmc,vdi}: implement subtype

2010-08-26 Thread Alexander Larsson
On Thu, 2010-08-26 at 04:46 -0400, Alon Levy wrote: > --- > hw/spice-vdi.c |6 ++ > hw/spice-vmc.c | 47 +++ > 2 files changed, 53 insertions(+), 0 deletions(-) > > diff --git a/hw/spice-vdi.c b/hw/spice-vdi.c > index 415932b..f5fda4d 100644 >

Re: [Spice-devel] [PATCH 1/2] spice-{vdi, vmc}: rename SpiceVDIPort* to SpiceCharDevice*

2010-08-26 Thread Alexander Larsson
On Thu, 2010-08-26 at 04:46 -0400, Alon Levy wrote: > --- > hw/spice-vdi.c | 16 > hw/spice-vmc.c | 22 +++--- > 2 files changed, 19 insertions(+), 19 deletions(-) Ack ___ Spice-devel mailing list Spice-devel@list

Re: [Spice-devel] [PATCH 1/2] server: rename SpiceVDIPort* to SpiceCharDevice*

2010-08-26 Thread Alexander Larsson
On Thu, 2010-08-26 at 04:44 -0400, Alon Levy wrote: > --- > server/reds.c | 48 +- > server/spice-experimental.h | 28 > 2 files changed, 38 insertions(+), 38 deletions(-) Ack _

Re: [Spice-devel] [PATCH 2/2] server: add subtype to SpiceCharDeviceInterface, use for vdagent

2010-08-26 Thread Alexander Larsson
On Thu, 2010-08-26 at 04:45 -0400, Alon Levy wrote: > diff --git a/server/spice-experimental.h b/server/spice-experimental.h > index e40b3ec..fd8ef67 100644 > --- a/server/spice-experimental.h > +++ b/server/spice-experimental.h > @@ -10,6 +10,7 @@ typedef struct SpiceCharDeviceState SpiceCharDevi

Re: [Spice-devel] [PATCH 1/1] Add API to turn on backwards compatibility mode

2010-08-26 Thread Alexander Larsson
On Thu, 2010-08-26 at 09:26 -0400, Alon Levy wrote: > - al...@redhat.com wrote: > > > From: Alexander Larsson > > > > When upgrading a cluster of machines you typically do this by > > upgrading a set of machines at a time, making the new machines run > > the new software version, but in a fa

Re: [Spice-devel] [RFC 1/2] spice, server: introduce SpiceCharDevice

2010-08-26 Thread Alexander Larsson
On Wed, 2010-08-25 at 11:19 -0400, Alon Levy wrote: > - "Alexander Larsson" wrote: > > > +const char* (*subtype)(SpiceCharDeviceInstance *sin); > > > > I don't think we need a callback here. Just make this a const char *. > > > > No, that doesn't work - the subtype is not a feature of t

Re: [Spice-devel] [PATCH 1/1] Add API to turn on backwards compatibility mode

2010-08-26 Thread Alon Levy
- al...@redhat.com wrote: > From: Alexander Larsson > > When upgrading a cluster of machines you typically do this by > upgrading a set of machines at a time, making the new machines run > the new software version, but in a fashion compatible with the old > versions (in terms of e.g. migrat

[Spice-devel] [PATCH 1/1] Add API to turn on backwards compatibility mode

2010-08-26 Thread alexl
From: Alexander Larsson When upgrading a cluster of machines you typically do this by upgrading a set of machines at a time, making the new machines run the new software version, but in a fashion compatible with the old versions (in terms of e.g. migration). Then when all machines are any new fea

[Spice-devel] [PATCH 0/1] Version compat API

2010-08-26 Thread alexl
From: Alexander Larsson Adds libspice API to handle backwards compatibility. Alexander Larsson (1): Add API to turn on backwards compatibility mode server/reds.c | 20 server/spice.h | 13 + 2 files changed, 33 insertions(+), 0 deletions(-)

[Spice-devel] [PATCH 3/3] server: cleanups in destorying surfaces code

2010-08-26 Thread Yonit Halperin
--- server/red_worker.c | 51 ++- 1 files changed, 22 insertions(+), 29 deletions(-) diff --git a/server/red_worker.c b/server/red_worker.c index e688971..e0204de 100644 --- a/server/red_worker.c +++ b/server/red_worker.c @@ -1507,20 +1507,20 @@ s

[Spice-devel] [PATCH 2/3] server: really wait for a surface to be destroyed, when calling destroy_surface_wait

2010-08-26 Thread Yonit Halperin
Waiting till all the pipe items that are dependent on the surface will be sent. This was probably the cause for freedesktop bug #29750. --- server/red_worker.c | 84 +- 1 files changed, 75 insertions(+), 9 deletions(-) diff --git a/server/red_work

[Spice-devel] [PATCH 1/3] server: consider also PIPE_ITEM_UPGRADE when searching for drawables in red_clear_surface_drawables_from_pipe

2010-08-26 Thread Yonit Halperin
--- server/red_worker.c | 36 +++- 1 files changed, 19 insertions(+), 17 deletions(-) diff --git a/server/red_worker.c b/server/red_worker.c index 27d9491..1a3f755 100644 --- a/server/red_worker.c +++ b/server/red_worker.c @@ -1807,30 +1807,32 @@ static void red

[Spice-devel] [PATCH 0/3] Server fixes and cleanups for destorying surface

2010-08-26 Thread Yonit Halperin
Fixes for server crash, #29750. And cleanups in destroy surfaces code. Yonit Halperin (3): server: consider also PIPE_ITEM_UPGRADE when searching for drawables in red_clear_surface_drawables_from_pipe server: really wait for a surface to be destroyed, when calling destroy_surface_wait

[Spice-devel] [PATCH 2/2] spice-{vmc,vdi}: implement subtype

2010-08-26 Thread Alon Levy
--- hw/spice-vdi.c |6 ++ hw/spice-vmc.c | 47 +++ 2 files changed, 53 insertions(+), 0 deletions(-) diff --git a/hw/spice-vdi.c b/hw/spice-vdi.c index 415932b..f5fda4d 100644 --- a/hw/spice-vdi.c +++ b/hw/spice-vdi.c @@ -290,12 +290,18 @@ st

[Spice-devel] [PATCH 1/2] spice-{vdi, vmc}: rename SpiceVDIPort* to SpiceCharDevice*

2010-08-26 Thread Alon Levy
--- hw/spice-vdi.c | 16 hw/spice-vmc.c | 22 +++--- 2 files changed, 19 insertions(+), 19 deletions(-) diff --git a/hw/spice-vdi.c b/hw/spice-vdi.c index 23cbbe1..415932b 100644 --- a/hw/spice-vdi.c +++ b/hw/spice-vdi.c @@ -104,7 +104,7 @@ typedef struct PCI

[Spice-devel] [PATCH 2/2] server: add subtype to SpiceCharDeviceInterface, use for vdagent

2010-08-26 Thread Alon Levy
--- server/reds.c | 56 +- server/spice-experimental.h |2 + 2 files changed, 51 insertions(+), 7 deletions(-) diff --git a/server/reds.c b/server/reds.c index 0870612..e5a61cb 100644 --- a/server/reds.c +++ b/server/reds.c @@ -184,6 +1

[Spice-devel] [PATCH 1/2] server: rename SpiceVDIPort* to SpiceCharDevice*

2010-08-26 Thread Alon Levy
--- server/reds.c | 48 +- server/spice-experimental.h | 28 2 files changed, 38 insertions(+), 38 deletions(-) diff --git a/server/reds.c b/server/reds.c index 571013f..0870612 100644 --- a/server/reds.c +++ b/se