diff options
author | Alexander Beregalov <a.beregalov@gmail.com> | 2009-04-09 13:25:25 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-04-11 05:53:53 -0400 |
commit | fefbfb1e09cbcd5ad6fd595c52aa8f01dc4e1126 (patch) | |
tree | 0330985e556d700fd95d934f178d927f4de8dd13 /drivers/net/arm/am79c961a.c | |
parent | f97b1f2a416045c7a9c7e62d575a809bc32c0f1e (diff) |
am79c961a: convert to net_device_ops
Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/arm/am79c961a.c')
-rw-r--r-- | drivers/net/arm/am79c961a.c | 24 |
1 files changed, 15 insertions, 9 deletions
diff --git a/drivers/net/arm/am79c961a.c b/drivers/net/arm/am79c961a.c index 4bc6901b3819..627bc75da17d 100644 --- a/drivers/net/arm/am79c961a.c +++ b/drivers/net/arm/am79c961a.c | |||
@@ -665,6 +665,20 @@ static void __init am79c961_banner(void) | |||
665 | if (net_debug && version_printed++ == 0) | 665 | if (net_debug && version_printed++ == 0) |
666 | printk(KERN_INFO "%s", version); | 666 | printk(KERN_INFO "%s", version); |
667 | } | 667 | } |
668 | static const struct net_device_ops am79c961_netdev_ops = { | ||
669 | .ndo_open = am79c961_open, | ||
670 | .ndo_stop = am79c961_close, | ||
671 | .ndo_start_xmit = am79c961_sendpacket, | ||
672 | .ndo_get_stats = am79c961_getstats, | ||
673 | .ndo_set_multicast_list = am79c961_setmulticastlist, | ||
674 | .ndo_tx_timeout = am79c961_timeout, | ||
675 | .ndo_validate_addr = eth_validate_addr, | ||
676 | .ndo_change_mtu = eth_change_mtu, | ||
677 | .ndo_set_mac_address = eth_mac_addr, | ||
678 | #ifdef CONFIG_NET_POLL_CONTROLLER | ||
679 | .ndo_poll_controller = am79c961_poll_controller, | ||
680 | #endif | ||
681 | }; | ||
668 | 682 | ||
669 | static int __init am79c961_probe(struct platform_device *pdev) | 683 | static int __init am79c961_probe(struct platform_device *pdev) |
670 | { | 684 | { |
@@ -732,15 +746,7 @@ static int __init am79c961_probe(struct platform_device *pdev) | |||
732 | if (am79c961_hw_init(dev)) | 746 | if (am79c961_hw_init(dev)) |
733 | goto release; | 747 | goto release; |
734 | 748 | ||
735 | dev->open = am79c961_open; | 749 | dev->netdev_ops = &am79c961_netdev_ops; |
736 | dev->stop = am79c961_close; | ||
737 | dev->hard_start_xmit = am79c961_sendpacket; | ||
738 | dev->get_stats = am79c961_getstats; | ||
739 | dev->set_multicast_list = am79c961_setmulticastlist; | ||
740 | dev->tx_timeout = am79c961_timeout; | ||
741 | #ifdef CONFIG_NET_POLL_CONTROLLER | ||
742 | dev->poll_controller = am79c961_poll_controller; | ||
743 | #endif | ||
744 | 750 | ||
745 | ret = register_netdev(dev); | 751 | ret = register_netdev(dev); |
746 | if (ret == 0) { | 752 | if (ret == 0) { |