[Spice-devel] [PATCH spice] Call migrate_end_complete() after falling back to switch-host
Christophe Fergeau
cfergeau at redhat.com
Thu Jul 28 09:52:45 UTC 2016
Hey,
Not overly familiar with the migration code (guess I should experiment
more with it and try to write some documentation...), but this seems to
make sense..
Acked-by: Christophe Fergeau <cfergeau at redhat.com>
Can you backport it to the 0.12 branch, or do you prefer that I do it?
Christophe
On Wed, Jul 20, 2016 at 05:16:31PM +0400, marcandre.lureau at redhat.com wrote:
> From: Marc-André Lureau <marcandre.lureau at redhat.com>
>
> Eventually, during a seamless migration, qemu may finish to migrate
> before the spice client even finished to connect all channels to
> destination and informed the server. In this case,
> main_channel_client_migrate_src_complete() will fall back to
> switch-host method, and reds_mig_fill_wait_disconnect() is called to
> complete the migration (disconnecting all channels).
>
> reds_mig_cleanup() is called when all channels are disconnected, but
> reds->mig_wait_connect is still TRUE, and it will call
> migrate_connect_complete() instead of the expected
> migrate_end_complete(). Setting reds->mig_wait_connect to FALSE when
> reds_mig_fill_wait_disconnect() solves the issue.
>
> Fixes:
> https://bugzilla.redhat.com/show_bug.cgi?id=1352836
>
> Signed-off-by: Marc-André Lureau <marcandre.lureau at redhat.com>
> ---
> server/reds.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/server/reds.c b/server/reds.c
> index 10b943a..969fe62 100644
> --- a/server/reds.c
> +++ b/server/reds.c
> @@ -2982,6 +2982,7 @@ static void reds_mig_fill_wait_disconnect(RedsState *reds)
>
> reds->mig_wait_disconnect_clients = g_list_append(reds->mig_wait_disconnect_clients, client);
> }
> + reds->mig_wait_connect = FALSE;
> reds->mig_wait_disconnect = TRUE;
> reds->core->timer_start(reds->mig_timer, MIGRATE_TIMEOUT);
> }
> --
> 2.9.0
>
> _______________________________________________
> Spice-devel mailing list
> Spice-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/spice-devel
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/spice-devel/attachments/20160728/649e4f8f/attachment.sig>
More information about the Spice-devel
mailing list