aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/yellowfin.c
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@vyatta.com>2008-11-21 20:35:16 -0500
committerDavid S. Miller <davem@davemloft.net>2008-11-21 20:35:16 -0500
commitbfd82c35824016920c629ea55963dc6db6f9effe (patch)
tree1960acefb2caf86dedf74047660b291dc91f6b16 /drivers/net/yellowfin.c
parenta7bd89cbb1aa8342617c2f8a6dc0595e5f553115 (diff)
yellowfin: 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/yellowfin.c')
-rw-r--r--drivers/net/yellowfin.c17
1 files changed, 11 insertions, 6 deletions
diff --git a/drivers/net/yellowfin.c b/drivers/net/yellowfin.c
index d8dbc57f3e56..f806e6361a3c 100644
--- a/drivers/net/yellowfin.c
+++ b/drivers/net/yellowfin.c
@@ -355,6 +355,16 @@ static int yellowfin_close(struct net_device *dev);
355static void set_rx_mode(struct net_device *dev); 355static void set_rx_mode(struct net_device *dev);
356static const struct ethtool_ops ethtool_ops; 356static const struct ethtool_ops ethtool_ops;
357 357
358static const struct net_device_ops netdev_ops = {
359 .ndo_open = yellowfin_open,
360 .ndo_stop = yellowfin_close,
361 .ndo_start_xmit = yellowfin_start_xmit,
362 .ndo_set_multicast_list = set_rx_mode,
363 .ndo_change_mtu = eth_change_mtu,
364 .ndo_validate_addr = eth_validate_addr,
365 .ndo_do_ioctl = netdev_ioctl,
366 .ndo_tx_timeout = yellowfin_tx_timeout,
367};
358 368
359static int __devinit yellowfin_init_one(struct pci_dev *pdev, 369static int __devinit yellowfin_init_one(struct pci_dev *pdev,
360 const struct pci_device_id *ent) 370 const struct pci_device_id *ent)
@@ -464,13 +474,8 @@ static int __devinit yellowfin_init_one(struct pci_dev *pdev,
464 np->duplex_lock = 1; 474 np->duplex_lock = 1;
465 475
466 /* The Yellowfin-specific entries in the device structure. */ 476 /* The Yellowfin-specific entries in the device structure. */
467 dev->open = &yellowfin_open; 477 dev->netdev_ops = &netdev_ops;
468 dev->hard_start_xmit = &yellowfin_start_xmit;
469 dev->stop = &yellowfin_close;
470 dev->set_multicast_list = &set_rx_mode;
471 dev->do_ioctl = &netdev_ioctl;
472 SET_ETHTOOL_OPS(dev, &ethtool_ops); 478 SET_ETHTOOL_OPS(dev, &ethtool_ops);
473 dev->tx_timeout = yellowfin_tx_timeout;
474 dev->watchdog_timeo = TX_TIMEOUT; 479 dev->watchdog_timeo = TX_TIMEOUT;
475 480
476 if (mtu) 481 if (mtu)