All of lore.kernel.org
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Laszlo Ersek <lersek@redhat.com>
Cc: blauwirbel@gmail.com, akong@redhat.com, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] PIIX3: reset the VM when the Reset Control Register's RCPU bit gets set
Date: Tue, 15 Jan 2013 17:53:38 +0100	[thread overview]
Message-ID: <50F58992.90005@redhat.com> (raw)
In-Reply-To: <1358207252-23852-1-git-send-email-lersek@redhat.com>

Il 15/01/2013 00:47, Laszlo Ersek ha scritto:
> @@ -442,12 +455,14 @@ static void piix3_reset(void *opaque)
>      pci_conf[0xae] = 0x00;
>  
>      d->pic_levels = 0;
> +    d->rcr = 0;
>  }
>  
>  static int piix3_post_load(void *opaque, int version_id)
>  {
>      PIIX3State *piix3 = opaque;
>      piix3_update_irq_levels(piix3);
> +    piix3->rcr &= 2; /* keep System Reset type only */
>      return 0;
>  }
>  
> @@ -464,7 +479,7 @@ static void piix3_pre_save(void *opaque)
>  
>  static const VMStateDescription vmstate_piix3 = {
>      .name = "PIIX3",
> -    .version_id = 3,
> +    .version_id = 4,
>      .minimum_version_id = 2,
>      .minimum_version_id_old = 2,
>      .post_load = piix3_post_load,
> @@ -473,15 +488,46 @@ static const VMStateDescription vmstate_piix3 = {
>          VMSTATE_PCI_DEVICE(dev, PIIX3State),
>          VMSTATE_INT32_ARRAY_V(pci_irq_levels_vmstate, PIIX3State,
>                                PIIX_NUM_PIRQS, 3),
> +        VMSTATE_UINT8_V(rcr, PIIX3State, 4),
>          VMSTATE_END_OF_LIST()
>      }

It would be nice to put this in a subsection, since it should be almost
always 0.

Otherwise, the patch looks good.

Thanks!

Paolo

  reply	other threads:[~2013-01-15 16:53 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-14 23:47 [Qemu-devel] [PATCH] PIIX3: reset the VM when the Reset Control Register's RCPU bit gets set Laszlo Ersek
2013-01-15 16:53 ` Paolo Bonzini [this message]
2013-01-15 19:09   ` Laszlo Ersek
2013-01-15 20:04   ` [Qemu-devel] [PATCH v2] " Laszlo Ersek
2013-01-15 20:12     ` [Qemu-devel] v1->v2 diff (PIIX3: reset the VM when the Reset Control Register's RCPU bit gets set) Laszlo Ersek
2013-01-16 10:54     ` [Qemu-devel] [PATCH v2] PIIX3: reset the VM when the Reset Control Register's RCPU bit gets set Paolo Bonzini
2013-01-16 18:06     ` Anthony Liguori

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=50F58992.90005@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=akong@redhat.com \
    --cc=blauwirbel@gmail.com \
    --cc=lersek@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 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.