qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 24/29] migration, vl: start migration via qmp_migrate_incomin


From: Dr. David Alan Gilbert
Subject: Re: [PATCH 24/29] migration, vl: start migration via qmp_migrate_incoming
Date: Wed, 2 Dec 2020 15:08:46 +0000
User-agent: Mutt/1.14.6 (2020-07-11)

* Paolo Bonzini (pbonzini@redhat.com) wrote:
> On 02/12/20 14:10, Dr. David Alan Gilbert wrote:
> > I'm more worried about how this stops a repeated 'migrate incoming'
> > or a 'migrate_incoming' that's issued following a qemu that's been
> > started with -incoming tcp:... but which a socket hasn't yet connected
> > to.
> 
> Good question, fortunately it is simply handled answer:
> 
> void qmp_migrate_incoming(const char *uri, Error **errp)
> {
>     Error *local_err = NULL;
>     static bool once = true;
> 
>     if (!once) {
>         error_setg(errp, "The incoming migration has already been started");
>         return;
>     }
>     if (!runstate_check(RUN_STATE_INMIGRATE)) {
>         error_setg(errp, "'-incoming' was not specified on the command
> line");
>         return;
>     }
> 
>     qemu_start_incoming_migration(uri, &local_err);
> 
>     if (local_err) {
>         error_propagate(errp, local_err);
>         return;
>     }
> 
>     once = false;
> }
> 
> This patch can simplify things because every incoming migrations (no matter
> if '-incoming defer' or '-incoming tcp:...') goes through the
> qmp_migrate_incoming function above.

Yeh I think that's OK.

Dave

> Paolo
> 
-- 
Dr. David Alan Gilbert / dgilbert@redhat.com / Manchester, UK




reply via email to

[Prev in Thread] Current Thread [Next in Thread]