diff options
author | Stephen Hemminger <shemminger@linux-foundation.org> | 2009-03-26 15:11:32 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-03-27 00:46:48 -0700 |
commit | 462540bdb2f08d465a2416764fc628520f82939f (patch) | |
tree | 71dd1c715d2faae1a0ab650fa030a11b28dadc50 /drivers/net/lance.c | |
parent | 06e884031702f06b32ce20750ab3c46c596dc776 (diff) |
lance: convert 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/lance.c')
-rw-r--r-- | drivers/net/lance.c | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/drivers/net/lance.c b/drivers/net/lance.c index d83d4010656d..633808d447be 100644 --- a/drivers/net/lance.c +++ b/drivers/net/lance.c @@ -454,6 +454,18 @@ out: } #endif +static const struct net_device_ops lance_netdev_ops = { + .ndo_open = lance_open, + .ndo_start_xmit = lance_start_xmit, + .ndo_stop = lance_close, + .ndo_get_stats = lance_get_stats, + .ndo_set_multicast_list = set_multicast_list, + .ndo_tx_timeout = lance_tx_timeout, + .ndo_change_mtu = eth_change_mtu, + .ndo_set_mac_address = eth_mac_addr, + .ndo_validate_addr = eth_validate_addr, +}; + static int __init lance_probe1(struct net_device *dev, int ioaddr, int irq, int options) { struct lance_private *lp; @@ -714,12 +726,7 @@ static int __init lance_probe1(struct net_device *dev, int ioaddr, int irq, int printk(version); /* The LANCE-specific entries in the device structure. */ - dev->open = lance_open; - dev->hard_start_xmit = lance_start_xmit; - dev->stop = lance_close; - dev->get_stats = lance_get_stats; - dev->set_multicast_list = set_multicast_list; - dev->tx_timeout = lance_tx_timeout; + dev->netdev_ops = &lance_netdev_ops; dev->watchdog_timeo = TX_TIMEOUT; err = register_netdev(dev); |