From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53210) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WLYnh-0000pP-9e for qemu-devel@nongnu.org; Thu, 06 Mar 2014 08:57:34 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WLYna-0008QN-PU for qemu-devel@nongnu.org; Thu, 06 Mar 2014 08:57:29 -0500 Received: from mail-qc0-f178.google.com ([209.85.216.178]:38390) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WLYna-0008QH-LC for qemu-devel@nongnu.org; Thu, 06 Mar 2014 08:57:22 -0500 Received: by mail-qc0-f178.google.com with SMTP id i8so2832046qcq.23 for ; Thu, 06 Mar 2014 05:57:21 -0800 (PST) From: Mike Day In-Reply-To: <1394088217-4504-1-git-send-email-aik@ozlabs.ru> References: <1394088217-4504-1-git-send-email-aik@ozlabs.ru> Date: Thu, 06 Mar 2014 08:57:20 -0500 Message-ID: <87bnxjo2f3.fsf@pixel.localdomain> MIME-Version: 1.0 Content-Type: text/plain Subject: Re: [Qemu-devel] [PATCH] usb-ohci: add vmstate descriptor List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Alexey Kardashevskiy , qemu-devel@nongnu.org Alexey Kardashevskiy writes: > This adds migration support for OHCI. > > Signed-off-by: Alexey Kardashevskiy Reviewed-by: Mike Day > --- > hw/usb/hcd-ohci.c | 12 ++++++++++++ > 1 file changed, 12 insertions(+) > > diff --git a/hw/usb/hcd-ohci.c b/hw/usb/hcd-ohci.c > index e38cdeb..c42e091 100644 > --- a/hw/usb/hcd-ohci.c > +++ b/hw/usb/hcd-ohci.c > @@ -1984,6 +1984,17 @@ static Property ohci_pci_properties[] = { > DEFINE_PROP_END_OF_LIST(), > }; > > +static const VMStateDescription vmstate_ohci = { > + .name = "ohci", > + .version_id = 1, > + .minimum_version_id = 1, > + .minimum_version_id_old = 1, > + .fields = (VMStateField[]) { > + VMSTATE_PCI_DEVICE(parent_obj, OHCIPCIState), > + VMSTATE_END_OF_LIST() > + } > +}; > + > static void ohci_pci_class_init(ObjectClass *klass, void *data) > { > DeviceClass *dc = DEVICE_CLASS(klass); > @@ -1997,6 +2008,7 @@ static void ohci_pci_class_init(ObjectClass *klass, void *data) > set_bit(DEVICE_CATEGORY_USB, dc->categories); > dc->desc = "Apple USB Controller"; > dc->props = ohci_pci_properties; > + dc->vmsd = &vmstate_ohci; > } > > static const TypeInfo ohci_pci_info = { > -- > 1.8.4.rc4 > >