diff options
Diffstat (limited to 'drivers/usb')
-rw-r--r-- | drivers/usb/atm/ueagle-atm.c | 22 | ||||
-rw-r--r-- | drivers/usb/core/Kconfig | 12 | ||||
-rw-r--r-- | drivers/usb/gadget/composite.c | 18 | ||||
-rw-r--r-- | drivers/usb/host/xhci-mem.c | 25 | ||||
-rw-r--r-- | drivers/usb/misc/uss720.c | 4 | ||||
-rw-r--r-- | drivers/usb/serial/ftdi_sio.c | 1 | ||||
-rw-r--r-- | drivers/usb/serial/ftdi_sio_ids.h | 5 | ||||
-rw-r--r-- | drivers/usb/storage/unusual_devs.h | 7 |
8 files changed, 69 insertions, 25 deletions
diff --git a/drivers/usb/atm/ueagle-atm.c b/drivers/usb/atm/ueagle-atm.c index 44447f54942f..99ac70e32556 100644 --- a/drivers/usb/atm/ueagle-atm.c +++ b/drivers/usb/atm/ueagle-atm.c | |||
@@ -2206,8 +2206,11 @@ static int uea_boot(struct uea_softc *sc) | |||
2206 | goto err1; | 2206 | goto err1; |
2207 | } | 2207 | } |
2208 | 2208 | ||
2209 | sc->kthread = kthread_run(uea_kthread, sc, "ueagle-atm"); | 2209 | /* Create worker thread, but don't start it here. Start it after |
2210 | if (sc->kthread == ERR_PTR(-ENOMEM)) { | 2210 | * all usbatm generic initialization is done. |
2211 | */ | ||
2212 | sc->kthread = kthread_create(uea_kthread, sc, "ueagle-atm"); | ||
2213 | if (IS_ERR(sc->kthread)) { | ||
2211 | uea_err(INS_TO_USBDEV(sc), "failed to create thread\n"); | 2214 | uea_err(INS_TO_USBDEV(sc), "failed to create thread\n"); |
2212 | goto err2; | 2215 | goto err2; |
2213 | } | 2216 | } |
@@ -2624,6 +2627,7 @@ static struct usbatm_driver uea_usbatm_driver = { | |||
2624 | static int uea_probe(struct usb_interface *intf, const struct usb_device_id *id) | 2627 | static int uea_probe(struct usb_interface *intf, const struct usb_device_id *id) |
2625 | { | 2628 | { |
2626 | struct usb_device *usb = interface_to_usbdev(intf); | 2629 | struct usb_device *usb = interface_to_usbdev(intf); |
2630 | int ret; | ||
2627 | 2631 | ||
2628 | uea_enters(usb); | 2632 | uea_enters(usb); |
2629 | uea_info(usb, "ADSL device founded vid (%#X) pid (%#X) Rev (%#X): %s\n", | 2633 | uea_info(usb, "ADSL device founded vid (%#X) pid (%#X) Rev (%#X): %s\n", |
@@ -2637,7 +2641,19 @@ static int uea_probe(struct usb_interface *intf, const struct usb_device_id *id) | |||
2637 | if (UEA_IS_PREFIRM(id)) | 2641 | if (UEA_IS_PREFIRM(id)) |
2638 | return uea_load_firmware(usb, UEA_CHIP_VERSION(id)); | 2642 | return uea_load_firmware(usb, UEA_CHIP_VERSION(id)); |
2639 | 2643 | ||
2640 | return usbatm_usb_probe(intf, id, &uea_usbatm_driver); | 2644 | ret = usbatm_usb_probe(intf, id, &uea_usbatm_driver); |
2645 | if (ret == 0) { | ||
2646 | struct usbatm_data *usbatm = usb_get_intfdata(intf); | ||
2647 | struct uea_softc *sc = usbatm->driver_data; | ||
2648 | |||
2649 | /* Ensure carrier is initialized to off as early as possible */ | ||
2650 | UPDATE_ATM_SIGNAL(ATM_PHY_SIG_LOST); | ||
2651 | |||
2652 | /* Only start the worker thread when all init is done */ | ||
2653 | wake_up_process(sc->kthread); | ||
2654 | } | ||
2655 | |||
2656 | return ret; | ||
2641 | } | 2657 | } |
2642 | 2658 | ||
2643 | static void uea_disconnect(struct usb_interface *intf) | 2659 | static void uea_disconnect(struct usb_interface *intf) |
diff --git a/drivers/usb/core/Kconfig b/drivers/usb/core/Kconfig index 9eed5b52d9de..bcc24779ba0e 100644 --- a/drivers/usb/core/Kconfig +++ b/drivers/usb/core/Kconfig | |||
@@ -107,11 +107,19 @@ config USB_SUSPEND | |||
107 | If you are unsure about this, say N here. | 107 | If you are unsure about this, say N here. |
108 | 108 | ||
109 | config USB_OTG | 109 | config USB_OTG |
110 | bool | 110 | bool "OTG support" |
111 | depends on USB && EXPERIMENTAL | 111 | depends on USB && EXPERIMENTAL |
112 | depends on USB_SUSPEND | 112 | depends on USB_SUSPEND |
113 | default n | 113 | default n |
114 | 114 | help | |
115 | The most notable feature of USB OTG is support for a | ||
116 | "Dual-Role" device, which can act as either a device | ||
117 | or a host. The initial role is decided by the type of | ||
118 | plug inserted and can be changed later when two dual | ||
119 | role devices talk to each other. | ||
120 | |||
121 | Select this only if your board has Mini-AB/Micro-AB | ||
122 | connector. | ||
115 | 123 | ||
116 | config USB_OTG_WHITELIST | 124 | config USB_OTG_WHITELIST |
117 | bool "Rely on OTG Targeted Peripherals List" | 125 | bool "Rely on OTG Targeted Peripherals List" |
diff --git a/drivers/usb/gadget/composite.c b/drivers/usb/gadget/composite.c index 7b5cc16e4a0b..8572dad5ecbb 100644 --- a/drivers/usb/gadget/composite.c +++ b/drivers/usb/gadget/composite.c | |||
@@ -1047,9 +1047,9 @@ composite_unbind(struct usb_gadget *gadget) | |||
1047 | kfree(cdev->req->buf); | 1047 | kfree(cdev->req->buf); |
1048 | usb_ep_free_request(gadget->ep0, cdev->req); | 1048 | usb_ep_free_request(gadget->ep0, cdev->req); |
1049 | } | 1049 | } |
1050 | device_remove_file(&gadget->dev, &dev_attr_suspended); | ||
1050 | kfree(cdev); | 1051 | kfree(cdev); |
1051 | set_gadget_data(gadget, NULL); | 1052 | set_gadget_data(gadget, NULL); |
1052 | device_remove_file(&gadget->dev, &dev_attr_suspended); | ||
1053 | composite = NULL; | 1053 | composite = NULL; |
1054 | } | 1054 | } |
1055 | 1055 | ||
@@ -1107,14 +1107,6 @@ static int composite_bind(struct usb_gadget *gadget) | |||
1107 | */ | 1107 | */ |
1108 | usb_ep_autoconfig_reset(cdev->gadget); | 1108 | usb_ep_autoconfig_reset(cdev->gadget); |
1109 | 1109 | ||
1110 | /* standardized runtime overrides for device ID data */ | ||
1111 | if (idVendor) | ||
1112 | cdev->desc.idVendor = cpu_to_le16(idVendor); | ||
1113 | if (idProduct) | ||
1114 | cdev->desc.idProduct = cpu_to_le16(idProduct); | ||
1115 | if (bcdDevice) | ||
1116 | cdev->desc.bcdDevice = cpu_to_le16(bcdDevice); | ||
1117 | |||
1118 | /* composite gadget needs to assign strings for whole device (like | 1110 | /* composite gadget needs to assign strings for whole device (like |
1119 | * serial number), register function drivers, potentially update | 1111 | * serial number), register function drivers, potentially update |
1120 | * power state and consumption, etc | 1112 | * power state and consumption, etc |
@@ -1126,6 +1118,14 @@ static int composite_bind(struct usb_gadget *gadget) | |||
1126 | cdev->desc = *composite->dev; | 1118 | cdev->desc = *composite->dev; |
1127 | cdev->desc.bMaxPacketSize0 = gadget->ep0->maxpacket; | 1119 | cdev->desc.bMaxPacketSize0 = gadget->ep0->maxpacket; |
1128 | 1120 | ||
1121 | /* standardized runtime overrides for device ID data */ | ||
1122 | if (idVendor) | ||
1123 | cdev->desc.idVendor = cpu_to_le16(idVendor); | ||
1124 | if (idProduct) | ||
1125 | cdev->desc.idProduct = cpu_to_le16(idProduct); | ||
1126 | if (bcdDevice) | ||
1127 | cdev->desc.bcdDevice = cpu_to_le16(bcdDevice); | ||
1128 | |||
1129 | /* stirng overrides */ | 1129 | /* stirng overrides */ |
1130 | if (iManufacturer || !cdev->desc.iManufacturer) { | 1130 | if (iManufacturer || !cdev->desc.iManufacturer) { |
1131 | if (!iManufacturer && !composite->iManufacturer && | 1131 | if (!iManufacturer && !composite->iManufacturer && |
diff --git a/drivers/usb/host/xhci-mem.c b/drivers/usb/host/xhci-mem.c index 0fae58ef8afe..1d0f45f0e7a6 100644 --- a/drivers/usb/host/xhci-mem.c +++ b/drivers/usb/host/xhci-mem.c | |||
@@ -1680,6 +1680,7 @@ static void xhci_add_in_port(struct xhci_hcd *xhci, unsigned int num_ports, | |||
1680 | xhci->port_array[i] = (u8) -1; | 1680 | xhci->port_array[i] = (u8) -1; |
1681 | } | 1681 | } |
1682 | /* FIXME: Should we disable the port? */ | 1682 | /* FIXME: Should we disable the port? */ |
1683 | continue; | ||
1683 | } | 1684 | } |
1684 | xhci->port_array[i] = major_revision; | 1685 | xhci->port_array[i] = major_revision; |
1685 | if (major_revision == 0x03) | 1686 | if (major_revision == 0x03) |
@@ -1758,16 +1759,20 @@ static int xhci_setup_port_arrays(struct xhci_hcd *xhci, gfp_t flags) | |||
1758 | return -ENOMEM; | 1759 | return -ENOMEM; |
1759 | 1760 | ||
1760 | port_index = 0; | 1761 | port_index = 0; |
1761 | for (i = 0; i < num_ports; i++) | 1762 | for (i = 0; i < num_ports; i++) { |
1762 | if (xhci->port_array[i] != 0x03) { | 1763 | if (xhci->port_array[i] == 0x03 || |
1763 | xhci->usb2_ports[port_index] = | 1764 | xhci->port_array[i] == 0 || |
1764 | &xhci->op_regs->port_status_base + | 1765 | xhci->port_array[i] == -1) |
1765 | NUM_PORT_REGS*i; | 1766 | continue; |
1766 | xhci_dbg(xhci, "USB 2.0 port at index %u, " | 1767 | |
1767 | "addr = %p\n", i, | 1768 | xhci->usb2_ports[port_index] = |
1768 | xhci->usb2_ports[port_index]); | 1769 | &xhci->op_regs->port_status_base + |
1769 | port_index++; | 1770 | NUM_PORT_REGS*i; |
1770 | } | 1771 | xhci_dbg(xhci, "USB 2.0 port at index %u, " |
1772 | "addr = %p\n", i, | ||
1773 | xhci->usb2_ports[port_index]); | ||
1774 | port_index++; | ||
1775 | } | ||
1771 | } | 1776 | } |
1772 | if (xhci->num_usb3_ports) { | 1777 | if (xhci->num_usb3_ports) { |
1773 | xhci->usb3_ports = kmalloc(sizeof(*xhci->usb3_ports)* | 1778 | xhci->usb3_ports = kmalloc(sizeof(*xhci->usb3_ports)* |
diff --git a/drivers/usb/misc/uss720.c b/drivers/usb/misc/uss720.c index 796e2f68f749..4ff21587ab03 100644 --- a/drivers/usb/misc/uss720.c +++ b/drivers/usb/misc/uss720.c | |||
@@ -3,7 +3,7 @@ | |||
3 | /* | 3 | /* |
4 | * uss720.c -- USS720 USB Parport Cable. | 4 | * uss720.c -- USS720 USB Parport Cable. |
5 | * | 5 | * |
6 | * Copyright (C) 1999, 2005 | 6 | * Copyright (C) 1999, 2005, 2010 |
7 | * Thomas Sailer (t.sailer@alumni.ethz.ch) | 7 | * Thomas Sailer (t.sailer@alumni.ethz.ch) |
8 | * | 8 | * |
9 | * This program is free software; you can redistribute it and/or modify | 9 | * This program is free software; you can redistribute it and/or modify |
@@ -776,6 +776,8 @@ static const struct usb_device_id uss720_table[] = { | |||
776 | { USB_DEVICE(0x0557, 0x2001) }, | 776 | { USB_DEVICE(0x0557, 0x2001) }, |
777 | { USB_DEVICE(0x0729, 0x1284) }, | 777 | { USB_DEVICE(0x0729, 0x1284) }, |
778 | { USB_DEVICE(0x1293, 0x0002) }, | 778 | { USB_DEVICE(0x1293, 0x0002) }, |
779 | { USB_DEVICE(0x1293, 0x0002) }, | ||
780 | { USB_DEVICE(0x050d, 0x0002) }, | ||
779 | { } /* Terminating entry */ | 781 | { } /* Terminating entry */ |
780 | }; | 782 | }; |
781 | 783 | ||
diff --git a/drivers/usb/serial/ftdi_sio.c b/drivers/usb/serial/ftdi_sio.c index 6a50965e23f2..2dec50013528 100644 --- a/drivers/usb/serial/ftdi_sio.c +++ b/drivers/usb/serial/ftdi_sio.c | |||
@@ -796,6 +796,7 @@ static struct usb_device_id id_table_combined [] = { | |||
796 | { USB_DEVICE(FTDI_VID, FTDI_SCIENCESCOPE_LOGBOOKML_PID) }, | 796 | { USB_DEVICE(FTDI_VID, FTDI_SCIENCESCOPE_LOGBOOKML_PID) }, |
797 | { USB_DEVICE(FTDI_VID, FTDI_SCIENCESCOPE_LS_LOGBOOK_PID) }, | 797 | { USB_DEVICE(FTDI_VID, FTDI_SCIENCESCOPE_LS_LOGBOOK_PID) }, |
798 | { USB_DEVICE(FTDI_VID, FTDI_SCIENCESCOPE_HS_LOGBOOK_PID) }, | 798 | { USB_DEVICE(FTDI_VID, FTDI_SCIENCESCOPE_HS_LOGBOOK_PID) }, |
799 | { USB_DEVICE(FTDI_VID, FTDI_DOTEC_PID) }, | ||
799 | { USB_DEVICE(QIHARDWARE_VID, MILKYMISTONE_JTAGSERIAL_PID), | 800 | { USB_DEVICE(QIHARDWARE_VID, MILKYMISTONE_JTAGSERIAL_PID), |
800 | .driver_info = (kernel_ulong_t)&ftdi_jtag_quirk }, | 801 | .driver_info = (kernel_ulong_t)&ftdi_jtag_quirk }, |
801 | { }, /* Optional parameter entry */ | 802 | { }, /* Optional parameter entry */ |
diff --git a/drivers/usb/serial/ftdi_sio_ids.h b/drivers/usb/serial/ftdi_sio_ids.h index 1286f1e23d8c..bf0867285481 100644 --- a/drivers/usb/serial/ftdi_sio_ids.h +++ b/drivers/usb/serial/ftdi_sio_ids.h | |||
@@ -1081,6 +1081,11 @@ | |||
1081 | #define MJSG_HD_RADIO_PID 0x937C | 1081 | #define MJSG_HD_RADIO_PID 0x937C |
1082 | 1082 | ||
1083 | /* | 1083 | /* |
1084 | * D.O.Tec products (http://www.directout.eu) | ||
1085 | */ | ||
1086 | #define FTDI_DOTEC_PID 0x9868 | ||
1087 | |||
1088 | /* | ||
1084 | * Xverve Signalyzer tools (http://www.signalyzer.com/) | 1089 | * Xverve Signalyzer tools (http://www.signalyzer.com/) |
1085 | */ | 1090 | */ |
1086 | #define XVERVE_SIGNALYZER_ST_PID 0xBCA0 | 1091 | #define XVERVE_SIGNALYZER_ST_PID 0xBCA0 |
diff --git a/drivers/usb/storage/unusual_devs.h b/drivers/usb/storage/unusual_devs.h index 6ccdd3dd5259..fcc1e32ce256 100644 --- a/drivers/usb/storage/unusual_devs.h +++ b/drivers/usb/storage/unusual_devs.h | |||
@@ -481,6 +481,13 @@ UNUSUAL_DEV( 0x04e8, 0x507c, 0x0220, 0x0220, | |||
481 | USB_SC_DEVICE, USB_PR_DEVICE, NULL, | 481 | USB_SC_DEVICE, USB_PR_DEVICE, NULL, |
482 | US_FL_MAX_SECTORS_64), | 482 | US_FL_MAX_SECTORS_64), |
483 | 483 | ||
484 | /* Reported by Vitaly Kuznetsov <vitty@altlinux.ru> */ | ||
485 | UNUSUAL_DEV( 0x04e8, 0x5122, 0x0000, 0x9999, | ||
486 | "Samsung", | ||
487 | "YP-CP3", | ||
488 | USB_SC_DEVICE, USB_PR_DEVICE, NULL, | ||
489 | US_FL_MAX_SECTORS_64 | US_FL_BULK_IGNORE_TAG), | ||
490 | |||
484 | /* Entry and supporting patch by Theodore Kilgore <kilgota@auburn.edu>. | 491 | /* Entry and supporting patch by Theodore Kilgore <kilgota@auburn.edu>. |
485 | * Device uses standards-violating 32-byte Bulk Command Block Wrappers and | 492 | * Device uses standards-violating 32-byte Bulk Command Block Wrappers and |
486 | * reports itself as "Proprietary SCSI Bulk." Cf. device entry 0x084d:0x0011. | 493 | * reports itself as "Proprietary SCSI Bulk." Cf. device entry 0x084d:0x0011. |