netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Alexander Beregalov <a.beregalov@gmail.com>
To: netdev@vger.kernel.org
Cc: Alexander Beregalov <a.beregalov@gmail.com>
Subject: [PATCH 13/26] lib82596: convert to net_device_ops
Date: Thu, 16 Apr 2009 02:52:47 +0400	[thread overview]
Message-ID: <1239835980-22502-13-git-send-email-a.beregalov@gmail.com> (raw)
In-Reply-To: <1239835980-22502-12-git-send-email-a.beregalov@gmail.com>


Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com>
---
 drivers/net/lib82596.c |   23 ++++++++++++++---------
 1 files changed, 14 insertions(+), 9 deletions(-)

diff --git a/drivers/net/lib82596.c b/drivers/net/lib82596.c
index 7415f51..070fa45 100644
--- a/drivers/net/lib82596.c
+++ b/drivers/net/lib82596.c
@@ -1036,6 +1036,19 @@ static void print_eth(unsigned char *add, char *str)
 	printk(KERN_DEBUG "i596 0x%p, %pM --> %pM %02X%02X, %s\n",
 	       add, add + 6, add, add[12], add[13], str);
 }
+static const struct net_device_ops i596_netdev_ops = {
+	.ndo_open		= i596_open,
+	.ndo_stop		= i596_close,
+	.ndo_start_xmit		= i596_start_xmit,
+	.ndo_set_multicast_list	= set_multicast_list,
+	.ndo_tx_timeout		= i596_tx_timeout,
+	.ndo_change_mtu		= eth_change_mtu,
+	.ndo_validate_addr	= eth_validate_addr,
+	.ndo_set_mac_address	= eth_mac_addr,
+#ifdef CONFIG_NET_POLL_CONTROLLER
+	.ndo_poll_controller	= i596_poll_controller,
+#endif
+};
 
 static int __devinit i82596_probe(struct net_device *dev)
 {
@@ -1062,16 +1075,8 @@ static int __devinit i82596_probe(struct net_device *dev)
 		return -ENOMEM;
 	}
 
-	/* The 82596-specific entries in the device structure. */
-	dev->open = i596_open;
-	dev->stop = i596_close;
-	dev->hard_start_xmit = i596_start_xmit;
-	dev->set_multicast_list = set_multicast_list;
-	dev->tx_timeout = i596_tx_timeout;
+	dev->netdev_ops = &i596_netdev_ops;
 	dev->watchdog_timeo = TX_TIMEOUT;
-#ifdef CONFIG_NET_POLL_CONTROLLER
-	dev->poll_controller = i596_poll_controller;
-#endif
 
 	memset(dma, 0, sizeof(struct i596_dma));
 	lp->dma = dma;
-- 
1.6.2.3


  reply	other threads:[~2009-04-15 22:53 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-15 22:52 [PATCH 01/26] bmac: convert to net_device_ops Alexander Beregalov
2009-04-15 22:52 ` [PATCH 02/26] cpmac: " Alexander Beregalov
2009-04-15 22:52   ` [PATCH 03/26] dm9000: " Alexander Beregalov
2009-04-15 22:52     ` [PATCH 04/26] hplance: " Alexander Beregalov
2009-04-15 22:52       ` [PATCH 05/26] ibmveth: " Alexander Beregalov
2009-04-15 22:52         ` [PATCH 06/26] irda/au1k_ir: " Alexander Beregalov
2009-04-15 22:52           ` [PATCH 07/26] irda/pxaficp_ir: " Alexander Beregalov
2009-04-15 22:52             ` [PATCH 08/26] irda/sa1100_ir: " Alexander Beregalov
2009-04-15 22:52               ` [PATCH 09/26] iseries_veth: " Alexander Beregalov
2009-04-15 22:52                 ` [PATCH 10/26] ixp2000/ixpdev: " Alexander Beregalov
2009-04-15 22:52                   ` [PATCH 11/26] jazzsonic: " Alexander Beregalov
2009-04-15 22:52                     ` [PATCH 12/26] korina: " Alexander Beregalov
2009-04-15 22:52                       ` Alexander Beregalov [this message]
2009-04-15 22:52                         ` [PATCH 14/26] mace: " Alexander Beregalov
2009-04-15 22:52                           ` [PATCH 15/26] macmace: " Alexander Beregalov
2009-04-15 22:52                             ` [PATCH 16/26] meth: " Alexander Beregalov
2009-04-15 22:52                               ` [PATCH 17/26] mipsnet: " Alexander Beregalov
2009-04-15 22:52                                 ` [PATCH 18/26] mvme147: " Alexander Beregalov
2009-04-15 22:52                                   ` [PATCH 19/26] netx-eth: " Alexander Beregalov
2009-04-15 22:52                                     ` [PATCH 20/26] pasemi_mac: " Alexander Beregalov
2009-04-15 22:52                                       ` [PATCH 21/26] pci-skeleton: " Alexander Beregalov
2009-04-15 22:52                                         ` [PATCH 22/26] rionet: " Alexander Beregalov
2009-04-15 22:52                                           ` [PATCH 23/26] sb1250-mac: " Alexander Beregalov
2009-04-15 22:52                                             ` [PATCH 24/26] sgiseeq: " Alexander Beregalov
2009-04-15 22:52                                               ` [PATCH 25/26] smc911x: " Alexander Beregalov
2009-04-15 22:53                                                 ` [PATCH 26/26] sun3lance: " Alexander Beregalov
2009-04-16  9:24 ` [PATCH 01/26] bmac: " 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=1239835980-22502-13-git-send-email-a.beregalov@gmail.com \
    --to=a.beregalov@gmail.com \
    --cc=netdev@vger.kernel.org \
    /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).