aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/dl2k.c
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@vyatta.com>2008-11-21 20:31:51 -0500
committerDavid S. Miller <davem@davemloft.net>2008-11-21 20:31:51 -0500
commit876526443e64ae15bc3715dd6fbe8b9deadf89bc (patch)
treeadda64a6cf4abaaa2c01c7b82e78207e9d08bb38 /drivers/net/dl2k.c
parent0421eae68ffaf5ecfac860ee86e6a92e5b32a992 (diff)
dl2k: convert to net_device_ops
Convert driver to new net_device_ops. Compile tested only. Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/dl2k.c')
-rw-r--r--drivers/net/dl2k.c22
1 files changed, 14 insertions, 8 deletions
diff --git a/drivers/net/dl2k.c b/drivers/net/dl2k.c
index 9ec9785a9fc3..c749e9fb47ef 100644
--- a/drivers/net/dl2k.c
+++ b/drivers/net/dl2k.c
@@ -85,6 +85,19 @@ static int mii_write (struct net_device *dev, int phy_addr, int reg_num,
85 85
86static const struct ethtool_ops ethtool_ops; 86static const struct ethtool_ops ethtool_ops;
87 87
88static const struct net_device_ops netdev_ops = {
89 .ndo_open = rio_open,
90 .ndo_start_xmit = start_xmit,
91 .ndo_stop = rio_close,
92 .ndo_get_stats = get_stats,
93 .ndo_validate_addr = eth_validate_addr,
94 .ndo_set_mac_address = eth_mac_addr,
95 .ndo_set_multicast_list = set_multicast,
96 .ndo_do_ioctl = rio_ioctl,
97 .ndo_tx_timeout = rio_tx_timeout,
98 .ndo_change_mtu = change_mtu,
99};
100
88static int __devinit 101static int __devinit
89rio_probe1 (struct pci_dev *pdev, const struct pci_device_id *ent) 102rio_probe1 (struct pci_dev *pdev, const struct pci_device_id *ent)
90{ 103{
@@ -197,15 +210,8 @@ rio_probe1 (struct pci_dev *pdev, const struct pci_device_id *ent)
197 else if (tx_coalesce > TX_RING_SIZE-1) 210 else if (tx_coalesce > TX_RING_SIZE-1)
198 tx_coalesce = TX_RING_SIZE - 1; 211 tx_coalesce = TX_RING_SIZE - 1;
199 } 212 }
200 dev->open = &rio_open; 213 dev->netdev_ops = &netdev_ops;
201 dev->hard_start_xmit = &start_xmit;
202 dev->stop = &rio_close;
203 dev->get_stats = &get_stats;
204 dev->set_multicast_list = &set_multicast;
205 dev->do_ioctl = &rio_ioctl;
206 dev->tx_timeout = &rio_tx_timeout;
207 dev->watchdog_timeo = TX_TIMEOUT; 214 dev->watchdog_timeo = TX_TIMEOUT;
208 dev->change_mtu = &change_mtu;
209 SET_ETHTOOL_OPS(dev, &ethtool_ops); 215 SET_ETHTOOL_OPS(dev, &ethtool_ops);
210#if 0 216#if 0
211 dev->features = NETIF_F_IP_CSUM; 217 dev->features = NETIF_F_IP_CSUM;