Commit Graph

1720 Commits (303694eeee5eacad5b84105a15afd9e351e1891b)

Author SHA1 Message Date
Greg Kroah-Hartman b6ea163b6d USB: f81232.c: remove dbg() tracing calls
dbg() was used a lot a long time ago to trace code flow.  Now that we have
ftrace, this isn't needed at all, so remove these calls.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-03 16:44:07 -07:00
Greg Kroah-Hartman 005331f4c4 USB: ezusb.c: remove dbg() tracing calls
dbg() was used a lot a long time ago to trace code flow.  Now that we have
ftrace, this isn't needed at all, so remove these calls.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-03 16:44:02 -07:00
Greg Kroah-Hartman 4e512ab935 USB: empeg.c: remove dbg() tracing calls
dbg() was used a lot a long time ago to trace code flow.  Now that we have
ftrace, this isn't needed at all, so remove these calls.

CC: Gary Brubaker <xavyer@ix.netcom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-03 16:43:59 -07:00
Greg Kroah-Hartman a1bd886975 USB: digi_acceleport.c: remove dbg() tracing calls
dbg() was used a lot a long time ago to trace code flow.  Now that we have
ftrace, this isn't needed at all, so remove these calls.

CC: Peter Berger <pberger@brimson.com>
CC: Al Borchers <alborchers@steinerpoint.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-03 16:43:59 -07:00
Greg Kroah-Hartman 108feb66ac USB: cypress_m8.c: remove dbg() tracing calls
dbg() was used a lot a long time ago to trace code flow.  Now that we have
ftrace, this isn't needed at all, so remove these calls.

CC: Lonnie Mendez <dignome@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-03 16:43:58 -07:00
Greg Kroah-Hartman b627488c19 USB: cyberjack.c: remove dbg() tracing calls
dbg() was used a lot a long time ago to trace code flow.  Now that we have
ftrace, this isn't needed at all, so remove these calls.

CC: Matthias Bruestle and Harald Welte <support@reiner-sct.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-03 16:43:58 -07:00
Greg Kroah-Hartman b978a5a11b USB: cp210x.c: remove dbg() tracing calls
dbg() was used a lot a long time ago to trace code flow.  Now that we have
ftrace, this isn't needed at all, so remove these calls.

CC: Johan Hovold <jhovold@gmail.com>
CC: Preston Fick <preston.fick@silabs.com>
CC: Yuri Matylitski <ym@tekinsoft.com>
CC: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-03 16:43:57 -07:00
Greg Kroah-Hartman 2ec7d459c0 USB: ch341.c: remove dbg() tracing calls
dbg() was used a lot a long time ago to trace code flow.  Now that we have
ftrace, this isn't needed at all, so remove these calls.

CC: Johan Hovold <jhovold@gmail.com>
CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-03 16:43:55 -07:00
Greg Kroah-Hartman d17a44db94 USB: belkin_sa.c: remove dbg() tracing calls
dbg() was used a lot a long time ago to trace code flow.  Now that we have
ftrace, this isn't needed at all, so remove these calls.

CC: William Greathouse <wgreathouse@smva.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-03 16:43:52 -07:00
Greg Kroah-Hartman 4d9b4001e0 USB: serial: visor: convert dbg() to dev_dbg()
This removes most of the dbg() calls, as they were just tracing calls,
and converts the remaining ones to dev_dbg().

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-03 16:40:45 -07:00
Greg Kroah-Hartman d8789b2b90 USB: serial: pl2303: convert dbg() calls to dev_dbg()
This converts the usage of dbg() to dev_dbg() where needed, and removed
a bunch of these calls where they were just "tracing" calls, which are
no longer needed.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-03 16:39:27 -07:00
Preston Fick 32445605fc usb: cp210x: Corrected USB request type definitions
The original request types in the cp210x driver are labled as "DEVICE_TO_HOST" and
"HOST_TO_DEVICE" but the actual bit definition corresponds to a request to the
interface. This has been corrected, and the actual definition for the device
requests have been added.

Signed-off-by: Preston Fick <preston.fick@silabs.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-02 13:42:43 -07:00
Ben Minerds 70f3c7586c USB: serial: belkin_sa: Changes to conform with coding style
Removed some spaces before tabs and reformatted switch statement.

Signed-off-by: Ben Minerds <puzzleduck@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-29 22:20:03 -04:00
Johan Hovold 729be47735 USB: pl2303: remove unused define
Remove unused closing-wait define.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-25 11:42:17 -07:00
Johan Hovold c1d830c5be USB: serial: fix double newlines in debug output
Remove trailing newlines from debug messages.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-25 11:42:17 -07:00
Johan Hovold c5b4ee64ae USB: serial: remove redundant write-urb kill
Since commit 1ce7b9349f ("USB: serial: reuse generic write urb and
bulk-out buffer") the port write_urb is simply a pointer to the first
member of write_urbs so there's no need to kill it twice.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-25 11:42:16 -07:00
Johan Hovold bdce6612a0 USB: serial: fix interface data use
The interface data should not be used as a flag to signal disconnect.

Now that all serial drivers use the usb_serial disconnect flag and
mutex, we can set the interface data prior to registering the ports and
there's no need to clear it at disconnect.

This should hopefully also make it more clear that the interface data is
not a flag, which could prevent future misuse.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-25 11:37:19 -07:00
Johan Hovold 6f1efd6c5a USB: pl2303: fix abuse of interface data
Fix abuse of interface data which was used to signal device disconnect.

Use the usb_serial disconnect flag and mutex where appropriate.

Note that tiocmget does not need to check for disconnect as it does not
access the device.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-25 11:37:19 -07:00
Johan Hovold 1c51766924 USB: oti6858: fix abuse of interface data
Fix abuse of interface data which was used to signal device disconnect.

Note that neither tiocmset or tiocmget need to check for disconnect as
they do not access the device.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-25 11:37:18 -07:00
Johan Hovold 81d5a67290 USB: opticon: fix abuse of interface data
Fix abuse of interface data which was used to signal device disconnect.

Use the usb_serial disconnect flag and mutex where appropriate.

Note that tiocmget does not need to check for disconnect as it does not
access the device.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-25 11:37:18 -07:00
Dan Carpenter ec42899c2f USB: wwan: remove an unneeded check
We already verified that "status" was zero on this else branch.  Since
zero is not equal to -ESHUTDOWN, this condition is always true.  I
removed it and pull everything in an indent level.

This doesn't change how the code works, it's just a cleanup.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-23 13:27:21 -07:00
Greg Kroah-Hartman 09091a4d5f Merge 3.4-rc4 into usb-next.
This resolves the conflict in:
	drivers/usb/host/ehci-fsl.c
And picks up loads of xhci bugfixes to make it easier for others to test
with.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-22 15:25:26 -07:00
Greg Kroah-Hartman 3a1c2a8220 USB: usb_wwan.c: remove err() usage
err() was a very old USB-specific macro that I thought had
gone away.  This patch removes it from being used in the
driver and uses dev_err() instead.

CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
CC: "Rafael J. Wysocki" <rjw@sisk.pl>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-20 16:54:01 -07:00
Greg Kroah-Hartman 461863df3c USB: option.c: remove err() usage
err() was a very old USB-specific macro that I thought had
gone away.  This patch removes it from being used in the
driver and uses dev_err() instead.

CC: Matthias Urlichs <smurf@smurf.noris.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-20 16:53:59 -07:00
Greg Kroah-Hartman 085fb96262 USB: console.c: remove err() usage
err() was a very old USB-specific macro that I thought had
gone away.  This patch removes it from being used in the
driver and uses dev_err() instead.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-20 16:53:58 -07:00
Yuri Matylitski 2d5733fcd3 USB: serial: cp210x: Fixed usb_control_msg timeout values
Fixed too small hardcoded timeout values for usb_control_msg
in driver for SiliconLabs cp210x-based usb-to-serial adapters.
Replaced with USB_CTRL_GET_TIMEOUT/USB_CTRL_SET_TIMEOUT.

Signed-off-by: Yuri Matylitski <ym@tekinsoft.com>
Acked-by: Kirill A. Shutemov <kirill@shutemov.name>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-20 08:44:24 -07:00
Greg Kroah-Hartman b9ee17b7f5 USB: serial: ipaq: delete duplicate id
With the recent change to remove the module parameters from the ipaq
driver, we ended up with a duplicate id in the driver.  This patch
removes it.

Reported-by: Bjørn Mork <bjorn@mork.no>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-20 08:41:02 -07:00
Donald 0eafe4de1a USB: serial: mos7840: add support for MCS7810 devices
This patch added the support of MCS7810 device for the mos7840 driver.
The MCS7810 device supports single USB2.0-to-Serial port with
a LED indicator for reflecting transmission or reception activity.

Signed-off-by: Donald Lee <donald@asix.com.tw>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-19 19:08:10 -07:00
Greg Kroah-Hartman cae18768ac USB: serial: ipaq: remove product and vendor module parameters
This driver is for devices that are no longer being made, so the ability
to add new device ids when loading the module is not a feature that
anyone uses anymore.  So remove it, which simplifies the startup code a
lot, and saves space.

If you still need to dynamically load device ids, that can be done
through sysfs.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-19 15:17:46 -07:00
Greg Kroah-Hartman 0bf4da35b5 USB: serial: visor: remove product and vendor module parameters
This driver is for devices that are no longer being made, so the ability
to add new device ids when loading the module is not a feature that
anyone uses anymore.  So remove it, which simplifies the startup code a
lot, and saves space.

If you still need to dynamically load device ids, that can be done
through sysfs.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-19 15:16:59 -07:00
Adhir Ramjiawan 72b27a07ef USB: serial: removed assignment from if statements in ti_usb_3410_5052.c
Removed the assignment statements found in if statements by the
checkpatch.pl tool.

Signed-off-by: Adhir Ramjiawan <adhirramjiawan0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-18 13:58:57 -07:00
Bjørn Mork 749541d19e USB: sierra: avoid QMI/wwan interface on MC77xx
These devices have a number of non serial interfaces as well.  Use
the existing "Direct IP" blacklist to prevent binding to interfaces
which are handled by other drivers.

We also extend the "Direct IP" blacklist with with interfaces only
seen in "QMI" mode, assuming that these devices use the same
interface numbers for serial interfaces both in "Direct IP" and in
"QMI" mode.

Signed-off-by: Bjørn Mork <bjorn@mork.no>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-17 15:54:57 -07:00
Johan Hovold a65a6f14dc USB: serial: fix race between probe and open
Fix race between probe and open by making sure that the disconnected
flag is not cleared until all ports have been registered.

A call to tty_open while probe is running may get a reference to the
serial structure in serial_install before its ports have been
registered. This may lead to usb_serial_core calling driver open before
port is fully initialised.

With ftdi_sio this result in the following NULL-pointer dereference as
the private data has not been initialised at open:

[  199.698286] IP: [<f811a089>] ftdi_open+0x59/0xe0 [ftdi_sio]
[  199.698297] *pde = 00000000
[  199.698303] Oops: 0000 [#1] PREEMPT SMP
[  199.698313] Modules linked in: ftdi_sio usbserial
[  199.698323]
[  199.698327] Pid: 1146, comm: ftdi_open Not tainted 3.2.11 #70 Dell Inc. Vostro 1520/0T816J
[  199.698339] EIP: 0060:[<f811a089>] EFLAGS: 00010286 CPU: 0
[  199.698344] EIP is at ftdi_open+0x59/0xe0 [ftdi_sio]
[  199.698348] EAX: 0000003e EBX: f5067000 ECX: 00000000 EDX: 80000600
[  199.698352] ESI: f48d8800 EDI: 00000001 EBP: f515dd54 ESP: f515dcfc
[  199.698356]  DS: 007b ES: 007b FS: 00d8 GS: 0033 SS: 0068
[  199.698361] Process ftdi_open (pid: 1146, ti=f515c000 task=f481e040 task.ti=f515c000)
[  199.698364] Stack:
[  199.698368]  f811a9fe f811a9e0 f811b3ef 00000000 00000000 00001388 00000000 f4a86800
[  199.698387]  00000002 00000000 f806e68e 00000000 f532765c f481e040 00000246 22222222
[  199.698479]  22222222 22222222 22222222 f5067004 f5327600 f5327638 f515dd74 f806e6ab
[  199.698496] Call Trace:
[  199.698504]  [<f806e68e>] ? serial_activate+0x2e/0x70 [usbserial]
[  199.698511]  [<f806e6ab>] serial_activate+0x4b/0x70 [usbserial]
[  199.698521]  [<c126380c>] tty_port_open+0x7c/0xd0
[  199.698527]  [<f806e660>] ? serial_set_termios+0xa0/0xa0 [usbserial]
[  199.698534]  [<f806e76f>] serial_open+0x2f/0x70 [usbserial]
[  199.698540]  [<c125d07c>] tty_open+0x20c/0x510
[  199.698546]  [<c10e9eb7>] chrdev_open+0xe7/0x230
[  199.698553]  [<c10e48f2>] __dentry_open+0x1f2/0x390
[  199.698559]  [<c144bfec>] ? _raw_spin_unlock+0x2c/0x50
[  199.698565]  [<c10e4b76>] nameidata_to_filp+0x66/0x80
[  199.698570]  [<c10e9dd0>] ? cdev_put+0x20/0x20
[  199.698576]  [<c10f3e08>] do_last+0x198/0x730
[  199.698581]  [<c10f4440>] path_openat+0xa0/0x350
[  199.698587]  [<c10f47d5>] do_filp_open+0x35/0x80
[  199.698593]  [<c144bfec>] ? _raw_spin_unlock+0x2c/0x50
[  199.698599]  [<c10ff110>] ? alloc_fd+0xc0/0x100
[  199.698605]  [<c10f0b72>] ? getname_flags+0x72/0x120
[  199.698611]  [<c10e4450>] do_sys_open+0xf0/0x1c0
[  199.698617]  [<c11fcc08>] ? trace_hardirqs_on_thunk+0xc/0x10
[  199.698623]  [<c10e458e>] sys_open+0x2e/0x40
[  199.698628]  [<c144c990>] sysenter_do_call+0x12/0x36
[  199.698632] Code: 85 89 00 00 00 8b 16 8b 4d c0 c1 e2 08 c7 44 24 14 88 13 00 00 81 ca 00 00 00 80 c7 44 24 10 00 00 00 00 c7 44 24 0c 00 00 00 00 <0f> b7 41 78 31 c9 89 44 24 08 c7 44 24 04 00 00 00 00 c7 04 24
[  199.698884] EIP: [<f811a089>] ftdi_open+0x59/0xe0 [ftdi_sio] SS:ESP 0068:f515dcfc
[  199.698893] CR2: 0000000000000078
[  199.698925] ---[ end trace 77c43ec023940cff ]---

Reported-and-tested-by: Ken Huang <csuhgw@gmail.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-10 13:35:53 -07:00
Johan Hovold af5810597a USB: io_ti: fix abuse of interface data
Fix abuse of interface data which was used to signal device disconnect.

Use the usb_serial disconnect flag and mutex where appropriate.

Note that there's no need to grab the mutex in chase_port as it does not
access the device.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-10 13:32:54 -07:00
Johan Hovold 5c0c7582a6 USB: whiteheat: reimplement using generic framework
Kill custom list-based read and write implementations and reimplement
using the generic framework.

Compile-only tested.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-10 13:32:07 -07:00
Johan Hovold a6765cbafa USB: whiteheat: remove driver version
Remove driver version -- it's the kernel version that matters.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-10 13:32:07 -07:00
Aleksey Babahin e2dd3af49a USB: serial: metro-usb: cosmetic fix in driver description.
Message in kernel log:
"metro-usb ttyUSB0: Metrologic USB to Serial converter now disconnected from ttyUSB0"

bit more likely than:
"metro-usb ttyUSB0: Metrologic USB to serial converter. converter now disconnected from ttyUSB0"

Signed-off-by: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-10 13:30:38 -07:00
Aleksey Babahin 41dc294002 USB: serial: metro-usb: remove duplicated #include <linux/errno.h>
Signed-off-by: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-10 13:30:37 -07:00
Aleksey Babahin bd2c09bc20 USB: serial: metro-usb: make debug messages bit more informative.
In this place result value is always zero. Use urb->status instead.

Signed-off-by: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-10 13:30:37 -07:00
Aleksey Babahin 91fbecfe59 USB: serial: metro-usb: print errors always, not only in debug mode.
Signed-off-by: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-10 13:30:37 -07:00
Aleksey Babahin 704577861d USB: serial: metro-usb: get data from device in Uni-Directional mode.
We should send special control command to tell device start or stop
transmitting a data.

In Bi-Directional mode that cmd`s are not required.

Signed-off-by: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-10 13:30:37 -07:00
Aleksey Babahin 28a4b6a690 USB: serial: metro-usb: dummy implement write_int_callback() function.
This function is never called now. Because we don`t send much data
to the device, only one byte via usb_interrupt_msg(). That doesn't require
callback function. But without declaration of write_int_callback inside
the struct usb_serial_driver, the usb_serial_probe doesn't initialize
endpoint address for the interrupt out pipe(interrupt_out_endpointAddress).
This endpoint is necessary for sending data via usb_interrupt_msg()
function.

Signed-off-by: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-10 13:30:37 -07:00
Aleksey Babahin 810ec78e9a USB: serial: metro-usb: Fix idProduct for Uni-Directional mode.
The right idProduct for Metrologic Bar Code Scanner
in Uni-Directional Serial Emulation mode is 0x0700.

Also rename idProduct for Bi-Directional mode to be a bit more informative.

Signed-off-by: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-10 13:30:36 -07:00
Anton Samokhvalov c5d703dcc7 USB: sierra: add support for Sierra Wireless MC7710
Just add new device id. 3G works fine, LTE not tested.

Signed-off-by: Anton Samokhvalov <pg83@yandex.ru>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-09 15:42:25 -07:00
Simon Arlott 876ae50d94 USB: ftdi_sio: fix race condition in TIOCMIWAIT, and abort of TIOCMIWAIT when the device is removed
There are two issues here, one is that the device is generating
spurious very fast modem status line changes somewhere:

CTS becomes high then low 18µs later:
[121226.924373] ftdi_process_packet: prev rng=0 dsr=10 dcd=0 cts=6
[121226.924378] ftdi_process_packet: status=10 prev=00 diff=10
[121226.924382] ftdi_process_packet: now rng=0 dsr=10 dcd=0 cts=7
(wake_up_interruptible is called)
[121226.924391] ftdi_process_packet: prev rng=0 dsr=10 dcd=0 cts=7
[121226.924394] ftdi_process_packet: status=00 prev=10 diff=10
[121226.924397] ftdi_process_packet: now rng=0 dsr=10 dcd=0 cts=8
(wake_up_interruptible is called)

This wakes up the task in TIOCMIWAIT:
[121226.924405] ftdi_ioctl: 19451 rng=0->0 dsr=10->10 dcd=0->0 cts=6->8
(wait from 20:51:46 returns and observes both changes)

Which then calls TIOCMIWAIT again:
20:51:46.400239 ioctl(3, TIOCMIWAIT, 0x20) = 0
22:11:09.441818 ioctl(3, TIOCMGET, [TIOCM_DTR|TIOCM_RTS]) = 0
22:11:09.442812 ioctl(3, TIOCMIWAIT, 0x20) = -1 EIO (Input/output error)
(the second wake_up_interruptible takes effect and an I/O error occurs)

The other issue is that TIOCMIWAIT will wait forever (unless the task is
interrupted) if the device is removed.

This change removes the -EIO return that occurs if the counts don't
appear to have changed. Multiple counts may have been processed as
one or the waiting task may have started waiting after recording the
current count.

It adds a bool to indicate that the device has been removed so that
TIOCMIWAIT doesn't wait forever, and wakes up any tasks so that they can
return -EIO.

Signed-off-by: Simon Arlott <simon@fire.lp0.eu>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-09 15:41:40 -07:00
Simon Arlott fca5430d48 USB: ftdi_sio: fix status line change handling for TIOCMIWAIT and TIOCGICOUNT
Handling of TIOCMIWAIT was changed by commit 1d749f9afa
 USB: ftdi_sio.c: Use ftdi async_icount structure for TIOCMIWAIT, as in other drivers

FTDI_STATUS_B0_MASK does not indicate the changed modem status lines,
it indicates the value of the current modem status lines. An xor is
still required to determine which lines have changed.

The count was only being incremented if the line was high. The only
reason TIOCMIWAIT still worked was because the status packet is
repeated every 1ms, so the count was always changing. The wakeup
itself still ran based on the status lines changing.

This change fixes handling of updates to the modem status lines and
allows multiple processes to use TIOCMIWAIT concurrently.

Tested with two processes waiting on different status lines being
toggled independently.

Signed-off-by: Simon Arlott <simon@fire.lp0.eu>
Cc: Uwe Bonnes <bon@elektron.ikp.physik.tu-darmstadt.de>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-09 15:41:16 -07:00
Alan Stern 891a3b1fdd USB: fix bug in serial driver unregistration
This patch (as1536) fixes a bug in the USB serial core.  Unloading and
reloading a serial driver while a serial device is plugged in causes
errors because of the code in usb_serial_disconnect() that tries to
make sure the port_remove method is called.  With the new order of
driver registration introduced in the 3.4 kernel, this is definitely
not the right thing to do (if indeed it ever was).

The patch removes that whole section code, along with the mechanism
for keeping track of each port's registration state, which is no
longer needed.  The driver core can handle all that stuff for us.

Note: This has been tested only with one or two USB serial drivers.
In theory, other drivers might still run into trouble.  But if they
do, it will be the fault of the drivers, not of this patch -- that is,
the drivers will need to be fixed.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Reported-and-tested-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-09 15:36:20 -07:00
Aleksey Babahin 3a450850e2 USB: serial: metro-usb: Fix idProduct for Uni-Directional mode.
The right idProduct for Metrologic Bar Code Scanner
in Uni-Directional Serial Emulation mode is 0x0700.

Also rename idProduct for Bi-Directional mode to be a bit more informative.

Signed-off-by: Aleksey Babahin <tamerlan311@gmail.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-09 15:36:20 -07:00
Santiago Garcia Mantinan 9ac2feb22b USB: option: re-add NOVATELWIRELESS_PRODUCT_HSPA_HIGHSPEED to option_id array
Re-add NOVATELWIRELESS_PRODUCT_HSPA_HIGHSPEED to option_id array

Signed-off-by: Santiago Garcia Mantinan <manty@debian.org>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-09 15:36:20 -07:00
Johan Hovold ce5c985185 USB: pl2303: fix DTR/RTS being raised on baud rate change
DTR/RTS should only be raised when changing baudrate from B0 and not on
any baud rate change (> B0).

Reported-by: Søren Holm <sgh@sgh.dk>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-09 15:36:20 -07:00
Lucas De Marchi 970e248649 Documentation: remove references to /etc/modprobe.conf
Usage of /etc/modprobe.conf file was deprecated by module-init-tools and
is no longer parsed by new kmod tool. References to this file are
replaced in Documentation, comments and Kconfig according to the
context.

There are also some references to the old /etc/modules.conf from 2.4
kernels that are being removed.

Signed-off-by: Lucas De Marchi <lucas.demarchi@profusion.mobi>
Acked-by: Takashi Iwai <tiwai@suse.de>
Acked-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2012-03-30 16:03:15 -07:00
Andrew Bird (Sphere Systems) f264ddea01 USB: option: Ignore ZTE (Vodafone) K3570/71 net interfaces
These interfaces need to be handled by QMI/WWAN driver

Signed-off-by: Andrew Bird <ajb@spheresystems.co.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
2012-03-25 13:27:48 -04:00
Linus Torvalds ed378a52da USB merge for 3.4-rc1
Here's the big USB merge for the 3.4-rc1 merge window.
 
 Lots of gadget driver reworks here, driver updates, xhci changes, some
 new drivers added, usb-serial core reworking to fix some bugs, and other
 various minor things.
 
 There are some patches touching arch code, but they have all been acked
 by the various arch maintainers.
 
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v2.0.18 (GNU/Linux)
 
 iEYEABECAAYFAk9njL8ACgkQMUfUDdst+ylQ9wCfbBOnIT01lGOorkaE9pom0hhk
 HfMAoKq1xzCR2B+OS3UMyUQffk+Ri9Ri
 =KIQ2
 -----END PGP SIGNATURE-----

Merge tag 'usb-3.3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb

Pull USB merge for 3.4-rc1 from Greg KH:
 "Here's the big USB merge for the 3.4-rc1 merge window.

  Lots of gadget driver reworks here, driver updates, xhci changes, some
  new drivers added, usb-serial core reworking to fix some bugs, and
  other various minor things.

  There are some patches touching arch code, but they have all been
  acked by the various arch maintainers."

* tag 'usb-3.3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: (302 commits)
  net: qmi_wwan: add support for ZTE MF820D
  USB: option: add ZTE MF820D
  usb: gadget: f_fs: Remove lock is held before freeing checks
  USB: option: make interface blacklist work again
  usb/ub: deprecate & schedule for removal the "Low Performance USB Block" driver
  USB: ohci-pxa27x: add clk_prepare/clk_unprepare calls
  USB: use generic platform driver on ath79
  USB: EHCI: Add a generic platform device driver
  USB: OHCI: Add a generic platform device driver
  USB: ftdi_sio: new PID: LUMEL PD12
  USB: ftdi_sio: add support for FT-X series devices
  USB: serial: mos7840: Fixed MCS7820 device attach problem
  usb: Don't make USB_ARCH_HAS_{XHCI,OHCI,EHCI} depend on USB_SUPPORT.
  usb gadget: fix a section mismatch when compiling g_ffs with CONFIG_USB_FUNCTIONFS_ETH
  USB: ohci-nxp: Remove i2c_write(), use smbus
  USB: ohci-nxp: Support for LPC32xx
  USB: ohci-nxp: Rename symbols from pnx4008 to nxp
  USB: OHCI-HCD: Rename ohci-pnx4008 to ohci-nxp
  usb: gadget: Kconfig: fix typo for 'different'
  usb: dwc3: pci: fix another failure path in dwc3_pci_probe()
  ...
2012-03-20 11:26:30 -07:00
Linus Torvalds 843ec558f9 tty and serial merge for 3.4-rc1
Here's the big serial and tty merge for the 3.4-rc1 tree.
 
 There's loads of fixes and reworks in here from Jiri for the tty layer,
 and a number of patches from Alan to help try to wrestle the vt layer
 into a sane model.
 
 Other than that, lots of driver updates and fixes, and other minor
 stuff, all detailed in the shortlog.
 
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v2.0.18 (GNU/Linux)
 
 iEYEABECAAYFAk9nihQACgkQMUfUDdst+ylXTQCdFuwVuZgjCts+xDVa1jX2ac84
 UogAn3Wr+P7NYFN6gvaGm52KbGbZs405
 =2b/l
 -----END PGP SIGNATURE-----

Merge tag 'tty-3.3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty

Pull TTY/serial patches from Greg KH:
 "tty and serial merge for 3.4-rc1

  Here's the big serial and tty merge for the 3.4-rc1 tree.

  There's loads of fixes and reworks in here from Jiri for the tty
  layer, and a number of patches from Alan to help try to wrestle the vt
  layer into a sane model.

  Other than that, lots of driver updates and fixes, and other minor
  stuff, all detailed in the shortlog."

* tag 'tty-3.3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty: (132 commits)
  serial: pxa: add clk_prepare/clk_unprepare calls
  TTY: Wrong unicode value copied in con_set_unimap()
  serial: PL011: clear pending interrupts
  serial: bfin-uart: Don't access tty circular buffer in TX DMA interrupt after it is reset.
  vt: NULL dereference in vt_do_kdsk_ioctl()
  tty: serial: vt8500: fix annotations for probe/remove
  serial: remove back and forth conversions in serial_out_sync
  serial: use serial_port_in/out vs serial_in/out in 8250
  serial: introduce generic port in/out helpers
  serial: reduce number of indirections in 8250 code
  serial: delete useless void casts in 8250.c
  serial: make 8250's serial_in shareable to other drivers.
  serial: delete last unused traces of pausing I/O in 8250
  pch_uart: Add module parameter descriptions
  pch_uart: Use existing default_baud in setup_console
  pch_uart: Add user_uartclk parameter
  pch_uart: Add Fish River Island II uart clock quirks
  pch_uart: Use uartclk instead of base_baud
  mpc5200b/uart: select more tolerant uart prescaler on low baudrates
  tty: moxa: fix bit test in moxa_start()
  ...
2012-03-20 11:24:39 -07:00
Bjørn Mork 5889d3d420 USB: option: add ZTE MF820D
This device presents a total of 5 interfaces with ff/ff/ff
class/subclass/protocol. The last one of these is verified
to be a QMI/wwan combined interface which should be handled
by the qmi_wwan driver, so we blacklist it here.

Signed-off-by: Bjørn Mork <bjorn@mork.no>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-16 13:30:11 -07:00
Bjørn Mork 963940cf47 USB: option: make interface blacklist work again
commit 0d905fd "USB: option: convert Huawei K3765, K4505, K4605
reservered interface to blacklist" accidentally ANDed two
blacklist tests by leaving out a return.  This was not noticed
because the two consecutive bracketless if statements made it
syntactically correct.

Signed-off-by: Bjørn Mork <bjorn@mork.no>
Cc: <stable@vger.kernel.org> # 3.2.y, 3.3.y
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-16 13:30:10 -07:00
Michał Wróbel 57e596f3af USB: ftdi_sio: new PID: LUMEL PD12
Signed-off-by: Michał Wróbel <michal.wrobel@flytronic.pl>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-15 12:34:30 -07:00
Jim Paris dc0827c128 USB: ftdi_sio: add support for FT-X series devices
Add PID 0x6015, corresponding to the new series of FT-X chips
(FT220XD, FT201X, FT220X, FT221X, FT230X, FT231X, FT240X).  They all
appear as serial devices, and seem indistinguishable except for the
default product string stored in their EEPROM.  The baudrate
generation matches FT232RL devices.

Tested with a FT201X and FT230X at various baudrates (100 - 3000000).

Sample dmesg:
    ftdi_sio: v1.6.0:USB FTDI Serial Converters Driver
    usb 2-1: new full-speed USB device number 6 using ohci_hcd
    usb 2-1: New USB device found, idVendor=0403, idProduct=6015
    usb 2-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
    usb 2-1: Product: FT230X USB Half UART
    usb 2-1: Manufacturer: FTDI
    usb 2-1: SerialNumber: DC001WI6
    ftdi_sio 2-1:1.0: FTDI USB Serial Device converter detected
    drivers/usb/serial/ftdi_sio.c: ftdi_sio_port_probe
    drivers/usb/serial/ftdi_sio.c: ftdi_determine_type: bcdDevice = 0x1000, bNumInterfaces = 1
    usb 2-1: Detected FT-X
    usb 2-1: Number of endpoints 2
    usb 2-1: Endpoint 1 MaxPacketSize 64
    usb 2-1: Endpoint 2 MaxPacketSize 64
    usb 2-1: Setting MaxPacketSize 64
    drivers/usb/serial/ftdi_sio.c: read_latency_timer
    drivers/usb/serial/ftdi_sio.c: write_latency_timer: setting latency timer = 1
    drivers/usb/serial/ftdi_sio.c: create_sysfs_attrs
    drivers/usb/serial/ftdi_sio.c: sysfs attributes for FT-X
    usb 2-1: FTDI USB Serial Device converter now attached to ttyUSB0

Signed-off-by: Jim Paris <jim@jtan.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-14 15:43:05 -07:00
Donald Lee 093ea2d3a7 USB: serial: mos7840: Fixed MCS7820 device attach problem
A MCS7820 device supports two serial ports and a MCS7840 device supports
four serial ports. Both devices use the same driver, but the attach function
in driver was unable to correctly handle the port numbers for MCS7820
device. This problem has been fixed in this patch and this fix has been
verified on x86 Linux kernel 3.2.9 with both MCS7820 and MCS7840 devices.

Signed-off-by: Donald Lee <donald@asix.com.tw>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-14 12:25:26 -07:00
Michał Wróbel 47594d5528 USB: ftdi_sio: new PID: Distortec JTAG-lock-pick
Signed-off-by: Michał Wróbel <michal.wrobel@flytronic.pl>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-09 12:39:52 -08:00
Greg Kroah-Hartman 5db51b50c1 USB: serial: metro-usb: move to use dev_dbg() instead of dbg()
This properly ties the driver into the dynamic debug system and provides
the needed device identification when the messages are printed out.

It also removes a ton of checkpatch warnings as well, which is always a
nice validation that it's the correct thing to do.

Cc: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-08 14:16:12 -08:00
Greg Kroah-Hartman 8111e4ecf9 USB: serial: metro-usb: remove unneeded cast and function call
We should use kzalloc() instead of kmalloc() and memset(), and remove an
unneeded void * cast as well.

Cc: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-08 14:00:11 -08:00
Greg Kroah-Hartman dd63b0b4d6 USB: serial: metro-usb: remove function header comments
They aren't needed, make the checkpatch tool unhappy, and in some
places, aren't even correct.  So just remove them, they get in the way
and are messy.

Cc: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-08 13:58:13 -08:00
Greg Kroah-Hartman 9fbd1649d5 USB: serial: metro-usb: remove function prototypes
By rearranging the functions a bit, we can remove all function
prototypes.

Note, this also deleted the _close function, as it wasn't needed, it was
doing the same thing the cleanup function did, so just call that
instead.

Cc: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-08 13:55:41 -08:00
Greg Kroah-Hartman d4cbd6e990 USB: serial: metro-usb: fix up coding style errors
This fixes up all of the coding style errors, and removes the initial,
unneeded comments on how to load the module and the old changelog which
are no longer needed.

There are still a number of coding style warnings left, I'll get to them
later.

Cc: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-08 13:50:54 -08:00
Greg Kroah-Hartman 159d4d8d5e USB: serial: metro-usb: remove the .h file
A driver doesn't need a .h file just for simple things like vendor ids
and a private structure.  So move it into the .c file instead, saving
some overall lines.

Cc: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-08 13:42:41 -08:00
Greg Kroah-Hartman 1935e357bb USB: serial: metro-usb: convert to use module_usb_serial_driver
Now that we aren't doing anything special in the init function, move to
use the easier module_usb_serial_driver() call instead, saving a lot of
lines of unnecessary code.

Cc: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-08 13:39:53 -08:00
Greg Kroah-Hartman fdac0f647a USB: serial: metro-usb: remove vendor and product module parameters
All new usb serial drivers should be using the dynamic id function, not
having module parameters for this type of thing.  So remove them before
anyone gets used to them being there.

Cc: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-08 13:37:32 -08:00
Greg Kroah-Hartman 62f2a83de0 USB: serial: metro-usb: add to the build
This adds the metro-usb driver to the build system properly.

Cc: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-08 13:34:01 -08:00
Greg Kroah-Hartman 11a4f40064 USB: serial: metro-usb: fix up usb_serial_register calls
The usb serial core has changed how the driver is to be registered and
unregistered recently.  Make these changes to the driver so that it will
properly build and work.

Cc: Aleksey Babahin <tamerlan311@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-08 13:33:04 -08:00
Aleksey Babahin 43d186fe99 USB: serial: add metro-usb driver to the tree
This driver is for the Metrologic barcode scanner.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-08 13:24:09 -08:00
Bruno Thomsen c1cee1d840 USB: Microchip VID mislabeled as Hornby VID in ftdi_sio.
Microchip VID (0x04d8) was mislabeled as Hornby VID according to USB-IDs.

A Full Speed USB Demo Board PID (0x000a) was mislabeled as
Hornby Elite (an Digital Command Controller Console for model railways).

Most likely the Hornby based their design on
PIC18F87J50 Full Speed USB Demo Board.

Signed-off-by: Bruno Thomsen <bruno.thomsen@gmail.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-08 13:05:47 -08:00
Jiri Slaby 2f16669d32 TTY: remove re-assignments to tty_driver members
All num, magic and owner are set by alloc_tty_driver. No need to
re-set them on each allocation site.

pti driver sets something different to what it passes to
alloc_tty_driver. It is not a bug, since we don't use the lines
parameter in any way. Anyway this is fixed, and now we do the right
thing.

Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Acked-by: Tilman Schmidt <tilman@imap.cc>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-08 11:37:58 -08:00
Preston Fick a5360a53a7 usb: cp210x: Update to support CP2105 and multiple interface devices
This patch updates the cp210x driver to support CP210x multiple
interface devices devices from Silicon Labs. The existing driver
always sends control requests to interface 0, which is hardcoded in
the usb_control_msg function calls. This only allows for single
interface devices to be used, and causes a bug when using ports on an
interface other than 0 in the multiple interface devices.

Here are the changes included in this patch:
- Updated the device list to contain the Silicon Labs factory default
  VID/PID for multiple interface CP210x devices
- Created a cp210x_port_private struct created for each port on
  startup, this struct holds the interface number
- Added a cp210x_release function to clean up the cp210x_port_private
  memory created on startup
- Modified usb_get_config and usb_set_config to get a pointer to the
  cp210x_port_private struct, and use the interface number there in the
  usb_control_message wIndex param

Signed-off-by: Preston Fick <preston.fick@silabs.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-02 16:19:16 -08:00
Peter Korsgaard 444aa7fa9b USB: ftdi_sio: add support for BeagleBone rev A5+
BeagleBone changed to the default FTDI 0403:6010 id in rev A5 to make life
easier for Windows users, so we need a similar workaround as the Calao
board to support it.

Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-01 09:28:28 -08:00
Daniele Palmas 7204cf5848 USB: option driver: adding support for Telit CC864-SINGLE, CC864-DUAL and DE910-DUAL modems
Adding PID for Telit CC864-SINGLE, CC864-DUAL and DE910-DUAL
modems

Signed-off-by: Daniele Palmas <dnlplm@gmail.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-01 09:28:28 -08:00
Greg Kroah-Hartman aac1fc386f USB: serial: add Fintek F81232 usb to serial driver
This is the first cut at a driver for the Fintek F81232 USB to serial
single port converter.  This provides the initial framework for the
device, and some data can move through it, but no line settings are
handled, so it's not that useful yet.  It does give people a starting
place to work from.

Thank to Fintek for providing samples and specifications, without which,
this driver would have never been able to be written.

Cc: Amanda Ying <Amanda_Ying@fintek.com.tw>
Cc: Tom Tsai <Tom_Tsai@fintek.com.tw>
Cc: <linux-usb@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:36:35 -08:00
Greg Kroah-Hartman dba607f9f0 USB: serial: zio.c: use module_usb_serial_driver
This converts the zio.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:46 -08:00
Greg Kroah-Hartman 421f38835f USB: serial: whiteheat.c: use module_usb_serial_driver
This converts the whiteheat.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Support Department <support@connecttech.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:44 -08:00
Greg Kroah-Hartman b99dab0794 USB: serial: vivopay-serial.c: use module_usb_serial_driver
This converts the vivopay-serial.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:43 -08:00
Greg Kroah-Hartman 491c77a966 USB: serial: usb_debug.c: use module_usb_serial_driver
This converts the usb_debug.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Johan Hovold <jhovold@gmail.com>
CC: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:41 -08:00
Greg Kroah-Hartman ba76df3f65 USB: serial: symbolserial.c: use module_usb_serial_driver
This converts the symbolserial.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Johan Hovold <jhovold@gmail.com>
CC: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
CC: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:38 -08:00
Greg Kroah-Hartman 3a67460715 USB: serial: ssu100.c: use module_usb_serial_driver
This converts the ssu100.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:36 -08:00
Greg Kroah-Hartman a385c150a4 USB: serial: spcp8x5.c: use module_usb_serial_driver
This converts the spcp8x5.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:34 -08:00
Greg Kroah-Hartman c9d5217478 USB: serial: sierra.c: use module_usb_serial_driver
This converts the sierra.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Alan Stern <stern@rowland.harvard.edu>
CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Johan Hovold <jhovold@gmail.com>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:31 -08:00
Greg Kroah-Hartman b4264af2c5 USB: serial: siemens_mpi.c: use module_usb_serial_driver
This converts the siemens_mpi.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:29 -08:00
Greg Kroah-Hartman 3d8d7296f7 USB: serial: qcserial.c: use module_usb_serial_driver
This converts the qcserial.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Steven Hardy <shardy@redhat.com>
CC: Thomas Tuttle <ttuttle@chromium.org>
CC: Paul Gortmaker <paul.gortmaker@windriver.com>
CC: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:26 -08:00
Greg Kroah-Hartman 5bce269d3a USB: serial: qcaux.c: use module_usb_serial_driver
This converts the qcaux.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Alan Stern <stern@rowland.harvard.edu>
CC: Dan Williams <dcbw@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:24 -08:00
Greg Kroah-Hartman db55a0492d USB: serial: oti6858.c: use module_usb_serial_driver
This converts the oti6858.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Johan Hovold <jhovold@gmail.com>
CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:22 -08:00
Greg Kroah-Hartman 9334c4c16e USB: serial: option.c: use module_usb_serial_driver
This converts the option.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Matthias Urlichs <smurf@smurf.noris.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:19 -08:00
Greg Kroah-Hartman e206b7f831 USB: serial: opticon.c: use module_usb_serial_driver
This converts the opticon.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Johan Hovold <jhovold@gmail.com>
CC: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
CC: Julia Lawall <julia@diku.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:19 -08:00
Greg Kroah-Hartman 6384eaefd3 USB: serial: omninet.c: use module_usb_serial_driver
This converts the omninet.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Johan Hovold <jhovold@gmail.com>
CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:17 -08:00
Greg Kroah-Hartman 78365eaaa1 USB: serial: navman.c: use module_usb_serial_driver
This converts the navman.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:14 -08:00
Greg Kroah-Hartman 54cbcf5126 USB: serial: moto_modem.c: use module_usb_serial_driver
This converts the moto_modem.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Alan Stern <stern@rowland.harvard.edu>
CC: Elizabeth Jennifer Myers <elizabeth@sporksirc.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:12 -08:00
Greg Kroah-Hartman e7414d9a6d USB: serial: mos7840.c: use module_usb_serial_driver
This converts the mos7840.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Johan Hovold <jhovold@gmail.com>
CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:10 -08:00
Greg Kroah-Hartman 964e2b8425 USB: serial: mos7720.c: use module_usb_serial_driver
This converts the mos7720.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Johan Hovold <jhovold@gmail.com>
CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:07 -08:00
Greg Kroah-Hartman 193ecee442 USB: serial: mct_u232.c: use module_usb_serial_driver
This converts the mct_u232.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Johan Hovold <jhovold@gmail.com>
CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:05 -08:00
Greg Kroah-Hartman 8a9040b123 USB: serial: kobil_sct.c: use module_usb_serial_driver
This converts the kobil_sct.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Johan Hovold <jhovold@gmail.com>
CC: Jiri Slaby <jslaby@suse.cz>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Felipe Balbi <balbi@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:02 -08:00
Greg Kroah-Hartman 11f79858ce USB: serial: kl5kusb105.c: use module_usb_serial_driver
This converts the kl5kusb105.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Oliver Neukum <oliver@neukum.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:12:00 -08:00
Greg Kroah-Hartman d40f5b0c0c USB: serial: keyspan_pda.c: use module_usb_serial_driver
This converts the keyspan_pda.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:59 -08:00
Greg Kroah-Hartman 165c793d92 USB: serial: keyspan.c: use module_usb_serial_driver
This converts the keyspan.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:59 -08:00
Greg Kroah-Hartman d01bf4139d USB: serial: iuu_phoenix.c: use module_usb_serial_driver
This converts the iuu_phoenix.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Johan Hovold <jhovold@gmail.com>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:58 -08:00
Greg Kroah-Hartman f939484bb6 USB: serial: ipw.c: use module_usb_serial_driver
This converts the ipw.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Oliver Neukum <oneukum@suse.de>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:56 -08:00
Greg Kroah-Hartman 8485f8c965 USB: serial: io_ti.c: use module_usb_serial_driver
This converts the io_ti.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Johan Hovold <jhovold@gmail.com>
CC: Lucas De Marchi <lucas.demarchi@profusion.mobi>
CC: "Eric W. Biederman" <ebiederm@xmission.com>
CC: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:53 -08:00
Greg Kroah-Hartman 36ccce4912 USB: serial: io_edgeport.c: use module_usb_serial_driver
This converts the io_edgeport.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Johan Hovold <jhovold@gmail.com>
CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Huzaifa Sidhpurwala <huzaifas@redhat.com>
CC: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:51 -08:00
Greg Kroah-Hartman 68e9c9a7fd USB: serial: hp4x.c: use module_usb_serial_driver
This converts the hp4x.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:49 -08:00
Greg Kroah-Hartman db62c08128 USB: serial: garmin_gps.c: use module_usb_serial_driver
This converts the garmin_gps.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Johan Hovold <jhovold@gmail.com>
CC: Andrew Morton <akpm@linux-foundation.org>
CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:46 -08:00
Greg Kroah-Hartman 65e3b087d5 USB: serial: funsoft.c: use module_usb_serial_driver
This converts the funsoft.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:44 -08:00
Greg Kroah-Hartman 10a6b9ce8e USB: serial: empeg.c: use module_usb_serial_driver
This converts the empeg.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Gary Brubaker <xavyer@ix.netcom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:42 -08:00
Greg Kroah-Hartman 89ddc53c4a USB: serial: digi_acceleport.c: use module_usb_serial_driver
This converts the digi_acceleport.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Peter Berger <pberger@brimson.com>
CC: Al Borchers <alborchers@steinerpoint.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:41 -08:00
Greg Kroah-Hartman 7e3131f897 USB: serial: cypress_m8.c: use module_usb_serial_driver
This converts the cypress_m8.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Lonnie Mendez <dignome@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:41 -08:00
Greg Kroah-Hartman 5671df5c1c USB: serial: cyberjack.c: use module_usb_serial_driver
This converts the cyberjack.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Matthias Bruestle and Harald Welte <support@reiner-sct.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:40 -08:00
Greg Kroah-Hartman 274f3b1e82 USB: serial: cp210x.c: use module_usb_serial_driver
This converts the cp210x.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Johan Hovold <jhovold@gmail.com>
CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Florian Fainelli <f.fainelli@gmail.com>
CC: "Malte Schröder" <maltesch@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:40 -08:00
Greg Kroah-Hartman a5f5e6c2d8 USB: serial: ch341.c: use module_usb_serial_driver
This converts the ch341.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Johan Hovold <jhovold@gmail.com>
CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:37 -08:00
Greg Kroah-Hartman d2daea74cc USB: serial: belkin_sa.c: use module_usb_serial_driver
This converts the belkin_sa.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: William Greathouse <wgreathouse@smva.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:35 -08:00
Greg Kroah-Hartman a9a535d358 USB: serial: ark3116.c: use module_usb_serial_driver
This converts the ark3116.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Alan Stern <stern@rowland.harvard.edu>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
CC: Bart Hartgers <bart.hartgers@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:35 -08:00
Greg Kroah-Hartman 6f84a5198f USB: serial: aircable.c: use module_usb_serial_driver
This converts the aircable.c driver to use the module_usb_serial_driver() call
instead of having to have a module_init/module_exit function, saving a lot
of duplicated code.

CC: Paul Gortmaker <paul.gortmaker@windriver.com>
CC: Lucas De Marchi <lucas.demarchi@profusion.mobi>
CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 13:11:32 -08:00
Greg KH d1cddb4a8e USB: create module_usb_serial_driver macro
Now that Alan Stern has cleaned up the usb serial driver registration,
we have the ability to create a module_usb_serial_driver macro to make
things a bit simpler, like the other *_driver macros created.

But, as we need two functions here, we can't reuse the existing
module_driver() macro, so we need to roll our own.

Here's a patch implementing module_usb_serial_driver() and it converts
the pl2303 driver to use it, showing a nice cleanup.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 11:21:48 -08:00
Meng Zhang 0d8520a1d7 USB: option: Add MediaTek MT6276M modem&app interfaces
Add MEDIATEK products to Option driver

Signed-off-by: Meng Zhang <meng.zhang@mediatek.com>
Signed-off-by: Matthias Urlichs <matthias@urlichs.de>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 10:53:09 -08:00
Greg Kroah-Hartman 656d2b3964 USB: ftdi_sio: fix problem when the manufacture is a NULL string
On some misconfigured ftdi_sio devices, if the manufacturer string is
NULL, the kernel will oops when the device is plugged in.  This patch
fixes the problem.

Reported-by: Wojciech M Zabolotny <W.Zabolotny@elka.pw.edu.pl>
Tested-by: Wojciech M Zabolotny <W.Zabolotny@elka.pw.edu.pl>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-28 09:22:04 -08:00
Scott Dial 6d161b99f8 usb-serial: Add support for the Sealevel SeaLINK+8 2038-ROHS device
This patch adds new device IDs to the ftdi_sio module to support
the new Sealevel SeaLINK+8 2038-ROHS device.

Signed-off-by: Scott Dial <scott.dial@scientiallc.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24 16:15:48 -08:00
Dan Williams c192c8e71a USB: qcserial: don't grab QMI port on Gobi 1000 devices
Gobi 1000 devices have a different port layout, which wasn't respected
by the current driver, and thus it grabbed the QMI/net port.  In the
near future we'll be attaching another driver to the QMI/net port for
these devices (cdc-wdm and qmi_wwan) so make sure the qcserial driver
doesn't claim them.  This patch also prevents qcserial from binding to
interfaces 0 and 1 on 1K devices because those interfaces do not
respond.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24 12:53:38 -08:00
Greg Kroah-Hartman f799e76783 USB: serial: remove usb_serial_register and usb_serial_deregister
No one uses them anymore, they should be using the safer
usb_serial_register_drivers() and usb_serial_deregister_drivers()
functions instead.

Thanks to Alan Stern for writing these functions and porting all
in-kernel users to them.

Cc: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24 12:50:30 -08:00
Greg Kroah-Hartman 8c49fc99b6 usb-serial: use new registration API in keyspan_pda.c
This was missed in Alan's last round of conversions.

Cc: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24 12:49:34 -08:00
Alan Stern 29618e9fb5 usb-serial: use new registration API in [t-z]* drivers
This patch (as1529) modifies the following usb-serial drivers to
utilize the new usb_serial_{de}register_drivers() routines:

	ti_usb_3410_5052, usb_debug, visor, vivopay-serial,
	whiteheat, and zio.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24 12:39:21 -08:00
Alan Stern d860322f34 usb-serial: use new registration API in [q-s]* drivers
This patch (as1528) modifies the following usb-serial drivers to
utilize the new usb_serial_{de}register_drivers() routines:

	qcaux, qcserial, safe_serial, siemens_mpi, sierra,
	spcp8x5, ssu100, and symbolserial.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24 12:39:20 -08:00
Alan Stern f667ddad41 usb-serial: use new registration API in [n-p]* drivers
This patch (as1527) modifies the following usb-serial drivers to
utilize the new usb_serial_{de}register_drivers() routines:

	navman, omninet, opticon, option, oti6858, and pl2303.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24 12:39:20 -08:00
Alan Stern 4d2a7aff10 usb-serial: use new registration API in [k-m]* drivers
This patch (as1526) modifies the following usb-serial drivers to
utilize the new usb_serial_{de}register_drivers() routines:

	keyspan, kl5kusb105, kobil_sct, mct_u232, mos7720,
	mos7840, and moto_modem.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24 12:39:19 -08:00
Alan Stern 7dbe246098 usb-serial: use new registration API in [i-j]* drivers
This patch (as1525) modifies the following usb-serial drivers to
utilize the new usb_serial_{de}register_drivers() routines:

	io_edgeport, io_ti, ipaq, ipw, ir-usb, and iuu_phoenix.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24 12:39:18 -08:00
Alan Stern 97b6b6d233 usb-serial: use new registration API in [d-h]* drivers
This patch (as1524) modifies the following usb-serial drivers to
utilize the new usb_serial_{de}register_drivers() routines:

	digi_acceleport, empeg, ftdi_sio, funsoft, garmin_gps,
	and hp4x.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24 12:39:18 -08:00
Alan Stern 08a4f6bc2e usb-serial: use new registration API in [a-c]* drivers
This patch (as1523) modifies the following usb-serial drivers to
utilize the new usb_serial_{de}register_drivers() routines:

	aircable, ark3116, belkin_sa, ch341, cp210x, cyberjack,
	and cypress_m8.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24 12:39:17 -08:00
Alan Stern 765e0ba626 usb-serial: new API for driver registration
This patch (as1522) adds two new routines to the usb-serial core, for
registering and unregistering serial drivers.  Instead of registering
the usb_driver and usb_serial_drivers separately, with error checking
for each one, the drivers can all be registered and unregistered by a
single function call.  This reduces duplicated code.

More importantly, the new core routines change the order in which the
drivers are registered.  Currently the usb-serial drivers are all
registered first and the usb_driver is done last, which leaves a
window for problems.  A udev script may quickly add a new dynamic-ID
for a usb-serial driver, causing the corresponding usb_driver to be
probed.  If the usb_driver hasn't been registered yet then an oops
will occur.

The new routine prevents such problems by registering the usb_driver
first.  To insure that it gets probed properly for already-attached
serial devices, we call driver_attach() after all the usb-serial
drivers have been registered.

Along with adding the new routines, the patch modifies the "generic"
serial driver to use them.  Further patches will similarly modify all
the other in-tree USB serial drivers.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-24 12:39:17 -08:00
Greg Kroah-Hartman c69263c66e Merge branch 'usb-3.3-rc4' into usb-next
This is to pull in the xhci changes and the other fixes and device id
updates that were done in Linus's tree.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-23 08:21:03 -08:00
Bruno Thomsen c6c1e4491d USB: Added Kamstrup VID/PIDs to cp210x serial driver.
Signed-off-by: Bruno Thomsen <bruno.thomsen@gmail.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-21 16:29:15 -08:00
Andrew Lunn 7fd25702ba USB: Serial: ti_usb_3410_5052: Add Abbot Diabetes Care cable id
This USB-serial cable with mini stereo jack enumerates as:
Bus 001 Device 004: ID 1a61:3410 Abbott Diabetes Care

It is a TI3410 inside.

Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-21 16:29:15 -08:00
li.rui27@zte.com.cn b9e44fe5ec USB: option: cleanup zte 3g-dongle's pid in option.c
1. Remove all old mass-storage ids's pid:
     0x0026,0x0053,0x0098,0x0099,0x0149,0x0150,0x0160;
  2. As the pid from 0x1401 to 0x1510 which have not surely assigned to
     use for serial-port or mass-storage port,so i think it should be
     removed now, and will re-add after it have assigned in future;
  3. sort the pid to WCDMA and CDMA.

Signed-off-by: Rui li <li.rui27@zte.com.cn>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-14 15:08:40 -08:00
Greg Kroah-Hartman 7483948fdd Merge tag 'usb-3.3-rc3' into usb-next
This is done to resolve a merge conflict with:
	drivers/usb/class/cdc-wdm.c
and to better handle future patches for this driver as it is under
active development at the moment.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-10 11:13:53 -08:00
Greg Kroah-Hartman 5a22e30def Merge tag 'tty-3.3-rc3' tty-next
This is needed to handle the 8250 file merge mess properly for future
patches.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-10 10:25:27 -08:00
Johan Hovold 22a416c4e0 USB: serial: use dev_err_console in custom write paths
Use dev_err_console in write paths for devices which can be used as a
console but do not use the generic write implementation.

Compile-only tested.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-10 10:21:04 -08:00
Johan Hovold f1475a00a1 USB: serial: use dev_err_console in generic write
Use dev_err_console in write path so that an error at least gets
reported once.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-10 10:21:04 -08:00
Johan Hovold 548dd4b6da USB: serial: fix console error reporting
Do not report errors in write path if port is used as a console as this
may trigger the same error (and error report) resulting in a loop.

Reported-by: Stephen Hemminger <shemminger@vyatta.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-10 10:20:36 -08:00
Milan Kocian 90451e6973 USB: usbserial: add new PID number (0xa951) to the ftdi driver
Signed-off-by: Milan Kocian <milon@wq.cz>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-03 11:22:44 -08:00
Jiri Slaby 76f82a7ab3 USB: serial, use tty_standard_install
But before that we need to reorder the calls so that we don't need to
lower the reference counts if usb_autopm_get_interface fails.

Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Cc: Alan Cox <alan@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-02 15:00:56 -08:00
Rui li 1608ea5f4b USB: add new zte 3g-dongle's pid to option.c
As ZTE have and will use more pid for new products this year,
so we need to add some new zte 3g-dongle's pid on option.c ,
and delete one pid 0x0154 because it use for mass-storage port.

Signed-off-by: Rui li <li.rui27@zte.com.cn>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-01 16:06:52 -08:00
Thomas Tuttle 0a365706f2 USB: qcserial: don't enable autosuspend
We've found that qcserial devices will not always wake up reliably
from autosuspend, so disable it.

Signed-off-by: Thomas Tuttle <ttuttle@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-01 15:56:18 -08:00
Thomas Tuttle 2db4d87070 USB: qcserial: add several new serial devices
Signed-off-by: Thomas Tuttle <ttuttle@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-01 15:56:18 -08:00
Alan Cox 2353f806c9 USB: ftdi_sio: Add more identifiers
0x04d8, 0x000a: Hornby Elite

Signed-off-by: Alan Cox <alan@linux.intel.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-01-26 11:22:41 -08:00
Dan Williams 074cc73506 qcaux: add more Pantech UML190 and UML290 ports
More ports we now know how to talk to.

Signed-off-by: Dan Williams <dcbw@redhat.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-01-24 15:47:52 -08:00
Johan Hovold 0b238583ac USB: cp210x: fix debug output
Remove superfluous newlines from debug statements.
Remove unnecessary line breaks.

Signed-off-by: Johan Hovold <jhovold@gmail.com>
Cc: Preston Fick <preston.fick@silabs.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-01-24 14:31:04 -08:00
Felipe Balbi 3297f86a3d usb: serial: kobil_sct: fix compile warning:
Fix the following compile warning:

drivers/usb/serial/kobil_sct.c: In function ‘__check_debug’:
drivers/usb/serial/kobil_sct.c:719:1: warning: return from incompatible
pointer type [enabled by default]

Signed-off-by: Felipe Balbi <balbi@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-01-24 12:23:18 -08:00