diff options
author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2014-10-03 20:24:46 +0200 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2014-10-03 20:24:46 +0200 |
commit | 447a8b858e4bda41c394b1bc7fdbc9dc0bdf44f6 (patch) | |
tree | 676e741f2552c9cb301e1e49c557b92bf8940f55 /drivers/net/usb/cdc_subset.c | |
parent | Input: i8042 - fix Asus X450LCP touchpad detection (diff) | |
parent | Input: soc_button_array - convert to platform bus (diff) | |
download | linux-447a8b858e4bda41c394b1bc7fdbc9dc0bdf44f6.tar.xz linux-447a8b858e4bda41c394b1bc7fdbc9dc0bdf44f6.zip |
Merge branch 'next' into for-linus
Prepare first round of input updates for 3.18.
Diffstat (limited to 'drivers/net/usb/cdc_subset.c')
-rw-r--r-- | drivers/net/usb/cdc_subset.c | 27 |
1 files changed, 26 insertions, 1 deletions
diff --git a/drivers/net/usb/cdc_subset.c b/drivers/net/usb/cdc_subset.c index 91f0919fe278..6ea98cff2d3b 100644 --- a/drivers/net/usb/cdc_subset.c +++ b/drivers/net/usb/cdc_subset.c @@ -85,14 +85,28 @@ static int always_connected (struct usbnet *dev) * *-------------------------------------------------------------------------*/ +static void m5632_recover(struct usbnet *dev) +{ + struct usb_device *udev = dev->udev; + struct usb_interface *intf = dev->intf; + int r; + + r = usb_lock_device_for_reset(udev, intf); + if (r < 0) + return; + + usb_reset_device(udev); + usb_unlock_device(udev); +} + static const struct driver_info ali_m5632_info = { .description = "ALi M5632", .flags = FLAG_POINTTOPOINT, + .recover = m5632_recover, }; #endif - #ifdef CONFIG_USB_AN2720 #define HAVE_HARDWARE @@ -326,12 +340,23 @@ static const struct usb_device_id products [] = { MODULE_DEVICE_TABLE(usb, products); /*-------------------------------------------------------------------------*/ +static int dummy_prereset(struct usb_interface *intf) +{ + return 0; +} + +static int dummy_postreset(struct usb_interface *intf) +{ + return 0; +} static struct usb_driver cdc_subset_driver = { .name = "cdc_subset", .probe = usbnet_probe, .suspend = usbnet_suspend, .resume = usbnet_resume, + .pre_reset = dummy_prereset, + .post_reset = dummy_postreset, .disconnect = usbnet_disconnect, .id_table = products, .disable_hub_initiated_lpm = 1, |