[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-ppc] [PULL 36/45] net: lan9118: convert SysBus init method to
From: |
David Gibson |
Subject: |
Re: [Qemu-ppc] [PULL 36/45] net: lan9118: convert SysBus init method to a realize method |
Date: |
Tue, 23 Oct 2018 16:23:50 +0100 |
User-agent: |
Mutt/1.10.1 (2018-07-13) |
On Thu, Oct 18, 2018 at 05:04:13PM -0300, Eduardo Habkost wrote:
> From: Cédric Le Goater <address@hidden>
>
> Signed-off-by: Cédric Le Goater <address@hidden>
> Message-Id: <address@hidden>
> Reviewed-by: Philippe Mathieu-Daudé <address@hidden>
> Signed-off-by: Eduardo Habkost <address@hidden>
Reviewed-by: David Gibson <address@hidden>
> ---
> hw/net/lan9118.c | 9 +++------
> 1 file changed, 3 insertions(+), 6 deletions(-)
>
> diff --git a/hw/net/lan9118.c b/hw/net/lan9118.c
> index b9032dac59..a6269d9463 100644
> --- a/hw/net/lan9118.c
> +++ b/hw/net/lan9118.c
> @@ -1320,9 +1320,9 @@ static NetClientInfo net_lan9118_info = {
> .link_status_changed = lan9118_set_link,
> };
>
> -static int lan9118_init1(SysBusDevice *sbd)
> +static void lan9118_realize(DeviceState *dev, Error **errp)
> {
> - DeviceState *dev = DEVICE(sbd);
> + SysBusDevice *sbd = SYS_BUS_DEVICE(dev);
> lan9118_state *s = LAN9118(dev);
> QEMUBH *bh;
> int i;
> @@ -1349,8 +1349,6 @@ static int lan9118_init1(SysBusDevice *sbd)
> s->timer = ptimer_init(bh, PTIMER_POLICY_DEFAULT);
> ptimer_set_freq(s->timer, 10000);
> ptimer_set_limit(s->timer, 0xffff, 1);
> -
> - return 0;
> }
>
> static Property lan9118_properties[] = {
> @@ -1362,12 +1360,11 @@ static Property lan9118_properties[] = {
> static void lan9118_class_init(ObjectClass *klass, void *data)
> {
> DeviceClass *dc = DEVICE_CLASS(klass);
> - SysBusDeviceClass *k = SYS_BUS_DEVICE_CLASS(klass);
>
> - k->init = lan9118_init1;
> dc->reset = lan9118_reset;
> dc->props = lan9118_properties;
> dc->vmsd = &vmstate_lan9118;
> + dc->realize = lan9118_realize;
> }
>
> static const TypeInfo lan9118_info = {
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
signature.asc
Description: PGP signature
- [Qemu-ppc] [PULL 31/45] memory-device: complete factoring out plug handling, (continued)
- [Qemu-ppc] [PULL 31/45] memory-device: complete factoring out plug handling, Eduardo Habkost, 2018/10/18
- [Qemu-ppc] [PULL 30/45] memory-device: complete factoring out pre_plug handling, Eduardo Habkost, 2018/10/18
- [Qemu-ppc] [PULL 32/45] memory-device: complete factoring out unplug handling, Eduardo Habkost, 2018/10/18
- [Qemu-ppc] [PULL 33/45] memory-device: trace when pre_plugging/plugging/unplugging, Eduardo Habkost, 2018/10/18
- [Qemu-ppc] [PULL 34/45] net: etraxfs_eth: convert SysBus init method to a realize method, Eduardo Habkost, 2018/10/18
- [Qemu-ppc] [PULL 35/45] net: etraxfs_eth: add a reset method, Eduardo Habkost, 2018/10/18
- [Qemu-ppc] [PULL 37/45] net: lance: convert SysBus init method to a realize method, Eduardo Habkost, 2018/10/18
- [Qemu-ppc] [PULL 36/45] net: lan9118: convert SysBus init method to a realize method, Eduardo Habkost, 2018/10/18
- Re: [Qemu-ppc] [PULL 36/45] net: lan9118: convert SysBus init method to a realize method,
David Gibson <=
- [Qemu-ppc] [PULL 38/45] net: milkymist_minimac2: convert SysBus init method to a realize method, Eduardo Habkost, 2018/10/18
- [Qemu-ppc] [PULL 39/45] net: mipsnet: convert SysBus init method to a realize method, Eduardo Habkost, 2018/10/18
- [Qemu-ppc] [PULL 40/45] net: opencores_eth: convert SysBus init method to a realize method, Eduardo Habkost, 2018/10/18
- [Qemu-ppc] [PULL 41/45] net: smc91c111: convert SysBus init method to a realize method, Eduardo Habkost, 2018/10/18
- [Qemu-ppc] [PULL 42/45] net: stellaris_enet: convert SysBus init method to a realize method, Eduardo Habkost, 2018/10/18