diff options
author | Stephen Hemminger <shemminger@vyatta.com> | 2009-01-08 02:59:47 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-01-08 02:59:47 +0100 |
commit | 90d8743d03593520ceb5e8fd8cf3b86072518f83 (patch) | |
tree | 793491692cda8b06ea7ef44334d231c8afab00ae | |
parent | tulip: convert devices to new API (diff) | |
download | linux-90d8743d03593520ceb5e8fd8cf3b86072518f83.tar.xz linux-90d8743d03593520ceb5e8fd8cf3b86072518f83.zip |
de2104x: convert to net_device_ops
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | drivers/net/tulip/de2104x.c | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/drivers/net/tulip/de2104x.c b/drivers/net/tulip/de2104x.c index 5166be930a52..d5d53b633cf8 100644 --- a/drivers/net/tulip/de2104x.c +++ b/drivers/net/tulip/de2104x.c @@ -1922,6 +1922,18 @@ bad_srom: goto fill_defaults; } +static const struct net_device_ops de_netdev_ops = { + .ndo_open = de_open, + .ndo_stop = de_close, + .ndo_set_multicast_list = de_set_rx_mode, + .ndo_start_xmit = de_start_xmit, + .ndo_get_stats = de_get_stats, + .ndo_tx_timeout = de_tx_timeout, + .ndo_change_mtu = eth_change_mtu, + .ndo_set_mac_address = eth_mac_addr, + .ndo_validate_addr = eth_validate_addr, +}; + static int __devinit de_init_one (struct pci_dev *pdev, const struct pci_device_id *ent) { @@ -1944,14 +1956,9 @@ static int __devinit de_init_one (struct pci_dev *pdev, if (!dev) return -ENOMEM; + dev->netdev_ops = &de_netdev_ops; SET_NETDEV_DEV(dev, &pdev->dev); - dev->open = de_open; - dev->stop = de_close; - dev->set_multicast_list = de_set_rx_mode; - dev->hard_start_xmit = de_start_xmit; - dev->get_stats = de_get_stats; dev->ethtool_ops = &de_ethtool_ops; - dev->tx_timeout = de_tx_timeout; dev->watchdog_timeo = TX_TIMEOUT; de = netdev_priv(dev); |