qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Anthony Liguori <anthony@codemonkey.ws>
To: Jan Kiszka <jan.kiszka@siemens.com>
Cc: qemu-devel <qemu-devel@nongnu.org>, Juan Quintela <quintela@redhat.com>
Subject: Re: [Qemu-devel] [PATCH] vmstate: Add unmigratable flag
Date: Thu, 09 Jun 2011 15:00:02 -0500	[thread overview]
Message-ID: <4DF12642.1050707@codemonkey.ws> (raw)
In-Reply-To: <4DF0F86E.8040307@siemens.com>

On 06/09/2011 11:44 AM, Jan Kiszka wrote:
> A first step towards getting rid of register_device_unmigratable
> (ivshmem and lacking vmstate support in virtio are blocking this):
>
> Allow to register an unmigratable vmstate via qdev, i.e. tag a device
> declaratively.

I thought part of the problem with this was that for some devices (like 
ivshmem), whether it can be migrated was dynamic.  It depends on 
configuration, state, etc.

Regards,

Anthony Liguori

>
> Signed-off-by: Jan Kiszka<jan.kiszka@siemens.com>
> ---
>   hw/hw.h  |    1 +
>   savevm.c |    1 +
>   2 files changed, 2 insertions(+), 0 deletions(-)
>
> diff --git a/hw/hw.h b/hw/hw.h
> index 56447a7..97c474e 100644
> --- a/hw/hw.h
> +++ b/hw/hw.h
> @@ -333,6 +333,7 @@ struct VMStateDescription {
>       void (*pre_save)(void *opaque);
>       VMStateField *fields;
>       const VMStateSubsection *subsections;
> +    bool unmigratable;
>   };
>
>   extern const VMStateInfo vmstate_info_bool;
> diff --git a/savevm.c b/savevm.c
> index 939845c..98b2422 100644
> --- a/savevm.c
> +++ b/savevm.c
> @@ -1234,6 +1234,7 @@ int vmstate_register_with_alias_id(DeviceState *dev, int instance_id,
>       se->opaque = opaque;
>       se->vmsd = vmsd;
>       se->alias_id = alias_id;
> +    se->no_migrate = vmsd->unmigratable;
>
>       if (dev&&  dev->parent_bus&&  dev->parent_bus->info->get_dev_path) {
>           char *id = dev->parent_bus->info->get_dev_path(dev);

  parent reply	other threads:[~2011-06-09 20:00 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-09 16:44 [Qemu-devel] [PATCH] vmstate: Add unmigratable flag Jan Kiszka
2011-06-09 18:27 ` Markus Armbruster
2011-06-09 20:00 ` Anthony Liguori [this message]
2011-06-09 20:39   ` Jan Kiszka
2011-06-19 20:46     ` Cam Macdonell
2011-06-20  9:05       ` Jan Kiszka
2011-06-21 20:25         ` Cam Macdonell
2011-06-21 20:29           ` Jan Kiszka

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=4DF12642.1050707@codemonkey.ws \
    --to=anthony@codemonkey.ws \
    --cc=jan.kiszka@siemens.com \
    --cc=qemu-devel@nongnu.org \
    --cc=quintela@redhat.com \
    /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).