aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/cs89x0.c
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@linux-foundation.org>2009-03-26 11:11:43 -0400
committerDavid S. Miller <davem@davemloft.net>2009-03-27 03:46:55 -0400
commit15d23e7a9e02c8ecbbf9a855e626707ba839135a (patch)
tree62d746fff746b0883272c395fe4c8ced0f9b7e32 /drivers/net/cs89x0.c
parent635d8ba2ecb614b88ab16cb82c12cb344cab4427 (diff)
netdev: convert cs89x0 to net_device_ops
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/cs89x0.c')
-rw-r--r--drivers/net/cs89x0.c28
1 files changed, 17 insertions, 11 deletions
diff --git a/drivers/net/cs89x0.c b/drivers/net/cs89x0.c
index ff6497658a45..7433b88eed7e 100644
--- a/drivers/net/cs89x0.c
+++ b/drivers/net/cs89x0.c
@@ -501,6 +501,21 @@ static void net_poll_controller(struct net_device *dev)
501} 501}
502#endif 502#endif
503 503
504static const struct net_device_ops net_ops = {
505 .ndo_open = net_open,
506 .ndo_stop = net_close,
507 .ndo_tx_timeout = net_timeout,
508 .ndo_start_xmit = net_send_packet,
509 .ndo_get_stats = net_get_stats,
510 .ndo_set_multicast_list = set_multicast_list,
511 .ndo_set_mac_address = set_mac_address,
512#ifdef CONFIG_NET_POLL_CONTROLLER
513 .ndo_poll_controller = net_poll_controller,
514#endif
515 .ndo_change_mtu = eth_change_mtu,
516 .ndo_validate_addr = eth_validate_addr,
517};
518
504/* This is the real probe routine. Linux has a history of friendly device 519/* This is the real probe routine. Linux has a history of friendly device
505 probes on the ISA bus. A good device probes avoids doing writes, and 520 probes on the ISA bus. A good device probes avoids doing writes, and
506 verifies that the correct device exists and functions. 521 verifies that the correct device exists and functions.
@@ -843,17 +858,8 @@ cs89x0_probe1(struct net_device *dev, int ioaddr, int modular)
843 /* print the ethernet address. */ 858 /* print the ethernet address. */
844 printk(", MAC %pM", dev->dev_addr); 859 printk(", MAC %pM", dev->dev_addr);
845 860
846 dev->open = net_open; 861 dev->netdev_ops = &net_ops;
847 dev->stop = net_close; 862 dev->watchdog_timeo = HZ;
848 dev->tx_timeout = net_timeout;
849 dev->watchdog_timeo = HZ;
850 dev->hard_start_xmit = net_send_packet;
851 dev->get_stats = net_get_stats;
852 dev->set_multicast_list = set_multicast_list;
853 dev->set_mac_address = set_mac_address;
854#ifdef CONFIG_NET_POLL_CONTROLLER
855 dev->poll_controller = net_poll_controller;
856#endif
857 863
858 printk("\n"); 864 printk("\n");
859 if (net_debug) 865 if (net_debug)