aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/3c527.c
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@linux-foundation.org>2009-01-09 08:01:17 -0500
committerDavid S. Miller <davem@davemloft.net>2009-01-21 17:02:25 -0500
commit4394e6533da7f652a19e08009fff713f4168915e (patch)
tree38b13f3e17834379e4041cce2a1365148a15dfb2 /drivers/net/3c527.c
parent90e64c6ad2a5dd3ecad1b59e466d42945fe22eb2 (diff)
3c527: 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/3c527.c')
-rw-r--r--drivers/net/3c527.c19
1 files changed, 13 insertions, 6 deletions
diff --git a/drivers/net/3c527.c b/drivers/net/3c527.c
index 2df3af3b9b20..b61073c42bf8 100644
--- a/drivers/net/3c527.c
+++ b/drivers/net/3c527.c
@@ -288,6 +288,18 @@ struct net_device *__init mc32_probe(int unit)
288 return ERR_PTR(-ENODEV); 288 return ERR_PTR(-ENODEV);
289} 289}
290 290
291static const struct net_device_ops netdev_ops = {
292 .ndo_open = mc32_open,
293 .ndo_stop = mc32_close,
294 .ndo_start_xmit = mc32_send_packet,
295 .ndo_get_stats = mc32_get_stats,
296 .ndo_set_multicast_list = mc32_set_multicast_list,
297 .ndo_tx_timeout = mc32_timeout,
298 .ndo_change_mtu = eth_change_mtu,
299 .ndo_set_mac_address = eth_mac_addr,
300 .ndo_validate_addr = eth_validate_addr,
301};
302
291/** 303/**
292 * mc32_probe1 - Check a given slot for a board and test the card 304 * mc32_probe1 - Check a given slot for a board and test the card
293 * @dev: Device structure to fill in 305 * @dev: Device structure to fill in
@@ -518,12 +530,7 @@ static int __init mc32_probe1(struct net_device *dev, int slot)
518 printk("%s: Firmware Rev %d. %d RX buffers, %d TX buffers. Base of 0x%08X.\n", 530 printk("%s: Firmware Rev %d. %d RX buffers, %d TX buffers. Base of 0x%08X.\n",
519 dev->name, lp->exec_box->data[12], lp->rx_len, lp->tx_len, lp->base); 531 dev->name, lp->exec_box->data[12], lp->rx_len, lp->tx_len, lp->base);
520 532
521 dev->open = mc32_open; 533 dev->netdev_ops = &netdev_ops;
522 dev->stop = mc32_close;
523 dev->hard_start_xmit = mc32_send_packet;
524 dev->get_stats = mc32_get_stats;
525 dev->set_multicast_list = mc32_set_multicast_list;
526 dev->tx_timeout = mc32_timeout;
527 dev->watchdog_timeo = HZ*5; /* Board does all the work */ 534 dev->watchdog_timeo = HZ*5; /* Board does all the work */
528 dev->ethtool_ops = &netdev_ethtool_ops; 535 dev->ethtool_ops = &netdev_ethtool_ops;
529 536