Re: [Qemu-devel] [PATCH] qxl: use correct rom size for revision < 4

2012-12-13 Thread Yonit Halperin
On 12/13/2012 05:40 AM, Alon Levy wrote: On 12/06/12 16:41, Alon Levy wrote: RHBZ 869981 Before this patch revision < 4 (4 is the default) would result in a wrong qxl_rom size of 16384 instead of 8192 when building with spice-protocol-0.12, due to the addition of fields in the rom for client ca

[Qemu-devel] [PATCH] qxl: reload memslots after migration, when qxl is in UNDEFINED mode

2012-11-28 Thread Yonit Halperin
The devram memslot stays active when qxl enters UNDEFINED mode (i.e, no primary surface). If migration has occurred while the device is in UNDEFINED stae, the memslots have to be reloaded at the destination. Fixes rhbz#874574 Signed-off-by: Yonit Halperin --- hw/qxl.c | 1 + 1 file changed, 1

Re: [Qemu-devel] [PATCH] spice: increase the verbosity of spice section in "qemu --help"

2012-08-25 Thread Yonit Halperin
On 08/21/2012 03:31 PM, Eric Blake wrote: On 08/21/2012 04:54 AM, Yonit Halperin wrote: Added all spice options to the help string. This can be used by libvirt to determine which spice related features are supported by qemu. For older released, this is true; but for future versions of qemu

[Qemu-devel] [PATCH] spice: increase the verbosity of spice section in "qemu --help"

2012-08-21 Thread Yonit Halperin
Added all spice options to the help string. This can be used by libvirt to determine which spice related features are supported by qemu. Signed-off-by: Yonit Halperin --- qemu-options.hx | 18 +- 1 files changed, 17 insertions(+), 1 deletions(-) diff --git a/qemu-options.hx b

[Qemu-devel] [PATCH v3 5/5] spice: adding seamless-migration option to the command line

2012-08-21 Thread Yonit Halperin
its old migration method, which can result in data loss. Signed-off-by: Yonit Halperin --- qemu-config.c |3 +++ qemu-options.hx |3 +++ ui/spice-core.c |7 +++ 3 files changed, 13 insertions(+), 0 deletions(-) diff --git a/qemu-config.c b/qemu-config.c index 5c3296b..b7bb28f

[Qemu-devel] [PATCH v3 0/5] add support for spice migration v3

2012-08-21 Thread Yonit Halperin
, Yonit. Yonit Halperin (5): spice: notify spice server on vm start/stop spice: notify on vm state change only via spice_server_vm_start/stop spice migration: add QEVENT_SPICE_MIGRATE_COMPLETED spice: add 'migrated' flag to spice info spice: adding seamless-migration option to t

[Qemu-devel] [PATCH v3 3/5] spice migration: add QEVENT_SPICE_MIGRATE_COMPLETED

2012-08-21 Thread Yonit Halperin
, without suffering from data loss and inconsistencies. In order to allow this data transfer, we add QEVENT for signaling libvirt that spice migration has completed, and libvirt needs to wait for this event before quitting the src process. Signed-off-by: Yonit Halperin --- monitor.c |1

[Qemu-devel] [PATCH v3 1/5] spice: notify spice server on vm start/stop

2012-08-21 Thread Yonit Halperin
: Yonit Halperin --- ui/spice-core.c | 14 ++ 1 files changed, 14 insertions(+), 0 deletions(-) diff --git a/ui/spice-core.c b/ui/spice-core.c index 4fc48f8..32de1f1 100644 --- a/ui/spice-core.c +++ b/ui/spice-core.c @@ -545,6 +545,18 @@ static int add_channel(const char *name, const char

[Qemu-devel] [PATCH v3 2/5] spice: notify on vm state change only via spice_server_vm_start/stop

2012-08-21 Thread Yonit Halperin
QXLWorker->start/stop are deprecated since spice-server 0.11.2 Signed-off-by: Yonit Halperin --- hw/qxl.c |7 --- ui/spice-core.c|4 ui/spice-display.c | 32 ++-- ui/spice-display.h |9 +++-- 4 files changed, 45 inserti

[Qemu-devel] [PATCH v3 4/5] spice: add 'migrated' flag to spice info

2012-08-21 Thread Yonit Halperin
d check if its migration has completed. Signed-off-by: Yonit Halperin --- hmp.c|2 ++ qapi-schema.json |5 - ui/spice-core.c |4 3 files changed, 10 insertions(+), 1 deletions(-) diff --git a/hmp.c b/hmp.c index a9d5675..62f4dee 100644 --- a/hmp.c +++ b/hmp.c

Re: [Qemu-devel] [PATCH v2 2/5] spice: notify on vm state change only via spice_server_vm_start/stop

2012-08-21 Thread Yonit Halperin
Hi, On 08/21/2012 09:58 AM, Gerd Hoffmann wrote: Hi, +#if SPICE_SERVER_VERSION>= 0x000b02 /* 0.11.2 */ +static void display_start(void) +{ +DisplayListItem *item; + +QLIST_FOREACH(item,&display_list, link) { +item->display->running = true; +} +} I think we should simply

[Qemu-devel] [PATCH v2 5/5] spice: adding seamless-migration option to the command line

2012-08-20 Thread Yonit Halperin
its old migration method, which can result in data loss. Signed-off-by: Yonit Halperin --- qemu-config.c |3 +++ qemu-options.hx |3 +++ ui/spice-core.c |7 +++ 3 files changed, 13 insertions(+), 0 deletions(-) diff --git a/qemu-config.c b/qemu-config.c index 5c3296b..b7bb28f

[Qemu-devel] [PATCH v2 0/5] add support for spice migration v2

2012-08-20 Thread Yonit Halperin
://cgit.freedesktop.org/~yhalperi/spice-common/log/ spice: http://cgit.freedesktop.org/~yhalperi/spice/log/?h=seamless-migration.v1 spicei-gtk: http://cgit.freedesktop.org/~yhalperi/spice-gtk/log/ Regards, Yonit. Yonit Halperin (5): spice: notify spice server on vm start/stop spice: notify on vm state

[Qemu-devel] [PATCH v2 4/5] spice: add 'migrated' flag to spice info

2012-08-20 Thread Yonit Halperin
d check if its migration has completed. Signed-off-by: Yonit Halperin --- hmp.c|2 ++ qapi-schema.json |5 - ui/spice-core.c |4 3 files changed, 10 insertions(+), 1 deletions(-) diff --git a/hmp.c b/hmp.c index a9d5675..62f4dee 100644 --- a/hmp.c +++ b/hmp.c

[Qemu-devel] [PATCH v2 2/5] spice: notify on vm state change only via spice_server_vm_start/stop

2012-08-20 Thread Yonit Halperin
QXLWorker->start/stop are deprecated since spice-server 0.11.2 Signed-off-by: Yonit Halperin --- ui/spice-core.c| 44 ui/spice-display.c |6 ++ ui/spice-display.h |2 ++ 3 files changed, 52 insertions(+), 0 deletions(-) diff --

[Qemu-devel] [PATCH v2 1/5] spice: notify spice server on vm start/stop

2012-08-20 Thread Yonit Halperin
: Yonit Halperin --- ui/spice-core.c | 14 ++ 1 files changed, 14 insertions(+), 0 deletions(-) diff --git a/ui/spice-core.c b/ui/spice-core.c index 4fc48f8..32de1f1 100644 --- a/ui/spice-core.c +++ b/ui/spice-core.c @@ -545,6 +545,18 @@ static int add_channel(const char *name, const char

[Qemu-devel] [PATCH v2 3/5] spice migration: add QEVENT_SPICE_MIGRATE_COMPLETED

2012-08-20 Thread Yonit Halperin
, without suffering from data loss and inconsistencies. In order to allow this data transfer, we add QEVENT for signaling libvirt that spice migration has completed, and libvirt needs to wait for this event before quitting the src process. Signed-off-by: Yonit Halperin --- monitor.c |1

Re: [Qemu-devel] [PATCH 1/4] spice: notify spice server on vm start/stop

2012-08-16 Thread Yonit Halperin
On 08/16/2012 12:42 PM, Gerd Hoffmann wrote: On 08/16/12 10:23, Yonit Halperin wrote: Spice server needs to know about the vm state in order to prevent attempts to write to devices when they are stopped, mainly during the non-live stage of migration. Why this new hook? qemu already notifies

[Qemu-devel] [PATCH 2/4] spice migration: add QEVENT_SPICE_MIGRATE_COMPLETED

2012-08-16 Thread Yonit Halperin
, without suffering from data loss and inconsistencies. In order to allow this data transfer, we add QEVENT for signaling libvirt that spice migration has completed, and libvirt needs to wait for this event before quitting the src process. Signed-off-by: Yonit Halperin --- monitor.c |1

[Qemu-devel] [PATCH 3/4] spice: add 'migrated' flag to spice info

2012-08-16 Thread Yonit Halperin
d check if its migration has completed. Signed-off-by: Yonit Halperin --- hmp.c|2 ++ qapi-schema.json |5 - ui/spice-core.c |4 3 files changed, 10 insertions(+), 1 deletions(-) diff --git a/hmp.c b/hmp.c index a9d5675..62f4dee 100644 --- a/hmp.c +++ b/hmp.c

[Qemu-devel] [PATCH 4/4] spice: adding seamless-migration option to the command line

2012-08-16 Thread Yonit Halperin
its old migration method, which can result in data loss. Signed-off-by: Yonit Halperin --- qemu-config.c |3 +++ qemu-options.hx |3 +++ ui/spice-core.c |7 +++ 3 files changed, 13 insertions(+), 0 deletions(-) diff --git a/qemu-config.c b/qemu-config.c index 5c3296b..b7bb28f

[Qemu-devel] [PATCH 1/4] spice: notify spice server on vm start/stop

2012-08-16 Thread Yonit Halperin
: Yonit Halperin --- ui/spice-core.c | 14 ++ 1 files changed, 14 insertions(+), 0 deletions(-) diff --git a/ui/spice-core.c b/ui/spice-core.c index 4fc48f8..32de1f1 100644 --- a/ui/spice-core.c +++ b/ui/spice-core.c @@ -545,6 +545,18 @@ static int add_channel(const char *name, const char

[Qemu-devel] [PATCH 0/4] add support for spice migration

2012-08-16 Thread Yonit Halperin
/log/ Regards, Yonit. Yonit Halperin (4): spice: notify spice server on vm start/stop spice migration: add QEVENT_SPICE_MIGRATE_COMPLETED spice: add 'migrated' flag to spice info spice: adding seamless-migration option to the command line hmp.c|2 ++ monitor.c

Re: [Qemu-devel] [PATCH] spice: abort on invalid streaming cmdline params

2012-08-13 Thread Yonit Halperin
Ack On 08/13/2012 11:32 AM, Christophe Fergeau wrote: When parsing its command line parameters, spice aborts when it finds unexpected values, except for the 'streaming-video' option. This happens because the parsing of the parameters for this option is done using the 'name2enum' helper, which doe

Re: [Qemu-devel] [PATCH v2] qxl: add QXL_IO_MONITORS_CONFIG_ASYNC

2012-07-25 Thread Yonit Halperin
Hi, On 07/25/2012 08:29 PM, Alon Levy wrote: On Wed, Jul 25, 2012 at 12:00:21PM +0300, Yonit Halperin wrote: Hi, I think you should save the monitor configuration as part of the vmstate, and recall spice_qxl_monitors_config_async in qxl_post_load. Good point, will do. Would be nice if I could

Re: [Qemu-devel] [PATCH v2] qxl: add QXL_IO_MONITORS_CONFIG_ASYNC

2012-07-25 Thread Yonit Halperin
Hi, I think you should save the monitor configuration as part of the vmstate, and recall spice_qxl_monitors_config_async in qxl_post_load. Regards, Yonit. On 07/23/2012 07:33 PM, Alon Levy wrote: bumps spice-protocol to 0.12.0 for new IO. revision bumped to 4 for new IO support, enabled for s

Re: [Qemu-devel] [RFC PATCH 0/5] asynchronous migration state change handlers

2012-06-06 Thread Yonit Halperin
On 06/06/2012 12:22 PM, Anthony Liguori wrote: On 06/06/2012 05:10 PM, Yonit Halperin wrote: Hi, I would like to add some more points to Gerd's explanation: On 06/05/2012 04:15 PM, Gerd Hoffmann wrote: Hi, Absolutely not. This is hideously ugly and affects a bunch of code. Spice is

Re: [Qemu-devel] [RFC PATCH 0/5] asynchronous migration state change handlers

2012-06-06 Thread Yonit Halperin
Hi, I would like to add some more points to Gerd's explanation: On 06/05/2012 04:15 PM, Gerd Hoffmann wrote: Hi, Absolutely not. This is hideously ugly and affects a bunch of code. Spice is *not* getting a hook in migration where it gets to add arbitrary amounts of downtime to the migrati

[Qemu-devel] [RFC PATCH 3/5] migration: moving migration completion code to a separated routine

2012-06-04 Thread Yonit Halperin
Preparation for asynchronous migration state change notifiers. In the following patch the migrate_end routine will be used as the completion callback of the "migration end" notifiers list. Signed-off-by: Yonit Halperin --- migration.c | 31 --- migratio

[Qemu-devel] [RFC PATCH 4/5] migration: replace migration state change notifier with async notifiers

2012-06-04 Thread Yonit Halperin
the migration progress, till the async handlers have completed. Note that this patch still leaves the registered notifier handlers synchronous, i.e., they call the notifier completion callback immediately. Signed-off-by: Yonit Halperin --- migration.c | 84

[Qemu-devel] [RFC PATCH 5/5] spice: turn spice "migration end" handler to be async

2012-06-04 Thread Yonit Halperin
Instead of immediatly calling the notifier completion callback, the notification handler assigns a completion callback to spice's migration interface. Spice should call this callback when it completes handling the migration state change. Signed-off-by: Yonit Halperin --- ui/spice-core.c |

[Qemu-devel] [RFC PATCH 2/5] migration: moving migration start code to a separated routine

2012-06-04 Thread Yonit Halperin
Preparation for asynchronous migration state change notifiers. In a following patch the migrate_start routine will be used as the completion callback of the "migration start" notifiers list. Signed-off-by: Yonit Halperin --- migratio

[Qemu-devel] [RFC PATCH 1/5] notifiers: add support for async notifiers handlers

2012-06-04 Thread Yonit Halperin
This patch defines 2 subtypes of notifiers, sync and async. Both of them can be added to a notifiers list. The patch adds optional complete_cb to the notifiers list. complete_cb is called when all the async notifiers have completed. Signed-off-by: Yonit Halperin --- input.c |2

[Qemu-devel] [RFC PATCH 0/5] asynchronous migration state change handlers

2012-06-04 Thread Yonit Halperin
ould also want to migrate data that will allow us to continue the new spice connection from the same point the old one stopped. Without requiring special treatment in the client side. Regards, Yonit. Yonit Halperin (5): notifiers: add support for async notifiers handlers migration: mo

[Qemu-devel] [RFC PATCH 4/4] migration: replace migration state change notifier with async notifiers

2012-05-30 Thread Yonit Halperin
Note that this patch leaves the current notifier handlers synchronous, i.e., they call the notifier completion callback immediately. Signed-off-by: Yonit Halperin --- migration.c | 84 +- migration.h |8 - ui/spice-core.c

[Qemu-devel] [RFC PATCH 3/4] migration: moving migration completion code to a separated routine

2012-05-30 Thread Yonit Halperin
Preparation for asynchronous migration state change notifiers. Signed-off-by: Yonit Halperin --- migration.c | 31 --- migration.h |1 + 2 files changed, 17 insertions(+), 15 deletions(-) diff --git a/migration.c b/migration.c index 91c807d..c86611d 100644

[Qemu-devel] [RFC PATCH 2/4] migration: moving migration start code to a separated routine

2012-05-30 Thread Yonit Halperin
Preparation for asynchronous migration state change notifiers. Signed-off-by: Yonit Halperin --- migration.c | 73 +- migration.h |2 + 2 files changed, 58 insertions(+), 17 deletions(-) diff --git a/migration.c b/migration.c index

[Qemu-devel] [RFC PATCH 1/4] notifiers: add support for async notifiers handlers

2012-05-30 Thread Yonit Halperin
Signed-off-by: Yonit Halperin --- input.c |2 +- migration.c |2 +- notify.c | 79 +++--- notify.h | 55 --- qemu-timer.c |2 +- vl.c |2 +- 6 files changed, 129

[Qemu-devel] [RFC PATCH 0/4] asynchronous migration state change handlers

2012-05-30 Thread Yonit Halperin
to employ vmstate for migrating spice in-flight data, e.g., usb buffers that were sent from the client and reached the server after the vm was stopped. Regards, Yonit. Yonit Halperin (4): notifiers: add support for async notifiers handlers migration: moving migration start code to a separated

[Qemu-devel] [PATCH] monitor: fix client_migrate_info error handling

2012-03-18 Thread Yonit Halperin
Report QERR_INVALID_PARAMETER when port is missing. Otherwise QERR_UNDEFINED_ERROR will occur. rhbz #795652 Signed-off-by: Yonit Halperin --- monitor.c |5 + 1 files changed, 5 insertions(+), 0 deletions(-) diff --git a/monitor.c b/monitor.c index d57e7bf..8f46031 100644 --- a

Re: [Qemu-devel] [Spice-devel] seamless migration with spice

2012-03-12 Thread Yonit Halperin
Hi, On 03/13/2012 08:40 AM, Gerd Hoffmann wrote: On 03/12/12 19:45, Yonit Halperin wrote: Hi, On 03/12/2012 03:50 PM, Gerd Hoffmann wrote: Hi, Can you explain/exemplify, why sending data as a blob (either by (a) or (b)), that is verified only by the two ends that actually use it, is a

Re: [Qemu-devel] [Spice-devel] seamless migration with spice

2012-03-12 Thread Yonit Halperin
Hi, On 03/12/2012 03:50 PM, Gerd Hoffmann wrote: Hi, Can you explain/exemplify, why sending data as a blob (either by (a) or (b)), that is verified only by the two ends that actually use it, is a problem? It tends to be not very robust. Especially when the creating/parsing is done ad-hoc

Re: [Qemu-devel] [Spice-devel] seamless migration with spice

2012-03-12 Thread Yonit Halperin
On 03/12/2012 11:46 AM, Gerd Hoffmann wrote: Hi, The problem with (b) is, that iirc the way b was implemented in the past was still the big blob approach, but then pass the blob through the client, which means an evil client could modify it, causing all sorts of "interesting" behavior inside

Re: [Qemu-devel] seamless migration with spice

2012-03-11 Thread Yonit Halperin
Hi. On 03/11/2012 05:36 PM, Anthony Liguori wrote: On 03/11/2012 10:25 AM, Alon Levy wrote: On Sun, Mar 11, 2012 at 09:18:17AM -0500, Anthony Liguori wrote: On 03/11/2012 08:16 AM, Yonit Halperin wrote: Hi, We would like to implement seamless migration for Spice, i.e., keeping the currently

[Qemu-devel] seamless migration with spice

2012-03-11 Thread Yonit Halperin
Hi, We would like to implement seamless migration for Spice, i.e., keeping the currently opened spice client session valid after migration. Today, the spice client establishes the connection to the destination before migration starts, and when migration completes, the client's session is moved

Re: [Qemu-devel] [PATCH] qxl: don't render stuff when the vm is stopped.

2012-02-15 Thread Yonit Halperin
On 02/15/2012 03:36 PM, Gerd Hoffmann wrote: On 02/15/12 14:22, Yonit Halperin wrote: Hi, On 02/15/2012 03:11 PM, Gerd Hoffmann wrote: This patch fixes the local qxl renderer to not kick spice-server in case the vm is stopped. First it is pointless because we render evevything when the vm is

Re: [Qemu-devel] [PATCH] qxl: don't render stuff when the vm is stopped.

2012-02-15 Thread Yonit Halperin
Hi, On 02/15/2012 03:11 PM, Gerd Hoffmann wrote: This patch fixes the local qxl renderer to not kick spice-server in case the vm is stopped. First it is pointless because we render evevything when the vm is stopped. Thus there is nothing to render anyway because a stopped guest can hardly queue

[Qemu-devel] [PATCH v2 2/2] qxl: make sure primary surface is saved on migration also in compat mode

2012-02-15 Thread Yonit Halperin
RHBZ #790083 Signed-off-by: Yonit Halperin --- hw/qxl.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/hw/qxl.c b/hw/qxl.c index df55de1..10137f9 100644 --- a/hw/qxl.c +++ b/hw/qxl.c @@ -1470,7 +1470,7 @@ static void qxl_dirty_surfaces(PCIQXLDevice *qxl) intptr_t

[Qemu-devel] [PATCH v2 1/2] qxl: set only off-screen surfaces dirty instead of the whole vram

2012-02-15 Thread Yonit Halperin
We used to assure the guest surfaces were saved before migration by setting the whole vram dirty. This patch sets dirty only the areas that are actually used in the vram. Signed-off-by: Yonit Halperin --- hw/qxl.c | 53 - 1 files changed, 44

Re: [Qemu-devel] [PATCH] qxl: make sure primary surface is saved on migration also in compat mode

2012-02-14 Thread Yonit Halperin
On 02/14/2012 11:24 AM, Gerd Hoffmann wrote: Hi, I can do it, by retrieving the surfaces addresses from the tracked guest commands. Exactly. However, if we already do it, it would be even better if we just dirty only the areas that are actually modified by the update_area calls. The prob

Re: [Qemu-devel] [Spice-devel] [PATCH] qxl: make sure primary surface is saved on migration also in compat mode

2012-02-14 Thread Yonit Halperin
On 02/14/2012 11:10 AM, Yonit Halperin wrote: On 02/14/2012 10:35 AM, Gerd Hoffmann wrote: On 02/14/12 09:10, Yonit Halperin wrote: RHBZ #790083 Signed-off-by: Yonit Halperin You are doing two things in one patch: (a) fix the compat mode bug, which also matches the patch description, and (b

Re: [Qemu-devel] [PATCH] qxl: make sure primary surface is saved on migration also in compat mode

2012-02-14 Thread Yonit Halperin
On 02/14/2012 10:35 AM, Gerd Hoffmann wrote: On 02/14/12 09:10, Yonit Halperin wrote: RHBZ #790083 Signed-off-by: Yonit Halperin You are doing two things in one patch: (a) fix the compat mode bug, which also matches the patch description, and (b) skip vram when it is unused (in compat mode

[Qemu-devel] [PATCH] qxl: make sure primary surface is saved on migration also in compat mode

2012-02-14 Thread Yonit Halperin
RHBZ #790083 Signed-off-by: Yonit Halperin --- hw/qxl.c | 17 - 1 files changed, 12 insertions(+), 5 deletions(-) diff --git a/hw/qxl.c b/hw/qxl.c index bc03c1d..a2a3380 100644 --- a/hw/qxl.c +++ b/hw/qxl.c @@ -1478,14 +1478,21 @@ static void qxl_vm_change_state_handler(void

[Qemu-devel] [PATCH] spice: support ipv6 channel address in monitor events and in spice info

2012-02-08 Thread Yonit Halperin
RHBZ #788444 CC: Gerd Hoffmann Signed-off-by: Yonit Halperin --- ui/spice-core.c | 37 - 1 files changed, 32 insertions(+), 5 deletions(-) diff --git a/ui/spice-core.c b/ui/spice-core.c index 5639c6f..60fd6c3 100644 --- a/ui/spice-core.c +++ b/ui/spice

[Qemu-devel] [PATCH] server: support IPV6 addresses in channel events sent to qemu

2012-02-08 Thread Yonit Halperin
RHBZ #788444 CC: Gerd Hoffmann Signed-off-by: Gerd Hoffmann Signed-off-by: Yonit Halperin --- server/reds.c | 21 + server/spice.h |6 ++ 2 files changed, 23 insertions(+), 4 deletions(-) diff --git a/server/reds.c b/server/reds.c index 2492a89..828ba65 100644

Re: [Qemu-devel] [Spice-devel] client_migrate_info - do we need a new command?

2011-12-14 Thread Yonit Halperin
Hi, On 12/13/2011 08:19 PM, Anthony Liguori wrote: In our call today, Avi asked that we evaluate whether the interface for client_migrate_info is the Right Interface before we introduce a new command to work around the fact that async commands are broken. I looked into this today and here's what

Re: [Qemu-devel] [Spice-devel] Possible SPICE/QEMU deadlock on fast client reconnect

2011-10-23 Thread Yonit Halperin
Hi, Sounds like https://bugzilla.redhat.com/show_bug.cgi?id=746950 and https://bugs.freedesktop.org/show_bug.cgi?id=41858 Alon's patch: http://lists.freedesktop.org/archives/spice-devel/2011-September /005369.html Should solve it. Cheers, Yonit. On 10/21/2011 05:26 PM, Daniel P. Berrange wrote

[Qemu-devel] [PATCH] qxl: fix guest cursor tracking

2011-10-18 Thread Yonit Halperin
will prevent access to pci memory that was released. RHBZ: 744518 Signed-off-by: Yonit Halperin --- hw/qxl.c | 16 1 files changed, 12 insertions(+), 4 deletions(-) diff --git a/hw/qxl.c b/hw/qxl.c index 03848ed..c9b60a2 100644 --- a/hw/qxl.c +++ b/hw/qxl.c @@ -238,6 +238,9 @@

Re: [Qemu-devel] [PATCH] qxl: create slots on post_load in any state (fix RHBZ 740547)

2011-10-17 Thread Yonit Halperin
ACK On 10/17/2011 12:24 PM, Alon Levy wrote: If we migrate when the device is not in a native state the guest still believes the slots are created, and will cause operations that reference the slots, causing a "panic: virtual address out of range" on the first of them. Easy to see by migrating in

[Qemu-devel] [PATCH v2 0/2] spice migration interface v2 (RHBZ 737921)

2011-10-17 Thread Yonit Halperin
be called upon migration start/end ** spice_server_start and the migrate_end_complete callback, were added for future use, in case we implement a real seamless spice migration Yonit Halperin (2): spice: turn client_migrate_info to async spice: support the new migration interface (spice 0.

[Qemu-devel] [PATCH v2 1/2] spice: turn client_migrate_info to async

2011-10-17 Thread Yonit Halperin
cb will be called after spice client has been connected to the target (or a timeout). See following patches and spice patches. Signed-off-by: Yonit Halperin --- hmp-commands.hx |3 ++- monitor.c |6 -- qmp-commands.hx |3 ++- ui/qemu-spice.h | 14 +++--- ui/spice

[Qemu-devel] [PATCH v2 2/2] spice: support the new migration interface (spice 0.8.3)

2011-10-17 Thread Yonit Halperin
- call spice_server_migrate_(start|end|connect). - register spice_migrate_connect completion callback Signed-off-by: Yonit Halperin --- ui/spice-core.c | 56 ++- 1 files changed, 55 insertions(+), 1 deletions(-) diff --git a/ui/spice-core.c

Re: [Qemu-devel] [Spice-devel] viewing continuous guest virtual memory as continuous in qemu

2011-10-03 Thread Yonit Halperin
On 10/02/2011 03:24 PM, Alon Levy wrote: Hi, I'm trying to acheive the $subject. Some background: currently spice relies on a preallocated pci bar for both surfaces and for VGA framebuffer + commands. I have been trying to get rid of the surfaces bar. To do that I allocate memory in the gue

Re: [Qemu-devel] [PATCH spice-server 08/13] server: move the linking of channels to a separate routine

2011-09-25 Thread Yonit Halperin
On 09/22/2011 05:01 PM, Alon Levy wrote: On Wed, Sep 21, 2011 at 06:51:18PM +0300, Yonit Halperin wrote: Signed-off-by: Yonit Halperin --- server/reds.c | 68 +++- 1 files changed, 42 insertions(+), 26 deletions(-) diff --git a/server

[Qemu-devel] [PATCH spice-server 03/13] configure: spice-protocol >= 0.8.2 (semi-seamless migration protocol)

2011-09-21 Thread Yonit Halperin
Signed-off-by: Yonit Halperin --- configure.ac |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/configure.ac b/configure.ac index 3a86515..e169f36 100644 --- a/configure.ac +++ b/configure.ac @@ -126,7 +126,7 @@ fi dnl

[Qemu-devel] [PATCH spice-server 02/13] server: handle migration interface addition

2011-09-21 Thread Yonit Halperin
Signed-off-by: Yonit Halperin --- server/reds.c | 29 + server/reds.h |4 2 files changed, 33 insertions(+), 0 deletions(-) diff --git a/server/reds.c b/server/reds.c index 9a983f8..99d52f9 100644 --- a/server/reds.c +++ b/server/reds.c @@ -73,6 +73,7

[Qemu-devel] [PATCH spice-server 10/13] server: call migrate_connect_complete callback when no client is connected

2011-09-21 Thread Yonit Halperin
Signed-off-by: Yonit Halperin --- server/reds.c | 72 ++--- 1 files changed, 43 insertions(+), 29 deletions(-) diff --git a/server/reds.c b/server/reds.c index ca4e1d1..6d2269c 100644 --- a/server/reds.c +++ b/server/reds.c @@ -761,6 +761,7

[Qemu-devel] [PATCH spice-server 06/13] server: send SPICE_MSG_MAIN_MIGRATE_END on spice_server_migrate_end

2011-09-21 Thread Yonit Halperin
Signed-off-by: Yonit Halperin --- server/reds.c | 86 + 1 files changed, 68 insertions(+), 18 deletions(-) diff --git a/server/reds.c b/server/reds.c index 845b0ee..e088b08 100644 --- a/server/reds.c +++ b/server/reds.c @@ -275,6 +275,7

[Qemu-devel] [PATCH spice-server 05/13] spice.proto: add SPICE_MSG_MAIN_MIGRATE_END & SPICE_MSGC_MAIN_MIGRATE_END

2011-09-21 Thread Yonit Halperin
Signed-off-by: Yonit Halperin --- spice.proto |4 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/spice.proto b/spice.proto index d5b954e..235ec95 100644 --- a/spice.proto +++ b/spice.proto @@ -219,6 +219,8 @@ channel MainChannel : BaseChannel { uint8

[Qemu-devel] [PATCH spice-server 12/13] server: fall back to switch host scheme in case semi-seamless connection to target fails

2011-09-21 Thread Yonit Halperin
Signed-off-by: Yonit Halperin --- server/reds.c | 18 +- 1 files changed, 13 insertions(+), 5 deletions(-) diff --git a/server/reds.c b/server/reds.c index 76aa0ed..54c06d1 100644 --- a/server/reds.c +++ b/server/reds.c @@ -283,6 +283,7 @@ typedef struct RedsState { int

[Qemu-devel] [PATCH spice-server 08/13] server: move the linking of channels to a separate routine

2011-09-21 Thread Yonit Halperin
Signed-off-by: Yonit Halperin --- server/reds.c | 68 +++- 1 files changed, 42 insertions(+), 26 deletions(-) diff --git a/server/reds.c b/server/reds.c index bea0eb0..e7388a0 100644 --- a/server/reds.c +++ b/server/reds.c @@ -2612,12

[Qemu-devel] [PATCH spice-server 09/13] server: handling semi-seamless migration in the target side

2011-09-21 Thread Yonit Halperin
(1) not sending anything to the client till we recieve SPICE_MSGC_MIGRATE_END (2) start a new migration (handle client_migrate_info) only after SPICE_MSGC_MIGRATE_END from the previous migration has been received (3) use the correct ticket Signed-off-by: Yonit Halperin --- server/reds.c

[Qemu-devel] [PATCH spice-server 01/13] server/spice.h: semi-seamless migration interface, RHBZ #738266

2011-09-21 Thread Yonit Halperin
_migrate_info command. Signed-off-by: Yonit Halperin --- server/reds.c |9 + server/spice-experimental.h |3 --- server/spice.h | 27 ++- 3 files changed, 35 insertions(+), 4 deletions(-) diff --git a/server/reds.c b/server

[Qemu-devel] [PATCH spice-server 07/13] server: move SPICE_MSG_MAIN_INIT sending code to a separate routine

2011-09-21 Thread Yonit Halperin
Signed-off-by: Yonit Halperin --- server/reds.c | 56 +--- 1 files changed, 33 insertions(+), 23 deletions(-) diff --git a/server/reds.c b/server/reds.c index e088b08..bea0eb0 100644 --- a/server/reds.c +++ b/server/reds.c @@ -2078,6

[Qemu-devel] [PATCH spice-server 00/13] semi-seamless migration v2 (RHBZ #738266, 725009)

2011-09-21 Thread Yonit Halperin
not accept new spice client connections. Thus, we trigger the connection to the target upon client_migrate_info command. Yonit Halperin (13): server/spice.h: semi-seamless migration interface, RHBZ #738266 server: handle migration interface addition configure: spice-protocol >=

[Qemu-devel] [PATCH 1/2] spice: turn client_migrate_info to async

2011-09-21 Thread Yonit Halperin
cb will be called after spice client has been connected to the target (or a timeout). See following patches and spice patches. Signed-off-by: Yonit Halperin --- hmp-commands.hx |3 ++- monitor.c |6 -- qmp-commands.hx |3 ++- ui/qemu-spice.h | 13 +++-- ui/spice

[Qemu-devel] [PATCH spice-server 04/13] server, proto: tell the client to connect to the migration target before migraton starts

2011-09-21 Thread Yonit Halperin
(1) send SPICE_MSG_MAIN_MIGRATE_BEGIN upon spice_server_migrate_connect (2) wait for SPICE_MSGC_MAIN_MIGRATE_(CONNECTED|CONNECT_ERROR), or a timeout, in order to complete client_migrate_info monitor command Signed-off-by: Yonit Halperin --- common/messages.h |2 + server/reds.c

[Qemu-devel] [PATCH spice-server 13/13] Release 0.8.3

2011-09-21 Thread Yonit Halperin
Signed-off-by: Yonit Halperin --- NEWS |7 +++ configure.ac |2 +- server/spice-server.syms |4 server/spice.h |2 +- 4 files changed, 13 insertions(+), 2 deletions(-) diff --git a/NEWS b/NEWS index ee6ceec..18168cb 100644

[Qemu-devel] [PATCH spice-server 11/13] server: turn spice_server_migrate_start into a valid call

2011-09-21 Thread Yonit Halperin
We will add a qemu call to spice_server_migrate_start when migration starts. For now, it does nothing, but we may need this notification in the future. Signed-off-by: Yonit Halperin --- server/reds.c |8 +--- 1 files changed, 1 insertions(+), 7 deletions(-) diff --git a/server/reds.c b

[Qemu-devel] [PATCH spice-protocol] Release 0.8.2

2011-09-21 Thread Yonit Halperin
semi-seamless migration RHBZ 738262 Signed-off-by: Yonit Halperin --- NEWS |4 configure.ac |2 +- spice/enums.h|2 ++ spice/protocol.h |6 +- 4 files changed, 12 insertions(+), 2 deletions(-) diff --git a/NEWS b/NEWS index f238abc..bb11ed2 100644

[Qemu-devel] [PATCH 2/2] spice: support the new migration interface (spice 0.8.3)

2011-09-21 Thread Yonit Halperin
- call spice_server_migrate_(start|end|connect). - register spice_migrate_connect completion callback Signed-off-by: Yonit Halperin --- ui/spice-core.c | 56 ++- 1 files changed, 55 insertions(+), 1 deletions(-) diff --git a/ui/spice-core.c

[Qemu-devel] [PATCH 0/2] spice migration interface (RHBZ 737921)

2011-09-21 Thread Yonit Halperin
we implement a real seamless spice migration Spice server patches will be emailed next. They are for the 0.8 spice branch, but will be ported to upstream soon. Yonit Halperin (2): spice: turn client_migrate_info to async spice: support the new migration interface (spice 0.8.3) hmp-commands

[Qemu-devel] [PATCH] spice: set qxl->ssd.running=true before telling spice to start, RHBZ #733993

2011-09-05 Thread Yonit Halperin
If qxl->ssd.running=true is set after telling spice to start, the spice server thread can call qxl_send_events while qxl->ssd.running is still false. This leads to assert(d->ssd.running). Signed-off-by: Yonit Halperin --- Since it looks like the purpose of the assert in qxl_send

[Qemu-devel] [PATCH v3 1/2] qxl: send interrupt after migration in case ram->int_pending != 0, RHBZ #732949

2011-09-04 Thread Yonit Halperin
ult, the guest driver was stacked or very slow (when the waiting for the interrupt was with timeout). Signed-off-by: Yonit Halperin --- hw/qxl.c | 10 -- 1 files changed, 8 insertions(+), 2 deletions(-) diff --git a/hw/qxl.c b/hw/qxl.c index b34bccf..de65a40 100644 --- a/hw/qxl.c +++ b/

[Qemu-devel] [PATCH v3 2/2] qxl: s/qxl_set_irq/qxl_update_irq/

2011-09-04 Thread Yonit Halperin
Signed-off-by: Yonit Halperin --- hw/qxl.c | 12 ++-- 1 files changed, 6 insertions(+), 6 deletions(-) diff --git a/hw/qxl.c b/hw/qxl.c index de65a40..f00b5d3 100644 --- a/hw/qxl.c +++ b/hw/qxl.c @@ -808,7 +808,7 @@ static void qxl_exit_vga_mode(PCIQXLDevice *d

Re: [Qemu-devel] [Spice-devel] [PATCH] server: don't call reds_stream_free from worker thread context

2011-09-04 Thread Yonit Halperin
On 09/02/2011 06:19 PM, Gerd Hoffmann wrote: reds_stream_free() may call the channel_event callback which is not supposed to be callsed from worker thread context. This patch moves the reds_stream_free call for the display channel from the worker to the dispatcher to fix this issue. [ Note: not

Re: [Qemu-devel] [PATCH v2 1/2] qxl: send interrupt after migration in case ram->int_pending != 0, RHBZ #732949

2011-09-03 Thread Yonit Halperin
On 09/01/2011 10:36 PM, Michael S. Tsirkin wrote: On Wed, Aug 31, 2011 at 03:37:33PM +0300, Yonit Halperin wrote: if qxl_send_events was called from spice server context, and then migration had completed before a call to pipe_read, the target guest qxl driver didn't get the interrupt. Th

[Qemu-devel] [PATCH v2 2/2] qxl: s/qxl_set_irq/qxl_update_irq/

2011-08-31 Thread Yonit Halperin
--- hw/qxl.c | 12 ++-- 1 files changed, 6 insertions(+), 6 deletions(-) diff --git a/hw/qxl.c b/hw/qxl.c index c7edc60..3ddca88 100644 --- a/hw/qxl.c +++ b/hw/qxl.c @@ -808,7 +808,7 @@ static void qxl_exit_vga_mode(PCIQXLDevice *d) qxl_destroy_primary(d, QXL_SYNC); } -static vo

[Qemu-devel] [PATCH v2 1/2] qxl: send interrupt after migration in case ram->int_pending != 0, RHBZ #732949

2011-08-31 Thread Yonit Halperin
if qxl_send_events was called from spice server context, and then migration had completed before a call to pipe_read, the target guest qxl driver didn't get the interrupt. In addition, qxl_send_events ignored further interrupts of the same kind, since ram->int_pending was set. As a result, the gues

Re: [Qemu-devel] [PATCH] qxl: send interrupt after migration in case ram->int_pending != 0, RHBZ #732949

2011-08-31 Thread Yonit Halperin
On 08/31/2011 01:23 PM, Gerd Hoffmann wrote: On 08/31/11 10:20, Yonit Halperin wrote: if qxl_send_events was called from spice server context, and then migration had completed before a call to pipe_read, the target guest qxl driver didn't get the interrupt. In addition, qxl_send_events ig

[Qemu-devel] [PATCH] qxl: send interrupt after migration in case ram->int_pending != 0, RHBZ #732949

2011-08-31 Thread Yonit Halperin
if qxl_send_events was called from spice server context, and then migration had completed before a call to pipe_read, the target guest qxl driver didn't get the interrupt. In addition, qxl_send_events ignored further interrupts of the same kind, since ram->int_pending was set. As a result, the gues

[Qemu-devel] [PATCH] qxl: allowing the command rings to be not empty when spice worker is stopped RHBZ #728984

2011-08-09 Thread Yonit Halperin
same as 8927cfbba232e28304734f7afd463c1b84134031, but for qxl_check_state, that was triggered by qxl_pre_load (which calls qxl_hard_reset, which calls qxl_soft_reset), and caused the migration target to crash. --- hw/qxl.c |8 +++- 1 files changed, 3 insertions(+), 5 deletions(-) diff -

[Qemu-devel] [PATCH] qxl: upon reset, if spice worker is stopped, the command rings can be not empty

2011-07-12 Thread Yonit Halperin
Spice worker does no longer process commands when it is stopped. Otherwise, it might crash during migration when attempting to process commands while the guest is not completely loaded. Cc: Alon Levy --- hw/qxl.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/qxl.

[Qemu-devel] [PATCHv3] qxl: make sure primary surface is saved on migration

2011-07-04 Thread Yonit Halperin
--- hw/qxl.c |9 ++--- 1 files changed, 6 insertions(+), 3 deletions(-) diff --git a/hw/qxl.c b/hw/qxl.c index 2bb36c6..b3a3507 100644 --- a/hw/qxl.c +++ b/hw/qxl.c @@ -1165,11 +1165,14 @@ static void qxl_vm_change_state_handler(void *opaque, int running, int reason) qemu_spice_vm_c

[Qemu-devel] [PATCHv2] qxl: make sure primary surface is saved on migration

2011-07-04 Thread Yonit Halperin
--- hw/qxl.c |9 ++--- 1 files changed, 6 insertions(+), 3 deletions(-) diff --git a/hw/qxl.c b/hw/qxl.c index 2bb36c6..cff95a4 100644 --- a/hw/qxl.c +++ b/hw/qxl.c @@ -1165,11 +1165,14 @@ static void qxl_vm_change_state_handler(void *opaque, int running, int reason) qemu_spice_vm_c

[Qemu-devel] [PATCH] qxl: make sure primary surface is saved on migration

2011-07-04 Thread Yonit Halperin
--- hw/qxl.c |9 ++--- 1 files changed, 6 insertions(+), 3 deletions(-) diff --git a/hw/qxl.c b/hw/qxl.c index 2bb36c6..9fdeffb 100644 --- a/hw/qxl.c +++ b/hw/qxl.c @@ -1165,11 +1165,14 @@ static void qxl_vm_change_state_handler(void *opaque, int running, int reason) qemu_spice_vm_c

Re: [Qemu-devel] [PATCH 2/2] qxl: add QXL_IO_UPDATE_MEM for guest S3&S4 support

2011-06-30 Thread Yonit Halperin
On 06/29/2011 02:38 PM, Alon Levy wrote: On Wed, Jun 29, 2011 at 12:25:00PM +0200, Gerd Hoffmann wrote: On 06/29/11 11:21, Alon Levy wrote: On Wed, Jun 29, 2011 at 11:01:11AM +0200, Gerd Hoffmann wrote: Hi, I think it will receive them after migration, since the command ring was stored.

Re: [Qemu-devel] [PATCH 2/2] qxl: add QXL_IO_UPDATE_MEM for guest S3&S4 support

2011-06-26 Thread Yonit Halperin
Sorry for the late response, wasn't available. I'm afraid that (1) and (2) will indeed wakeup the worker, but will not assure emptying the command ring, as it depends on the client pipe size. - Original Message - From: "Alon Levy" To: "Gerd Hoffmann" Cc: qemu-devel@nongnu.org, yhalp..

Re: [Qemu-devel] [PATCH 2/2] qxl: add QXL_IO_UPDATE_MEM for guest S3&S4 support

2011-06-20 Thread Yonit Halperin
On 06/20/2011 07:32 PM, Alon Levy wrote: On Mon, Jun 20, 2011 at 05:50:32PM +0200, Gerd Hoffmann wrote: On 06/20/11 17:11, Alon Levy wrote: On Mon, Jun 20, 2011 at 04:07:59PM +0200, Gerd Hoffmann wrote: What is the difference to one worker->stop() + worker->start() cycle? ok, stop+start won