aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/3c509.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/3c509.c')
-rw-r--r--drivers/net/3c509.c25
1 files changed, 16 insertions, 9 deletions
diff --git a/drivers/net/3c509.c b/drivers/net/3c509.c
index 8c694213035b..fbb371921991 100644
--- a/drivers/net/3c509.c
+++ b/drivers/net/3c509.c
@@ -537,6 +537,21 @@ static struct mca_driver el3_mca_driver = {
537static int mca_registered; 537static int mca_registered;
538#endif /* CONFIG_MCA */ 538#endif /* CONFIG_MCA */
539 539
540static const struct net_device_ops netdev_ops = {
541 .ndo_open = el3_open,
542 .ndo_stop = el3_close,
543 .ndo_start_xmit = el3_start_xmit,
544 .ndo_get_stats = el3_get_stats,
545 .ndo_set_multicast_list = set_multicast_list,
546 .ndo_tx_timeout = el3_tx_timeout,
547 .ndo_change_mtu = eth_change_mtu,
548 .ndo_set_mac_address = eth_mac_addr,
549 .ndo_validate_addr = eth_validate_addr,
550#ifdef CONFIG_NET_POLL_CONTROLLER
551 .ndo_poll_controller = el3_poll_controller,
552#endif
553};
554
540static int __devinit el3_common_init(struct net_device *dev) 555static int __devinit el3_common_init(struct net_device *dev)
541{ 556{
542 struct el3_private *lp = netdev_priv(dev); 557 struct el3_private *lp = netdev_priv(dev);
@@ -553,16 +568,8 @@ static int __devinit el3_common_init(struct net_device *dev)
553 } 568 }
554 569
555 /* The EL3-specific entries in the device structure. */ 570 /* The EL3-specific entries in the device structure. */
556 dev->open = &el3_open; 571 dev->netdev_ops = &netdev_ops;
557 dev->hard_start_xmit = &el3_start_xmit;
558 dev->stop = &el3_close;
559 dev->get_stats = &el3_get_stats;
560 dev->set_multicast_list = &set_multicast_list;
561 dev->tx_timeout = el3_tx_timeout;
562 dev->watchdog_timeo = TX_TIMEOUT; 572 dev->watchdog_timeo = TX_TIMEOUT;
563#ifdef CONFIG_NET_POLL_CONTROLLER
564 dev->poll_controller = el3_poll_controller;
565#endif
566 SET_ETHTOOL_OPS(dev, &ethtool_ops); 573 SET_ETHTOOL_OPS(dev, &ethtool_ops);
567 574
568 err = register_netdev(dev); 575 err = register_netdev(dev);