aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/usb
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@vyatta.com>2009-03-20 15:35:49 -0400
committerDavid S. Miller <davem@davemloft.net>2009-03-21 22:40:58 -0400
commit19b8f8f1a1cd9e31a1092a6841065471df8db00f (patch)
tree443aa82cd6bec200af9f58a2c754cd76745fac12 /drivers/net/usb
parentedc4ae08644045dc803dc519f96ff245cb80adad (diff)
usbnet: convert catc device 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/usb')
-rw-r--r--drivers/net/usb/catc.c18
1 files changed, 13 insertions, 5 deletions
diff --git a/drivers/net/usb/catc.c b/drivers/net/usb/catc.c
index 2fb4e3654d79..b9dd42574288 100644
--- a/drivers/net/usb/catc.c
+++ b/drivers/net/usb/catc.c
@@ -743,6 +743,18 @@ static int catc_stop(struct net_device *netdev)
743 return 0; 743 return 0;
744} 744}
745 745
746static const struct net_device_ops catc_netdev_ops = {
747 .ndo_open = catc_open,
748 .ndo_stop = catc_stop,
749 .ndo_start_xmit = catc_start_xmit,
750
751 .ndo_tx_timeout = catc_tx_timeout,
752 .ndo_set_multicast_list = catc_set_multicast_list,
753 .ndo_change_mtu = eth_change_mtu,
754 .ndo_set_mac_address = eth_mac_addr,
755 .ndo_validate_addr = eth_validate_addr,
756};
757
746/* 758/*
747 * USB probe, disconnect. 759 * USB probe, disconnect.
748 */ 760 */
@@ -767,12 +779,8 @@ static int catc_probe(struct usb_interface *intf, const struct usb_device_id *id
767 779
768 catc = netdev_priv(netdev); 780 catc = netdev_priv(netdev);
769 781
770 netdev->open = catc_open; 782 netdev->netdev_ops = &catc_netdev_ops;
771 netdev->hard_start_xmit = catc_hard_start_xmit;
772 netdev->stop = catc_stop;
773 netdev->tx_timeout = catc_tx_timeout;
774 netdev->watchdog_timeo = TX_TIMEOUT; 783 netdev->watchdog_timeo = TX_TIMEOUT;
775 netdev->set_multicast_list = catc_set_multicast_list;
776 SET_ETHTOOL_OPS(netdev, &ops); 784 SET_ETHTOOL_OPS(netdev, &ops);
777 785
778 catc->usbdev = usbdev; 786 catc->usbdev = usbdev;