Re: [Qemu-devel] [RFC 7/7] qxl: add allocator

2012-02-21 Thread Alon Levy
On Tue, Feb 21, 2012 at 08:57:54AM +0100, Gerd Hoffmann wrote: Hi, TBH I'm having problems without doing it with my own Allocator. In particular calling ppm_save from spice_server thread seems to be a problem. Grabbed the qemu mutex? Didn't we remove qemu mutex grabbing from the

Re: [Qemu-devel] [RFC 7/7] qxl: add allocator

2012-02-21 Thread Gerd Hoffmann
Hi, Right now qxl_render_update checks if the displaysurface buffer is not shared, meaning it was allocated by qemu, and in this case it replaces it with the flipped buffer. I think we should first reqire spice-server 0.8.latest, so update_area_complete is available unconditionally.

Re: [Qemu-devel] [RFC 7/7] qxl: add allocator

2012-02-21 Thread Alon Levy
On Tue, Feb 21, 2012 at 10:20:49AM +0100, Gerd Hoffmann wrote: Hi, Right now qxl_render_update checks if the displaysurface buffer is not shared, meaning it was allocated by qemu, and in this case it replaces it with the flipped buffer. I think we should first reqire spice-server

Re: [Qemu-devel] [RFC 7/7] qxl: add allocator

2012-02-20 Thread Gerd Hoffmann
On 02/19/12 22:28, Alon Levy wrote: Add an implementation of the DisplayAllocator callbacks for qxl. Uses the QEMU_ALLOCATED_FLAG to ensure vga/vga_draw_graphic does the 24 to 32 bits per pixel line convertion. Since free/resize/create are defined in qxl.c, it is easy to ensure consistent

Re: [Qemu-devel] [RFC 7/7] qxl: add allocator

2012-02-20 Thread Alon Levy
On Mon, Feb 20, 2012 at 12:41:09PM +0100, Gerd Hoffmann wrote: On 02/19/12 22:28, Alon Levy wrote: Add an implementation of the DisplayAllocator callbacks for qxl. Uses the QEMU_ALLOCATED_FLAG to ensure vga/vga_draw_graphic does the 24 to 32 bits per pixel line convertion. Since

Re: [Qemu-devel] [RFC 7/7] qxl: add allocator

2012-02-20 Thread Gerd Hoffmann
Hi, I'll send a series that works with vnc+spice and sdl+spice (didn't test sdl+vnc+spice), and screendumps at the same time. Setting the QEMU_ALLOCATED_FLAG flag sounds hackish too. QEMU_ALLOCATED_FLAG is just a flag which is used by the defaultallocator_free_displaysurface function to

Re: [Qemu-devel] [RFC 7/7] qxl: add allocator

2012-02-20 Thread Alon Levy
On Mon, Feb 20, 2012 at 02:18:19PM +0100, Gerd Hoffmann wrote: Hi, I'll send a series that works with vnc+spice and sdl+spice (didn't test sdl+vnc+spice), and screendumps at the same time. Setting the QEMU_ALLOCATED_FLAG flag sounds hackish too. QEMU_ALLOCATED_FLAG is just a

Re: [Qemu-devel] [RFC 7/7] qxl: add allocator

2012-02-20 Thread Gerd Hoffmann
Hi, TBH I'm having problems without doing it with my own Allocator. In particular calling ppm_save from spice_server thread seems to be a problem. Grabbed the qemu mutex? BTW: qxl insisting on a shared displaysurface isn't very clean too, it better should be able to fallback to just

[Qemu-devel] [RFC 7/7] qxl: add allocator

2012-02-19 Thread Alon Levy
Add an implementation of the DisplayAllocator callbacks for qxl. Uses the QEMU_ALLOCATED_FLAG to ensure vga/vga_draw_graphic does the 24 to 32 bits per pixel line convertion. Since free/resize/create are defined in qxl.c, it is easy to ensure consistent usage of the flag (it means QXL_ALLOCATED