[Qemu-devel] [PATCH] vscclient: do not add a socket watch if there is not data to send

2013-06-06 Thread Marc-André Lureau
Fixes the following error: ** (process:780): CRITICAL **: do_socket_send: assertion `socket_to_send-len != 0' failed Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- libcacard/vscclient.c | 10 ++ 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/libcacard

[Qemu-devel] [PATCH] spice: replace use of deprecated API

2013-10-04 Thread Marc-André Lureau
hose API are deprecated since 0.11, and qemu depends on 0.12 already. --- hw/display/qxl.c | 16 ui/spice-core.c| 15 +++ ui/spice-display.c | 10 +- 3 files changed, 20 insertions(+), 21 deletions(-) diff --git a/hw/display/qxl.c b/hw/display/qxl.c

[Qemu-devel] [PATCH for-1.7] vga: fix invalid read after free

2013-11-05 Thread Marc-André Lureau
(spice-display.c:418) ==5370==by 0x2A7D01: display_refresh (qxl.c:1886) ==5370==by 0x3EEE1C: dpy_refresh (console.c:1436) Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- hw/display/vga.c | 1 - 1 file changed, 1 deletion(-) diff --git a/hw/display/vga.c b/hw/display/vga.c

[Qemu-devel] [PATCH 00/21] RFCv2: add Spice block device

2013-11-18 Thread Marc-André Lureau
to avoid extra media changed notifications, which is easily done by checking migration state. Marc-André Lureau (21): vscclient: do not add a socket watch if there is not data to send spice-char: remove unused field qmp_change_blockdev() remove unused has_format include: add missing config

[Qemu-devel] [PATCH 01/21] vscclient: do not add a socket watch if there is not data to send

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Fixes the following error: ** (process:780): CRITICAL **: do_socket_send: assertion `socket_to_send-len != 0' failed Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- libcacard/vscclient.c | 10 ++ 1 file changed, 6

[Qemu-devel] [PATCH 03/21] qmp_change_blockdev() remove unused has_format

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- blockdev.c| 2 +- include/sysemu/blockdev.h | 2 +- qmp.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/blockdev.c b

[Qemu-devel] [PATCH 04/21] include: add missing config-host.h include

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- include/ui/qemu-spice.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/ui/qemu-spice.h b/include/ui/qemu-spice.h index 86c75c7..a93b4b2 100644 --- a/include/ui/qemu

[Qemu-devel] [PATCH 06/21] Split nbd block client code

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block/Makefile.objs | 2 +- block/nbd-client.c | 372 +++ block/nbd-client.h | 51 +++ block/nbd.c | 373

[Qemu-devel] [PATCH 05/21] char: add qemu_chr_fe_event()

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- include/sysemu/char.h | 10 ++ qemu-char.c | 7 +++ spice-qemu-char.c | 10 ++ 3 files changed, 27 insertions(+) diff --git a/include/sysemu

[Qemu-devel] [PATCH 13/21] blockdev: add qmp_change_blockdev_int()

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Allow to pass additional arguments, such as options and opaque Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- blockdev.c| 24 +++- include/sysemu/blockdev.h | 3 +++ 2 files changed, 22

[Qemu-devel] [PATCH 07/21] nbd: don't change socket block during negotiate

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com The caller might handle non-blocking using coroutine. Leave the choice to the caller to use a blocking or non-blocking negotiate. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- nbd.c | 1 - 1 file changed, 1 deletion(-) diff

[Qemu-devel] [PATCH 10/21] nbd: finish any pending coroutine

2013-11-18 Thread Marc-André Lureau
Make sure all pending coroutines are finished when closing the session. Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- block/nbd-client.c | 22 +- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/block/nbd-client.c b/block/nbd-client.c index

[Qemu-devel] [PATCH 08/21] nbd: pass export name as init argument

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com There is no need to keep the export name around, and it seems a better fit as an argument in the init() call. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block/nbd-client.c | 10 -- block/nbd-client.h | 5

[Qemu-devel] [PATCH 14/21] block: extract make_snapshot() from bdrv_open()

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block.c | 121 +--- 1 file changed, 70 insertions(+), 51 deletions(-) diff --git a/block.c b/block.c index 0558525

[Qemu-devel] [PATCH 11/21] nbd: avoid uninitialized warnings

2013-11-18 Thread Marc-André Lureau
:1519) ==15815==by 0x1AD804: bdrv_delete (block.c:1772) ==15815==by 0x1B4136: bdrv_unref (block.c:4476) ==15815==by 0x1ACCE0: bdrv_close (block.c:1541) ==15815== Address 0x7feffef98 is on thread 1's stack Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- block/nbd-client.c

[Qemu-devel] [PATCH 15/21] block: add snapshot.size option to avoid extra bdrv_open()

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block.c | 19 --- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/block.c b/block.c index 09aada5..9e7632e 100644 --- a/block.c +++ b/block.c

[Qemu-devel] [PATCH 17/21] block: allow to call bdrv_open() with an opaque

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com If the block driver already has a bs-opaque when calling bdrv_open(), pass it down to the file driver. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com Conflicts: block.c --- block.c | 9 +++-- 1 file changed, 7

[Qemu-devel] [PATCH 18/21] block: do not notify change during migration

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com When starting qemu, a block driver isn't associated with a device, so no notification is emitted when the media is loaded. The Spice block driver loads the media during migration. But at that time, the device is already associated, however, we

[Qemu-devel] [PATCH 20/21] spice-core: allow an interface to be in AIO context

2013-11-18 Thread Marc-André Lureau
with a different context. Currently, the interface user_data is simply used to differentiate main loop from AIO, but could later be used to associate an interface with a particular thread. Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- include/ui/qemu-spice.h | 2 +- qemu-char.c

[Qemu-devel] [PATCH 21/21] block: add spice block device backend

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block/Makefile.objs | 1 + block/spicebd.c | 536 2 files changed, 537 insertions(+) create mode 100644 block/spicebd.c

[Qemu-devel] [PATCH 02/21] spice-char: remove unused field

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- spice-qemu-char.c | 1 - 1 file changed, 1 deletion(-) diff --git a/spice-qemu-char.c b/spice-qemu-char.c index 6d147a7..e074d9e 100644 --- a/spice-qemu-char.c +++ b/spice-qemu

[Qemu-devel] [PATCH 19/21] sysemu: add vm_start_hold/release

2013-11-18 Thread Marc-André Lureau
is started, but using a running main loop. Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- include/sysemu/sysemu.h | 2 ++ vl.c| 17 + 2 files changed, 19 insertions(+) diff --git a/include/sysemu/sysemu.h b/include/sysemu/sysemu.h index cd5791e

[Qemu-devel] [PATCH 16/21] block: learn to open a driver with a given opaque

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com If the block driver is given an opaque data, there is no need to allocate a new one. This allows to pass an existing driver state to the new driver. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block.c | 48

[Qemu-devel] [PATCH 09/21] nbd: make session_close() idempotent

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block/nbd-client.c | 5 + 1 file changed, 5 insertions(+) diff --git a/block/nbd-client.c b/block/nbd-client.c index e29227b..c0ad2c2 100644 --- a/block/nbd-client.c +++ b

[Qemu-devel] [PATCH 12/21] block: save the associated child name in BlockDriverState

2013-11-18 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com This allows the Spice block driver to eject the associated device. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block.c | 58 --- include/block/block_int.h | 1

Re: [Qemu-devel] [PATCH 21/21] block: add spice block device backend

2013-11-20 Thread Marc-André Lureau
/note to self: - add failing case where nbd channel isn't connected before and after migration (do not wait for nbd init or disconnection) On Mon, Nov 18, 2013 at 1:25 PM, Marc-André Lureau marcandre.lur...@gmail.com wrote: From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off

Re: [Qemu-devel] [PATCH 00/21] RFCv2: add Spice block device

2013-11-22 Thread Marc-André Lureau
Hi there, Even though there is no rush to review this series, it would be nice to get the first ~10 patches. It would make the next rebase easier, and the review smaller. cheers On Mon, Nov 18, 2013 at 1:25 PM, Marc-André Lureau marcandre.lur...@gmail.com wrote: Hi, The following patch

[Qemu-devel] WIP coroutine support in GLib

2013-11-26 Thread Marc-André Lureau
://bugzilla.gnome.org/show_bug.cgi?id=719362. If the proposal isn't refused, I'll keep working on it as it's incomplete at this point and will provide a qemu patch as a proof of concept. cheers -- Marc-André Lureau

[Qemu-devel] [PATCH] coroutine: remove qemu_co_queue_wait_insert_head

2013-11-27 Thread Marc-André Lureau
qemu_co_queue_wait_insert_head() is unused in qemu code base now. Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- include/block/coroutine.h | 6 -- qemu-coroutine-lock.c | 8 2 files changed, 14 deletions(-) diff --git a/include/block/coroutine.h b/include/block

[Qemu-devel] [PATCH 10/12] block: learn to open a driver with a given opaque

2013-06-20 Thread Marc-André Lureau
If the block driver is given an opaque data, there is no need to allocate a new one. This allows to pass an existing driver state to the new driver. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block.c | 47 --- 1 file changed, 28

[Qemu-devel] [PATCH 08/12] block: extract make_snapshot() from bdrv_open()

2013-06-20 Thread Marc-André Lureau
Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block.c | 107 +--- 1 file changed, 62 insertions(+), 45 deletions(-) diff --git a/block.c b/block.c index f502eed..5db8fa1 100644 --- a/block.c +++ b/block.c @@ -959,6

[Qemu-devel] [PATCH 12/12] block: add spice block device backend

2013-06-20 Thread Marc-André Lureau
Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block/Makefile.objs | 1 + block/spice.c | 523 2 files changed, 524 insertions(+) create mode 100644 block/spice.c diff --git a/block/Makefile.objs b/block

[Qemu-devel] [PATCH 04/12] Split nbd block client code

2013-06-20 Thread Marc-André Lureau
Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block/Makefile.objs | 2 +- block/nbd-client.c | 386 +++ block/nbd-client.h | 52 +++ block/nbd.c | 387 4 files

[Qemu-devel] [PATCH 03/12] nbd: don't change socket block during negotiate

2013-06-20 Thread Marc-André Lureau
The caller might handle non-blocking using coroutine. Leave the choice to the caller to use a blocking or non-blocking noegotiate. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- nbd.c | 1 - 1 file changed, 1 deletion(-) diff --git a/nbd.c b/nbd.c index 2606403..2f8c946 100644

[Qemu-devel] [PATCH 06/12] nbd: make session_close() idempotent

2013-06-20 Thread Marc-André Lureau
Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block/nbd-client.c | 5 + 1 file changed, 5 insertions(+) diff --git a/block/nbd-client.c b/block/nbd-client.c index b7eea21..c49be30 100644 --- a/block/nbd-client.c +++ b/block/nbd-client.c @@ -352,7 +352,12 @@ static void

[Qemu-devel] [PATCH 00/12] RFC: add Spice block device

2013-06-20 Thread Marc-André Lureau
://lists.freedesktop.org/archives/spice-devel/2013-June/013609.html http://lists.freedesktop.org/archives/spice-devel/2013-June/013610.html Marc-André Lureau (12): include: add missing config-host.h include char: add qemu_chr_fe_event() nbd: don't change socket block during negotiate Split nbd

[Qemu-devel] [PATCH 11/12] block: allow to call bdrv_open() with an opaque

2013-06-20 Thread Marc-André Lureau
If the block driver already has a bs-opaque when calling bdrv_open(), pass it down to the file driver. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/block.c b/block.c index bdffb42..ff9cb0b

[Qemu-devel] [PATCH 07/12] block: save the associated child in BlockDriverState

2013-06-20 Thread Marc-André Lureau
This allows the Spice block driver to eject the associated device. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block.c | 46 +- include/block/block_int.h | 1 + 2 files changed, 30 insertions(+), 17 deletions

[Qemu-devel] [PATCH 02/12] char: add qemu_chr_fe_event()

2013-06-20 Thread Marc-André Lureau
Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- include/sysemu/char.h | 10 ++ qemu-char.c | 7 +++ spice-qemu-char.c | 10 ++ 3 files changed, 27 insertions(+) diff --git a/include/sysemu/char.h b/include/sysemu/char.h index 066c216..eee70fe

[Qemu-devel] [PATCH 01/12] include: add missing config-host.h include

2013-06-20 Thread Marc-André Lureau
Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- include/ui/qemu-spice.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/ui/qemu-spice.h b/include/ui/qemu-spice.h index eba6d77..a92b2cf 100644 --- a/include/ui/qemu-spice.h +++ b/include/ui/qemu-spice.h @@ -18,6 +18,8

[Qemu-devel] [PATCH 09/12] block: add snapshot.size option to avoid extra bdrv_open()

2013-06-20 Thread Marc-André Lureau
Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block.c | 17 +++-- 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/block.c b/block.c index 5db8fa1..b421083 100644 --- a/block.c +++ b/block.c @@ -1046,20 +1046,25 @@ int bdrv_open(BlockDriverState *bs

[Qemu-devel] [PATCH 05/12] nbd: pass export name as init argument

2013-06-20 Thread Marc-André Lureau
There is no need to keep the export name around, and it seems a better fit as an argument in the init() call. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block/nbd-client.c | 8 block/nbd-client.h | 5 ++--- block/nbd.c| 13 - 3 files changed

Re: [Qemu-devel] [PATCH 07/12] block: save the associated child in BlockDriverState

2013-06-21 Thread Marc-André Lureau
Hi On Fri, Jun 21, 2013 at 12:25 AM, Paolo Bonzini pbonz...@redhat.com wrote: Il 20/06/2013 19:46, Marc-André Lureau ha scritto: This allows the Spice block driver to eject the associated device. The child can change when you have for example a streaming operation. Ah, can you point me

Re: [Qemu-devel] [PATCH 02/12] char: add qemu_chr_fe_event()

2013-06-21 Thread Marc-André Lureau
numbering for example. Luckily this is a place where changes are unlikely. But please don't let us add new ones. -- Marc-André Lureau

Re: [Qemu-devel] [PATCH 07/12] block: save the associated child in BlockDriverState

2013-06-21 Thread Marc-André Lureau
in readonly). I wonder what would happen if spicebd image would be something else than raw/iso, I suppose there would be more BlockDriverStates to handle the various format. -- Marc-André Lureau

[Qemu-devel] [PATCH 00/13] Spice block device, ready-to-go patches

2013-11-29 Thread Marc-André Lureau
-André Lureau (13): coroutine: remove qemu_co_queue_wait_insert_head vscclient: do not add a socket watch if there is not data to send spice-char: remove unused field qmp_change_blockdev() remove unused has_format include: add missing config-host.h include char: add qemu_chr_fe_event

[Qemu-devel] [PATCH 01/13] coroutine: remove qemu_co_queue_wait_insert_head

2013-11-29 Thread Marc-André Lureau
qemu_co_queue_wait_insert_head() is unused in qemu code base now. Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- include/block/coroutine.h | 6 -- qemu-coroutine-lock.c | 8 2 files changed, 14 deletions(-) diff --git a/include/block/coroutine.h b/include/block

[Qemu-devel] [PATCH 08/13] Split nbd block client code

2013-11-29 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block/Makefile.objs | 2 +- block/nbd-client.c | 372 +++ block/nbd-client.h | 51 +++ block/nbd.c | 373

[Qemu-devel] [PATCH 12/13] nbd: finish any pending coroutine

2013-11-29 Thread Marc-André Lureau
Make sure all pending coroutines are finished when closing the session. Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- block/nbd-client.c | 22 +- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/block/nbd-client.c b/block/nbd-client.c index

[Qemu-devel] [PATCH 09/13] nbd: don't change socket block during negotiate

2013-11-29 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com The caller might handle non-blocking using coroutine. Leave the choice to the caller to use a blocking or non-blocking negotiate. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- nbd.c | 1 - 1 file changed, 1 deletion(-) diff

[Qemu-devel] [PATCH 04/13] qmp_change_blockdev() remove unused has_format

2013-11-29 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- blockdev.c| 2 +- include/sysemu/blockdev.h | 2 +- qmp.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/blockdev.c b

[Qemu-devel] [PATCH 13/13] nbd: avoid uninitialized warnings

2013-11-29 Thread Marc-André Lureau
:1519) ==15815==by 0x1AD804: bdrv_delete (block.c:1772) ==15815==by 0x1B4136: bdrv_unref (block.c:4476) ==15815==by 0x1ACCE0: bdrv_close (block.c:1541) ==15815== Address 0x7feffef98 is on thread 1's stack Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- block/nbd-client.c

[Qemu-devel] [PATCH 11/13] nbd: make session_close() idempotent

2013-11-29 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block/nbd-client.c | 5 + 1 file changed, 5 insertions(+) diff --git a/block/nbd-client.c b/block/nbd-client.c index e29227b..c0ad2c2 100644 --- a/block/nbd-client.c +++ b

[Qemu-devel] [PATCH 06/13] char: add qemu_chr_fe_event()

2013-11-29 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Teach the chardev frontend to send event. This is used by the Spice port chardev currently. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- include/sysemu/char.h | 10 ++ qemu-char.c | 7 +++ 2 files

[Qemu-devel] [PATCH 07/13] spice-char: implement chardev port event

2013-11-29 Thread Marc-André Lureau
Wire up chardev fe_event to Spice port. Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- spice-qemu-char.c | 10 ++ 1 file changed, 10 insertions(+) diff --git a/spice-qemu-char.c b/spice-qemu-char.c index e074d9e..16439c5 100644 --- a/spice-qemu-char.c +++ b/spice-qemu

[Qemu-devel] [PATCH 03/13] spice-char: remove unused field

2013-11-29 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- spice-qemu-char.c | 1 - 1 file changed, 1 deletion(-) diff --git a/spice-qemu-char.c b/spice-qemu-char.c index 6d147a7..e074d9e 100644 --- a/spice-qemu-char.c +++ b/spice-qemu

[Qemu-devel] [PATCH 10/13] nbd: pass export name as init argument

2013-11-29 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com There is no need to keep the export name around, and it seems a better fit as an argument in the init() call. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block/nbd-client.c | 10 -- block/nbd-client.h | 5

[Qemu-devel] [PATCH 02/13] vscclient: do not add a socket watch if there is not data to send

2013-11-29 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Fixes the following error: ** (process:780): CRITICAL **: do_socket_send: assertion `socket_to_send-len != 0' failed Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- libcacard/vscclient.c | 10 ++ 1 file changed, 6

Re: [Qemu-devel] [PATCH 09/13] nbd: don't change socket block during negotiate

2013-12-01 Thread Marc-André Lureau
- Original Message - Il 30/11/2013 16:49, Marc-André Lureau ha scritto: So you suggest this block/unblock: (I haven't reviewed all callers of unix_connect_opts(), I am not sure that's what you meant) Other option would be to move the nonblock to unix_socket_outgoing. diff

[Qemu-devel] [PATCHv2 00/14] Spice block device, ready-to-go patches

2013-12-01 Thread Marc-André Lureau
: - should address Paolo comments - added a patch to remove unused CoQueue member Marc-André Lureau (14): coroutine: remove qemu_co_queue_wait_insert_head vscclient: do not add a socket watch if there is not data to send spice-char: remove unused field qmp_change_blockdev() remove unused has_format

[Qemu-devel] [PATCHv2 01/14] coroutine: remove qemu_co_queue_wait_insert_head

2013-12-01 Thread Marc-André Lureau
qemu_co_queue_wait_insert_head() is unused in qemu code base now. Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- include/block/coroutine.h | 6 -- qemu-coroutine-lock.c | 8 2 files changed, 14 deletions(-) diff --git a/include/block/coroutine.h b/include/block

[Qemu-devel] [PATCHv2 02/14] vscclient: do not add a socket watch if there is not data to send

2013-12-01 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Fixes the following error: ** (process:780): CRITICAL **: do_socket_send: assertion `socket_to_send-len != 0' failed Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- libcacard/vscclient.c | 10 ++ 1 file changed, 6

[Qemu-devel] [PATCHv2 03/14] spice-char: remove unused field

2013-12-01 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- spice-qemu-char.c | 1 - 1 file changed, 1 deletion(-) diff --git a/spice-qemu-char.c b/spice-qemu-char.c index 6d147a7..e074d9e 100644 --- a/spice-qemu-char.c +++ b/spice-qemu

[Qemu-devel] [PATCHv2 09/14] nbd: don't change socket block during negotiate

2013-12-01 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com The caller might handle non-blocking using coroutine. Leave the choice to the caller to use a blocking or non-blocking negotiate. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block/nbd-client.c | 1 + nbd.c | 2

[Qemu-devel] [PATCHv2 12/14] nbd: finish any pending coroutine

2013-12-01 Thread Marc-André Lureau
Make sure all pending coroutines are finished when closing the session. Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- block/nbd-client.c | 21 - 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/block/nbd-client.c b/block/nbd-client.c index

[Qemu-devel] [PATCHv2 10/14] nbd: pass export name as init argument

2013-12-01 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com There is no need to keep the export name around, and it seems a better fit as an argument in the init() call. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block/nbd-client.c | 9 - block/nbd-client.h | 5

[Qemu-devel] [PATCHv2 08/14] Split nbd block client code

2013-12-01 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block/Makefile.objs | 2 +- block/nbd-client.c | 372 +++ block/nbd-client.h | 51 +++ block/nbd.c | 373

[Qemu-devel] [PATCHv2 05/14] include: add missing config-host.h include

2013-12-01 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- include/ui/qemu-spice.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/ui/qemu-spice.h b/include/ui/qemu-spice.h index 86c75c7..a93b4b2 100644 --- a/include/ui/qemu

[Qemu-devel] [PATCHv2 11/14] nbd: make nbd_client_session_close() idempotent

2013-12-01 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- block/nbd-client.c | 5 + 1 file changed, 5 insertions(+) diff --git a/block/nbd-client.c b/block/nbd-client.c index 3dfae1d..9156093 100644 --- a/block/nbd-client.c +++ b

[Qemu-devel] [PATCHv2 13/14] nbd: avoid uninitialized warnings

2013-12-01 Thread Marc-André Lureau
:1519) ==15815==by 0x1AD804: bdrv_delete (block.c:1772) ==15815==by 0x1B4136: bdrv_unref (block.c:4476) ==15815==by 0x1ACCE0: bdrv_close (block.c:1541) ==15815== Address 0x7feffef98 is on thread 1's stack Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- block/nbd-client.c

[Qemu-devel] [PATCHv2 04/14] qmp_change_blockdev() remove unused has_format

2013-12-01 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- blockdev.c| 2 +- include/sysemu/blockdev.h | 2 +- qmp.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/blockdev.c b

[Qemu-devel] [PATCHv2 14/14] coroutine: remove unused CoQueue AioContext

2013-12-01 Thread Marc-André Lureau
The AioContext ctx field is apparently unused in qemu codebase since 02ffb504485. Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com --- include/block/coroutine.h | 1 - 1 file changed, 1 deletion(-) diff --git a/include/block/coroutine.h b/include/block/coroutine.h index b122c0c

[Qemu-devel] [PATCHv2 06/14] char: add qemu_chr_fe_event()

2013-12-01 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com Teach the chardev frontend to send event. This is used by the Spice port chardev currently. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- include/sysemu/char.h | 10 ++ qemu-char.c | 7 +++ 2 files

[Qemu-devel] [PATCH] vnc/spice: fix never and now expire_time

2011-01-06 Thread Marc-André Lureau
From: Marc-André Lureau marcandre.lur...@redhat.com --- monitor.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/monitor.c b/monitor.c index f258000..038d532 100644 --- a/monitor.c +++ b/monitor.c @@ -1136,9 +1136,9 @@ static int expire_password(Monitor *mon, const

Re: [Qemu-devel] [PATCH v2 0/4] GTK-DOC build integration (v2)

2011-12-14 Thread Marc-André Lureau
an upstream compromise possible. Can you point out a discussion/bug, What is the underscode requirements? thanks -- Marc-André Lureau

[Qemu-devel] [PATCH 1/2] hda: do not mix output and input streams, RHBZ #740493

2011-10-17 Thread Marc-André Lureau
Windows 7 may use the same stream number for input and output. That will result in lot of garbage on playback. The hardcoded value of 4 needs to be in sync with GCAP streams description and IN/OUT registers. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- hw/intel-hda.c |9

[Qemu-devel] [PATCH 2/2] hda: do not mix output and input stream states, RHBZ #740493

2011-10-17 Thread Marc-André Lureau
Windows 7 may use the same stream number for input and output. Current code will confuse streams. Changes since v1: - keep running_compat[] for migration version 1 - add running_real[] for migration version 2 Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- hw/hda-audio.c | 26

[Qemu-devel] [PATCH 1/2] hda: do not mix output and input streams, RHBZ #740493

2011-10-25 Thread Marc-André Lureau
Windows 7 may use the same stream number for input and output. That will result in lot of garbage on playback. The hardcoded value of 4 needs to be in sync with GCAP streams description and IN/OUT registers. Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- hw/intel-hda.c |9

[Qemu-devel] [PATCH 2/2] hda: do not mix output and input stream states, RHBZ #740493

2011-10-25 Thread Marc-André Lureau
Windows 7 may use the same stream number for input and output. Current code will confuse streams. Changes since v1: - keep running_compat[] for migration version 1 - add running_real[] for migration version 2 Signed-off-by: Marc-André Lureau marcandre.lur...@redhat.com --- hw/hda-audio.c | 26

[Qemu-devel] [PATCH 01/11] audio: add VOICE_VOLUME ctl

2011-09-21 Thread Marc-André Lureau
--- audio/audio.c | 12 audio/audio_int.h |1 + 2 files changed, 13 insertions(+), 0 deletions(-) diff --git a/audio/audio.c b/audio/audio.c index 5649075..c759c1f 100644 --- a/audio/audio.c +++ b/audio/audio.c @@ -2050,17 +2050,29 @@ void AUD_del_capture (CaptureVoiceOut

[Qemu-devel] [PATCH 00/11] RFC: apply volume on client stream

2011-09-21 Thread Marc-André Lureau
volume control for a while, but qemu part is the missing bit. Marc-André Lureau (11): audio: add VOICE_VOLUME ctl audio: don't apply volume effect if backend has VOICE_VOLUME_CAP audio: use a nominal volume of 1^32-1 hw/ac97: remove USE_MIXER code hw/ac97: the volume mask was not always

[Qemu-devel] [PATCH 08/11] RFC: use full PulseAudio API, largely adapted from pa_simple*

2011-09-21 Thread Marc-André Lureau
Unfortunately, pa_simple is a very limited API which doesn't let us retrieve the associated pa_stream. It is needed to control the volume of the stream. --- audio/paaudio.c | 356 +-- 1 files changed, 318 insertions(+), 38 deletions(-) diff

[Qemu-devel] [PATCH 04/11] hw/ac97: remove USE_MIXER code

2011-09-21 Thread Marc-André Lureau
It doesn't compile. The interesting bits for volume control are going to be rewritten. --- hw/ac97.c | 121 - 1 files changed, 0 insertions(+), 121 deletions(-) diff --git a/hw/ac97.c b/hw/ac97.c index 541d9a4..4d4a658 100644 ---

[Qemu-devel] [PATCH 11/11] RFC: make mixemu mandatory

2011-09-21 Thread Marc-André Lureau
- we need the QEMU_HDA_AMP_CAPS for Spice to handle the volume of HDA - without MIXEMU, volume control on the guest just feels wrong because it has no effect (when it is not applied by the guest) - after all, it's the role of qemu to emulate devices, and volume effect shouldn't be excluded

[Qemu-devel] [PATCH 03/11] audio: use a nominal volume of 1^32-1

2011-09-21 Thread Marc-André Lureau
So we can easily fit it into smaller int. We can just 16 to fit it into a 16bits volume range for example. --- audio/audio.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/audio/audio.c b/audio/audio.c index f830bb2..33b6c23 100644 --- a/audio/audio.c +++

[Qemu-devel] [PATCH 05/11] hw/ac97: the volume mask was not always 0x1f

2011-09-21 Thread Marc-André Lureau
It's a case by case, which will be added appropriately. --- hw/ac97.c |1 - 1 files changed, 0 insertions(+), 1 deletions(-) diff --git a/hw/ac97.c b/hw/ac97.c index 4d4a658..ba94835 100644 --- a/hw/ac97.c +++ b/hw/ac97.c @@ -114,7 +114,6 @@ enum { #define EACS_VRA 1 #define EACS_VRM 8

[Qemu-devel] [PATCH 02/11] audio: don't apply volume effect if backend has VOICE_VOLUME_CAP

2011-09-21 Thread Marc-André Lureau
--- audio/audio.c |9 +++-- audio/audio_int.h |5 + audio/audio_template.h |2 ++ 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/audio/audio.c b/audio/audio.c index c759c1f..f830bb2 100644 --- a/audio/audio.c +++ b/audio/audio.c @@ -954,7 +954,9

[Qemu-devel] [PATCH 07/11] audio/spice: add support for volume control

2011-09-21 Thread Marc-André Lureau
--- audio/spiceaudio.c | 43 +++ 1 files changed, 43 insertions(+), 0 deletions(-) diff --git a/audio/spiceaudio.c b/audio/spiceaudio.c index f972110..2df0957 100644 --- a/audio/spiceaudio.c +++ b/audio/spiceaudio.c @@ -202,7 +202,28 @@ static int

[Qemu-devel] [PATCH 09/11] RFC: configure: pa_simple is not needed anymore

2011-09-21 Thread Marc-André Lureau
--- configure |6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/configure b/configure index c3044c7..4278eb1 100755 --- a/configure +++ b/configure @@ -1682,9 +1682,9 @@ for drv in $audio_drv_list; do ;; pa) -audio_drv_probe $drv pulse/simple.h

[Qemu-devel] [PATCH 06/11] hw/ac97: new support for volume control

2011-09-21 Thread Marc-André Lureau
--- hw/ac97.c | 79 + 1 files changed, 79 insertions(+), 0 deletions(-) diff --git a/hw/ac97.c b/hw/ac97.c index ba94835..4a7c4ed 100644 --- a/hw/ac97.c +++ b/hw/ac97.c @@ -431,6 +431,63 @@ static void reset_voices (AC97LinkState *s,

[Qemu-devel] [PATCH 10/11] RFC: allow controlling volume with PulseAudio backend

2011-09-21 Thread Marc-André Lureau
--- audio/paaudio.c | 96 --- 1 files changed, 91 insertions(+), 5 deletions(-) diff --git a/audio/paaudio.c b/audio/paaudio.c index beed434..7ddc16d 100644 --- a/audio/paaudio.c +++ b/audio/paaudio.c @@ -664,15 +664,100 @@ static void

Re: [Qemu-devel] [PATCH 04/11] hw/ac97: remove USE_MIXER code

2011-09-27 Thread Marc-André Lureau
the patches? You should use git am instead of git apply perhaps regards -- Marc-André Lureau

[Qemu-devel] [PATCH 0/2] HDA fixes for Windows 7

2011-10-04 Thread Marc-André Lureau
number for input and output stream distinctively to avoid conflict, and it seems to be in accordance to the spec. Marc-André Lureau (2): hda: do not mix output and input streams, RHBZ #740493 hda: do not mix output and input stream states, RHBZ #740493 hw/hda-audio.c | 15

[Qemu-devel] [PATCH 1/2] hda: do not mix output and input streams, RHBZ #740493

2011-10-04 Thread Marc-André Lureau
Windows 7 may use the same stream number for input and output. That will result in lot of garbage on playback. The hardcoded value of 4 needs to be in sync with GCAP streams description and IN/OUT registers. --- hw/intel-hda.c |9 + 1 files changed, 5 insertions(+), 4 deletions(-)

[Qemu-devel] [PATCH 2/2] hda: do not mix output and input stream states, RHBZ #740493

2011-10-04 Thread Marc-André Lureau
Windows 7 may use the same stream number for input and output. Current code will confuse streams. NB: I wonder if this patch breaks migration code because of this change: -VMSTATE_BOOL_ARRAY(running, HDAAudioState, 16), +VMSTATE_BOOL_ARRAY(running, HDAAudioState, 2 * 16), ---

Re: [Qemu-devel] [PATCH 2/2] hda: do not mix output and input stream states, RHBZ #740493

2011-10-04 Thread Marc-André Lureau
Hi On Tue, Oct 4, 2011 at 7:21 PM, Juan Quintela quint...@redhat.com wrote: Marc-André Lureau marcandre.lur...@gmail.com wrote: Windows 7 may use the same stream number for input and output. Current code will confuse streams. NB: I wonder if this patch breaks migration code because

Re: [Qemu-devel] [PATCH 07/11] audio/spice: add support for volume control

2011-10-13 Thread Marc-André Lureau
,      .voice_size_out = sizeof (SpiceVoiceOut),      .voice_size_in  = sizeof (SpiceVoiceIn), +    .ctl_caps       = VOICE_VOLUME_CAP This should be #ifdef'ed too I guess? Agreed, to fallback on mixemu volume in that case. -- Marc-André Lureau

[Qemu-devel] [PATCH 02/11] audio: don't apply volume effect if backend has VOICE_VOLUME_CAP

2011-10-13 Thread Marc-André Lureau
--- audio/audio.c |9 +++-- audio/audio_int.h |5 + audio/audio_template.h |2 ++ 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/audio/audio.c b/audio/audio.c index c759c1f..f830bb2 100644 --- a/audio/audio.c +++ b/audio/audio.c @@ -954,7 +954,9

[Qemu-devel] [PATCH 04/11] hw/ac97: remove USE_MIXER code

2011-10-13 Thread Marc-André Lureau
It doesn't compile. The interesting bits for volume control are going to be rewritten. --- hw/ac97.c | 121 - 1 files changed, 0 insertions(+), 121 deletions(-) diff --git a/hw/ac97.c b/hw/ac97.c index 541d9a4..4d4a658 100644 ---

[Qemu-devel] [PATCH 06/11] hw/ac97: new support for volume control

2011-10-13 Thread Marc-André Lureau
--- hw/ac97.c | 79 + 1 files changed, 79 insertions(+), 0 deletions(-) diff --git a/hw/ac97.c b/hw/ac97.c index ba94835..4a7c4ed 100644 --- a/hw/ac97.c +++ b/hw/ac97.c @@ -431,6 +431,63 @@ static void reset_voices (AC97LinkState *s,

  1   2   3   4   5   6   7   8   9   10   >