From: Mark McLoughlin <markmc@redhat.com>
To: Stephen Hemminger <shemminger@vyatta.com>
Cc: David Miller <davem@davemloft.net>, netdev@vger.kernel.org
Subject: Re: [PATCH 5/8] virtio: convert to net_device_ops
Date: Tue, 06 Jan 2009 09:40:45 +0000 [thread overview]
Message-ID: <1231234845.12050.2.camel@localhost.localdomain> (raw)
In-Reply-To: <20090105201514.658060465@vyatta.com>
On Mon, 2009-01-05 at 12:14 -0800, Stephen Hemminger wrote:
> Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
>
>
> --- a/drivers/net/virtio_net.c 2009-01-05 11:24:44.578819161 -0800
> +++ b/drivers/net/virtio_net.c 2009-01-05 12:11:17.169569416 -0800
> @@ -624,6 +624,18 @@ static int virtnet_change_mtu(struct net
> return 0;
> }
>
> +static const struct net_device_ops virtnet_netdev = {
> + .ndo_open = virtnet_open,
> + .ndo_stop = virtnet_close,
> + .ndo_start_xmit = start_xmit,
> + .ndo_validate_addr = eth_validate_addr,
> + .ndo_set_mac_address = eth_mac_addr,
> + .ndo_change_mtu = virtnet_change_mtu,
> +#ifdef CONFIG_NET_POLL_CONTROLLER
> + .ndo_poll_controller = virtnet_netpoll,
> +#endif
> +};
> +
> static int virtnet_probe(struct virtio_device *vdev)
> {
> int err;
> @@ -636,14 +648,8 @@ static int virtnet_probe(struct virtio_d
> return -ENOMEM;
>
> /* Set up network device as normal. */
> - dev->open = virtnet_open;
> - dev->stop = virtnet_close;
> - dev->hard_start_xmit = start_xmit;
> - dev->change_mtu = virtnet_change_mtu;
> + dev->netdev_ops = &virtnet_netdev;
> dev->features = NETIF_F_HIGHDMA;
> -#ifdef CONFIG_NET_POLL_CONTROLLER
> - dev->poll_controller = virtnet_netpoll;
> -#endif
Looks good to me.
Acked-by: Mark McLoughlin <markmc@redhat.com>
Thanks,
Mark.
next prev parent reply other threads:[~2009-01-06 9:40 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-05 20:14 [PATCH 0/8] More net_device ops Stephen Hemminger
2009-01-05 20:14 ` [PATCH 2/8] bonding: use net_device_ops Stephen Hemminger
2009-01-06 18:42 ` David Miller
2009-01-05 20:14 ` [PATCH 3/8] wireless: convert wireless ioctl to net_device_ops Stephen Hemminger
[not found] ` <20090105201514.442703045-ZtmgI6mnKB3QT0dZR+AlfA@public.gmane.org>
2009-01-06 18:42 ` David Miller
2009-01-05 20:14 ` [PATCH 4/8] dsa: convert " Stephen Hemminger
[not found] ` <20090106060705.GG4414@server.marvell.com>
2009-01-06 18:43 ` David Miller
2009-01-06 22:51 ` Stephen Hemminger
2009-01-07 0:45 ` David Miller
2009-01-05 20:14 ` [PATCH 5/8] virtio: " Stephen Hemminger
2009-01-06 9:40 ` Mark McLoughlin [this message]
2009-01-06 18:44 ` David Miller
2009-01-05 20:14 ` [PATCH 6/8] xen-netfront: " Stephen Hemminger
2009-01-06 0:17 ` Jeremy Fitzhardinge
2009-01-06 18:45 ` David Miller
2009-01-05 20:14 ` [PATCH 7/8] infiniband: driver API update Stephen Hemminger
2009-01-05 21:02 ` Roland Dreier
2009-01-05 21:22 ` [ofa-general] [PATCH 1/3] infiniband: amso100 convert to net_device_ops Stephen Hemminger
2009-01-05 21:22 ` [ofa-general] [PATCH 2/3] infiniband: nes_nic " Stephen Hemminger
2009-01-05 21:23 ` [ofa-general] [PATCH 3/3] infiniband: ipoib " Stephen Hemminger
2009-01-06 5:07 ` Roland Dreier
2009-01-06 18:46 ` [ofa-general] " David Miller
2009-01-06 18:45 ` [ofa-general] Re: [PATCH 7/8] infiniband: driver API update David Miller
2009-01-05 20:14 ` [PATCH 8/8] sch_teql: convert to net_device_ops Stephen Hemminger
2009-01-06 18:46 ` David Miller
[not found] ` <20090105201514.192918670@vyatta.com>
2009-01-06 18:41 ` [PATCH 1/8] irda: convert to internal stats David Miller
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=1231234845.12050.2.camel@localhost.localdomain \
--to=markmc@redhat.com \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=shemminger@vyatta.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).