All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Andreas Färber" <afaerber@suse.de>
To: Amos Kong <akong@redhat.com>
Cc: aliguori@us.ibm.com, quintela@redhat.com, jasowang@redhat.com,
	qemu-devel@nongnu.org, blauwirbel@gmail.com,
	hpoussin@reactos.org
Subject: Re: [Qemu-devel] [RESEND PATCH] vmstate: fix varrays with uint32_t indexes
Date: Tue, 13 Mar 2012 17:38:52 +0100	[thread overview]
Message-ID: <4F5F781C.4080502@suse.de> (raw)
In-Reply-To: <20120313060536.7941.37036.stgit@dhcp-8-167.nay.redhat.com>

Am 13.03.2012 07:05, schrieb Amos Kong:
> VMSTATE_VARRAY_UINT32() is used in hw/ds1225y.c, and we checked
> VMS_VARRAY_UINT32 bit of field->flags in vmstate_load_state(),
> but we don't check this bit in vmstate_save_state().

So what were the symptoms? Does this need to be backported to stable?

Andreas

> 
> Signed-off-by: Amos Kong <akong@redhat.com>
> ---
>  savevm.c |    2 ++
>  1 files changed, 2 insertions(+), 0 deletions(-)
> 
> diff --git a/savevm.c b/savevm.c
> index 80be1ff..694eaa4 100644
> --- a/savevm.c
> +++ b/savevm.c
> @@ -1486,6 +1486,8 @@ void vmstate_save_state(QEMUFile *f, const VMStateDescription *vmsd,
>                  n_elems = field->num;
>              } else if (field->flags & VMS_VARRAY_INT32) {
>                  n_elems = *(int32_t *)(opaque+field->num_offset);
> +            } else if (field->flags & VMS_VARRAY_UINT32) {
> +                n_elems = *(uint32_t *)(opaque+field->num_offset);
>              } else if (field->flags & VMS_VARRAY_UINT16) {
>                  n_elems = *(uint16_t *)(opaque+field->num_offset);
>              } else if (field->flags & VMS_VARRAY_UINT8) {

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

  parent reply	other threads:[~2012-03-13 16:39 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-13  6:05 [Qemu-devel] [RESEND PATCH] vmstate: fix varrays with uint32_t indexes Amos Kong
2012-03-13 14:49 ` Juan Quintela
2012-03-13 16:38 ` Andreas Färber [this message]
2012-03-13 17:46   ` Juan Quintela
2012-03-14  6:19 ` Hervé Poussineau
2012-03-17 16:20 ` Blue Swirl

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=4F5F781C.4080502@suse.de \
    --to=afaerber@suse.de \
    --cc=akong@redhat.com \
    --cc=aliguori@us.ibm.com \
    --cc=blauwirbel@gmail.com \
    --cc=hpoussin@reactos.org \
    --cc=jasowang@redhat.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.