Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

3c523: convert to net_device_ops

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Stephen Hemminger and committed by
David S. Miller
90e64c6a f3701c2f

+15 -10
+15 -10
drivers/net/3c523.c
··· 403 403 return len; 404 404 } /* elmc_getinfo() */ 405 405 406 + static const struct net_device_ops netdev_ops = { 407 + .ndo_open = elmc_open, 408 + .ndo_stop = elmc_close, 409 + .ndo_get_stats = elmc_get_stats, 410 + .ndo_start_xmit = elmc_send_packet, 411 + .ndo_tx_timeout = elmc_timeout, 412 + #ifdef ELMC_MULTICAST 413 + .ndo_set_multicast_list = set_multicast_list, 414 + #endif 415 + .ndo_change_mtu = eth_change_mtu, 416 + .ndo_set_mac_address = eth_mac_addr, 417 + .ndo_validate_addr = eth_validate_addr, 418 + }; 419 + 406 420 /*****************************************************************/ 407 421 408 422 static int __init do_elmc_probe(struct net_device *dev) ··· 558 544 printk(KERN_INFO "%s: hardware address %pM\n", 559 545 dev->name, dev->dev_addr); 560 546 561 - dev->open = &elmc_open; 562 - dev->stop = &elmc_close; 563 - dev->get_stats = &elmc_get_stats; 564 - dev->hard_start_xmit = &elmc_send_packet; 565 - dev->tx_timeout = &elmc_timeout; 547 + dev->netdev_ops = &netdev_ops; 566 548 dev->watchdog_timeo = HZ; 567 - #ifdef ELMC_MULTICAST 568 - dev->set_multicast_list = &set_multicast_list; 569 - #else 570 - dev->set_multicast_list = NULL; 571 - #endif 572 549 dev->ethtool_ops = &netdev_ethtool_ops; 573 550 574 551 /* note that we haven't actually requested the IRQ from the kernel.