qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v3 2/2] ahci: add migration support


From: Juan Quintela
Subject: Re: [Qemu-devel] [PATCH v3 2/2] ahci: add migration support
Date: Tue, 15 Jan 2013 15:54:57 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux)

Jason Baron <address@hidden> wrote:
> From: Jason Baron <address@hidden>
>
> I've tested these patches by migrating Windows 7 and Fedora 17 guests (while
> uunder i/o) on both piix with ahci attached and on q35 (which has a built-in
> ahci controller).
>
> Changes from v2:
>  -migrate all relevant ahci fields
>  -flush any pending i/o in 'post_load'
>
> Changes from v1:
>  -extend Andreas Färber's patch
>
> Signed-off-by: Jason Baron <address@hidden>
> Signed-off-by: Andreas Färber <address@hidden>
> Cc: Alexander Graf <address@hidden>
> Cc: Kevin Wolf <address@hidden>
> Cc: Juan Quintela <address@hidden>
> Cc: Igor Mitsyanko <address@hidden>
> ---
>  hw/ide/ahci.c |   80 
> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++-
>  hw/ide/ahci.h |   10 +++++++
>  hw/ide/ich.c  |   11 +++++--
>  3 files changed, 97 insertions(+), 4 deletions(-)
>
> diff --git a/hw/ide/ahci.c b/hw/ide/ahci.c
> index 72cd1c8..96f224b 100644
> --- a/hw/ide/ahci.c
> +++ b/hw/ide/ahci.c
> @@ -1199,6 +1199,81 @@ void ahci_reset(AHCIState *s)
>      }
>  }
>  
> +static const VMStateDescription vmstate_ahci_device = {
> +    .name = "ahci port",

I will try to be consistent here, vmstate_ahci_port or "ahci device"

> index de39b30..0c4206a 100644
> --- a/hw/ide/ich.c
> +++ b/hw/ide/ich.c
> @@ -79,9 +79,14 @@
>  #define ICH9_IDP_INDEX          0x10
>  #define ICH9_IDP_INDEX_LOG2     0x04
>  
> -static const VMStateDescription vmstate_ahci = {
> +static const VMStateDescription vmstate_ich9_ahci = {
>      .name = "ahci",
> -    .unmigratable = 1,


I will also preffer here to be consistent between name of the variable
ad name of the section.

> +    .version_id = 1,
> +    .fields = (VMStateField []) {
> +        VMSTATE_PCI_DEVICE(card, AHCIPCIState),
> +        VMSTATE_AHCI(ahci, AHCIPCIState),
> +        VMSTATE_END_OF_LIST()
> +    },
>  };
>  
>  static void pci_ich9_reset(DeviceState *dev)
> @@ -152,7 +157,7 @@ static void ich_ahci_class_init(ObjectClass *klass, void 
> *data)
>      k->device_id = PCI_DEVICE_ID_INTEL_82801IR;
>      k->revision = 0x02;
>      k->class_id = PCI_CLASS_STORAGE_SATA;
> -    dc->vmsd = &vmstate_ahci;
> +    dc->vmsd = &vmstate_ich9_ahci;


Both comments are stylist, nothing big.  Change if you have to
resent/whoever merge it.

Kevin?

Later, Juan.




reply via email to

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