aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/class/cdc-acm.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2014-04-18 19:57:00 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2014-04-18 19:57:00 -0400
commit7e55f81ecf592d269b9430d9c06db509fc3f19f9 (patch)
tree127ec2f59dad0bed386bf7f84759eddcbad2dd7c /drivers/usb/class/cdc-acm.c
parentea2388f2813ec7871c40a8b18afb80b5674d6e1d (diff)
parent94d72f008909610710bb1841d665eeeb010a0be1 (diff)
Merge tag 'usb-3.15-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb
Pull USB fixes from Greg KH: "Here are a number of tiny USB fixes and new device ids for 3.15-rc2. Nothing major, just issues some people have reported. All of these have been in linux-next" * tag 'usb-3.15-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: uas: fix deadlocky memory allocations uas: fix error handling during scsi_scan() uas: fix GFP_NOIO under spinlock uwb: adds missing error handling USB: cdc-acm: Remove Motorola/Telit H24 serial interfaces from ACM driver USB: ohci-jz4740: FEAT_POWER is a port feature, not a hub feature USB: ohci-jz4740: Fix uninitialized variable warning USB: EHCI: tegra: set txfill_tuning usb: ehci-platform: Return immediately from suspend if ehci_suspend fails usb: ehci-exynos: Return immediately from suspend if ehci_suspend fails USB: fix crash during hotplug of PCI USB controller card USB: cdc-acm: fix double usb_autopm_put_interface() in acm_port_activate() usb: usb-common: fix typo for usb_state_string USB: usb_wwan: fix handling of missing bulk endpoints USB: pl2303: add ids for Hewlett-Packard HP POS pole displays USB: cp210x: Add 8281 (Nanotec Plug & Drive) usb: option driver, add support for Telit UE910v2 Revert "USB: serial: add usbid for dell wwan card to sierra.c" USB: serial: ftdi_sio: add id for Brainboxes serial cards
Diffstat (limited to 'drivers/usb/class/cdc-acm.c')
-rw-r--r--drivers/usb/class/cdc-acm.c34
1 files changed, 25 insertions, 9 deletions
diff --git a/drivers/usb/class/cdc-acm.c b/drivers/usb/class/cdc-acm.c
index 900f7ff805ee..904efb6035b0 100644
--- a/drivers/usb/class/cdc-acm.c
+++ b/drivers/usb/class/cdc-acm.c
@@ -518,13 +518,16 @@ static int acm_port_activate(struct tty_port *port, struct tty_struct *tty)
518 if (usb_submit_urb(acm->ctrlurb, GFP_KERNEL)) { 518 if (usb_submit_urb(acm->ctrlurb, GFP_KERNEL)) {
519 dev_err(&acm->control->dev, 519 dev_err(&acm->control->dev,
520 "%s - usb_submit_urb(ctrl irq) failed\n", __func__); 520 "%s - usb_submit_urb(ctrl irq) failed\n", __func__);
521 usb_autopm_put_interface(acm->control);
521 goto error_submit_urb; 522 goto error_submit_urb;
522 } 523 }
523 524
524 acm->ctrlout = ACM_CTRL_DTR | ACM_CTRL_RTS; 525 acm->ctrlout = ACM_CTRL_DTR | ACM_CTRL_RTS;
525 if (acm_set_control(acm, acm->ctrlout) < 0 && 526 if (acm_set_control(acm, acm->ctrlout) < 0 &&
526 (acm->ctrl_caps & USB_CDC_CAP_LINE)) 527 (acm->ctrl_caps & USB_CDC_CAP_LINE)) {
528 usb_autopm_put_interface(acm->control);
527 goto error_set_control; 529 goto error_set_control;
530 }
528 531
529 usb_autopm_put_interface(acm->control); 532 usb_autopm_put_interface(acm->control);
530 533
@@ -549,7 +552,6 @@ error_submit_read_urbs:
549error_set_control: 552error_set_control:
550 usb_kill_urb(acm->ctrlurb); 553 usb_kill_urb(acm->ctrlurb);
551error_submit_urb: 554error_submit_urb:
552 usb_autopm_put_interface(acm->control);
553error_get_interface: 555error_get_interface:
554disconnected: 556disconnected:
555 mutex_unlock(&acm->mutex); 557 mutex_unlock(&acm->mutex);
@@ -1652,13 +1654,27 @@ static const struct usb_device_id acm_ids[] = {
1652 }, 1654 },
1653 /* Motorola H24 HSPA module: */ 1655 /* Motorola H24 HSPA module: */
1654 { USB_DEVICE(0x22b8, 0x2d91) }, /* modem */ 1656 { USB_DEVICE(0x22b8, 0x2d91) }, /* modem */
1655 { USB_DEVICE(0x22b8, 0x2d92) }, /* modem + diagnostics */ 1657 { USB_DEVICE(0x22b8, 0x2d92), /* modem + diagnostics */
1656 { USB_DEVICE(0x22b8, 0x2d93) }, /* modem + AT port */ 1658 .driver_info = NO_UNION_NORMAL, /* handle only modem interface */
1657 { USB_DEVICE(0x22b8, 0x2d95) }, /* modem + AT port + diagnostics */ 1659 },
1658 { USB_DEVICE(0x22b8, 0x2d96) }, /* modem + NMEA */ 1660 { USB_DEVICE(0x22b8, 0x2d93), /* modem + AT port */
1659 { USB_DEVICE(0x22b8, 0x2d97) }, /* modem + diagnostics + NMEA */ 1661 .driver_info = NO_UNION_NORMAL, /* handle only modem interface */
1660 { USB_DEVICE(0x22b8, 0x2d99) }, /* modem + AT port + NMEA */ 1662 },
1661 { USB_DEVICE(0x22b8, 0x2d9a) }, /* modem + AT port + diagnostics + NMEA */ 1663 { USB_DEVICE(0x22b8, 0x2d95), /* modem + AT port + diagnostics */
1664 .driver_info = NO_UNION_NORMAL, /* handle only modem interface */
1665 },
1666 { USB_DEVICE(0x22b8, 0x2d96), /* modem + NMEA */
1667 .driver_info = NO_UNION_NORMAL, /* handle only modem interface */
1668 },
1669 { USB_DEVICE(0x22b8, 0x2d97), /* modem + diagnostics + NMEA */
1670 .driver_info = NO_UNION_NORMAL, /* handle only modem interface */
1671 },
1672 { USB_DEVICE(0x22b8, 0x2d99), /* modem + AT port + NMEA */
1673 .driver_info = NO_UNION_NORMAL, /* handle only modem interface */
1674 },
1675 { USB_DEVICE(0x22b8, 0x2d9a), /* modem + AT port + diagnostics + NMEA */
1676 .driver_info = NO_UNION_NORMAL, /* handle only modem interface */
1677 },
1662 1678
1663 { USB_DEVICE(0x0572, 0x1329), /* Hummingbird huc56s (Conexant) */ 1679 { USB_DEVICE(0x0572, 0x1329), /* Hummingbird huc56s (Conexant) */
1664 .driver_info = NO_UNION_NORMAL, /* union descriptor misplaced on 1680 .driver_info = NO_UNION_NORMAL, /* union descriptor misplaced on