qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Peter Xu <peterx@redhat.com>
To: Eric Blake <eblake@redhat.com>
Cc: alex.williamson@redhat.com,
	"Dr. David Alan Gilbert \(git\)" <dgilbert@redhat.com>,
	laine@redhat.com, qemu-devel@nongnu.org
Subject: Re: [PATCH 1/2] migration: Add blocker information
Date: Tue, 2 Feb 2021 10:52:49 -0500	[thread overview]
Message-ID: <20210202155249.GB6468@xz-x1> (raw)
In-Reply-To: <b536c8f1-adca-cdec-3298-26d3c506e96a@redhat.com>

On Tue, Feb 02, 2021 at 08:34:06AM -0600, Eric Blake wrote:
> On 2/2/21 7:55 AM, Dr. David Alan Gilbert (git) wrote:
> > From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
> > 
> > Modify query-migrate so that it has a flag indicating if outbound
> > migration is blocked, and if it is a list of reasons.
> > 
> > Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
> > ---
> >  migration/migration.c | 25 +++++++++++++++++++++++--
> >  migration/savevm.c    | 13 +++++++++++++
> >  migration/savevm.h    |  1 +
> >  qapi/migration.json   |  6 ++++++
> >  4 files changed, 43 insertions(+), 2 deletions(-)
> > 
> 
> > +++ b/qapi/migration.json
> > @@ -224,6 +224,10 @@
> >  #        only returned if VFIO device is present, migration is supported by all
> >  #        VFIO devices and status is 'active' or 'completed' (since 5.2)
> >  #
> > +# @blocked: True if outgoing migration is blocked (since 6.0)
> > +#
> > +# @blocked-reasons: A list of reasons an outgoing migration is blocked (since 6.0)
> 
> A bit of redundancy here; the presence of blocked-reasons is sufficient
> to tell if migration is blocked, without needing a bool.  But having the
> bool is more type-friendly for machines, so I don't mind having both.

Agreed.

Also I'd also think we can directly export the device list to JSON then we can
have {"blockers": { "devices": {...}, "other": {...}}} so upper layer can do
more things like "would you want to unplug the device XXX to make it
migratable?" instead of parsing the error message first.

But non of the above is a big deal, I think:

Reviewed-by: Peter Xu <peterx@redhat.com>

-- 
Peter Xu



  reply	other threads:[~2021-02-02 16:07 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-02 13:55 [PATCH 0/2] migration blocker information Dr. David Alan Gilbert (git)
2021-02-02 13:55 ` [PATCH 1/2] migration: Add " Dr. David Alan Gilbert (git)
2021-02-02 14:34   ` Eric Blake
2021-02-02 15:52     ` Peter Xu [this message]
2021-02-02 13:55 ` [PATCH 2/2] migration: Display the migration blockers Dr. David Alan Gilbert (git)
2021-02-02 14:38   ` Eric Blake
2021-02-02 15:53   ` Peter Xu
2021-02-04 15:11 ` [PATCH 0/2] migration blocker information Dr. David Alan Gilbert

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210202155249.GB6468@xz-x1 \
    --to=peterx@redhat.com \
    --cc=alex.williamson@redhat.com \
    --cc=dgilbert@redhat.com \
    --cc=eblake@redhat.com \
    --cc=laine@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).