aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/usb
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/usb')
-rw-r--r--drivers/net/usb/mcs7830.c16
1 files changed, 13 insertions, 3 deletions
diff --git a/drivers/net/usb/mcs7830.c b/drivers/net/usb/mcs7830.c
index ced8f36ebd01..7ae9afe99a4f 100644
--- a/drivers/net/usb/mcs7830.c
+++ b/drivers/net/usb/mcs7830.c
@@ -486,6 +486,18 @@ static int mcs7830_set_mac_address(struct net_device *netdev, void *p)
486 return 0; 486 return 0;
487} 487}
488 488
489static const struct net_device_ops mcs7830_netdev_ops = {
490 .ndo_open = usbnet_open,
491 .ndo_stop = usbnet_stop,
492 .ndo_start_xmit = usbnet_start_xmit,
493 .ndo_tx_timeout = usbnet_tx_timeout,
494 .ndo_change_mtu = usbnet_change_mtu,
495 .ndo_validate_addr = eth_validate_addr,
496 .ndo_do_ioctl = mcs7830_ioctl,
497 .ndo_set_multicast_list = mcs7830_set_multicast,
498 .ndo_set_mac_address = mcs7830_set_mac_address,
499};
500
489static int mcs7830_bind(struct usbnet *dev, struct usb_interface *udev) 501static int mcs7830_bind(struct usbnet *dev, struct usb_interface *udev)
490{ 502{
491 struct net_device *net = dev->net; 503 struct net_device *net = dev->net;
@@ -495,11 +507,9 @@ static int mcs7830_bind(struct usbnet *dev, struct usb_interface *udev)
495 if (ret) 507 if (ret)
496 goto out; 508 goto out;
497 509
498 net->do_ioctl = mcs7830_ioctl;
499 net->ethtool_ops = &mcs7830_ethtool_ops; 510 net->ethtool_ops = &mcs7830_ethtool_ops;
500 net->set_multicast_list = mcs7830_set_multicast; 511 net->netdev_ops = &mcs7830_netdev_ops;
501 mcs7830_set_multicast(net); 512 mcs7830_set_multicast(net);
502 net->set_mac_address = mcs7830_set_mac_address;
503 513
504 /* reserve space for the status byte on rx */ 514 /* reserve space for the status byte on rx */
505 dev->rx_urb_size = ETH_FRAME_LEN + 1; 515 dev->rx_urb_size = ETH_FRAME_LEN + 1;