From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:56080) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xj1Jy-00010J-On for qemu-devel@nongnu.org; Tue, 28 Oct 2014 03:36:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Xj1Jr-0008JY-9D for qemu-devel@nongnu.org; Tue, 28 Oct 2014 03:36:02 -0400 Received: from mx1.redhat.com ([209.132.183.28]:59541) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xj1Jr-0008JN-2G for qemu-devel@nongnu.org; Tue, 28 Oct 2014 03:35:55 -0400 From: Markus Armbruster Date: Tue, 28 Oct 2014 08:35:34 +0100 Message-Id: <1414481739-19939-6-git-send-email-armbru@redhat.com> In-Reply-To: <1414481739-19939-1-git-send-email-armbru@redhat.com> References: <1414481739-19939-1-git-send-email-armbru@redhat.com> Subject: [Qemu-devel] [PATCH RFC 05/10] pcnet: Convert to realize List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: pbonzini@redhat.com, arei.gonglei@huawei.com, kraxel@redhat.com, afaerber@suse.de, mst@redhat.com Signed-off-by: Markus Armbruster --- hw/net/pcnet-pci.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/hw/net/pcnet-pci.c b/hw/net/pcnet-pci.c index 50eb069..e5122a0 100644 --- a/hw/net/pcnet-pci.c +++ b/hw/net/pcnet-pci.c @@ -297,7 +297,7 @@ static NetClientInfo net_pci_pcnet_info = { .cleanup = pci_pcnet_cleanup, }; -static int pci_pcnet_init(PCIDevice *pci_dev) +static void pci_pcnet_realize(PCIDevice *pci_dev, Error **errp) { PCIPCNetState *d = PCI_PCNET(pci_dev); PCNetState *s = &d->state; @@ -336,7 +336,6 @@ static int pci_pcnet_init(PCIDevice *pci_dev) s->dma_opaque = pci_dev; pcnet_common_init(DEVICE(pci_dev), s, &net_pci_pcnet_info); - return 0; } static void pci_reset(DeviceState *dev) @@ -366,7 +365,7 @@ static void pcnet_class_init(ObjectClass *klass, void *data) DeviceClass *dc = DEVICE_CLASS(klass); PCIDeviceClass *k = PCI_DEVICE_CLASS(klass); - k->init = pci_pcnet_init; + k->realize = pci_pcnet_realize; k->exit = pci_pcnet_uninit; k->romfile = "efi-pcnet.rom", k->vendor_id = PCI_VENDOR_ID_AMD; -- 1.9.3