aboutsummaryrefslogtreecommitdiff
path: root/drivers/usb/serial
AgeCommit message (Collapse)Author
2008-04-28drivers/usb annotations and fixesAl Viro
* endianness annotations * endianness fixes * missing get_unaligned/put_unaligned It's pretty much all over the place, changes to different files are independent. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Serial-parts-Acked-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-04-24USB: remove unnecessary type casting of urb->contextMing Lei
urb->context code cleanup Signed-off-by: Ming Lei <tom.leiming@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24usb serial: more fixes and groundwork for tty changesAlan Cox
- If a termios change fails due to lack of memory we should copy the old settings back over as the device has not changed - Note various locking problems - kl5kusb105 had various remaining tty flag handling problems - Make safe_serial use tty_insert_flip_string not open coded loops - set termios speed properly in usb_serial Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: replace remaining __FUNCTION__ occurrencesHarvey Harrison
__FUNCTION__ is gcc-specific, use __func__ Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: serial: remove endpoints setting checks from core and headerGreg Kroah-Hartman
Remove the unused check for num_interrupt and friends as well as remove them from the header file because no usb-serial drivers no longer reference them. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: serial: remove unneeded number endpoints settingsGreg Kroah-Hartman
The usb-serial core no longer checks these fields so remove them from all of the individual drivers. They will be removed from the usb-serial core in a patch later in the series. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: option.c: correct DTR behaviourChris Collins
Setting DTR et al. should work for all interfaces if you actually pass the interface number. :-P This should help with devices that have important pseudo-serial ports that aren't on the first interface in the device. Signed-off-by: Chris Collins <chris@ursys.com.au> Signed-off-by: Matthias Urlichs <matthias@urlichs.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: Remove superfluous "depends on USB_SERIAL" from Kconfig.Robert P. J. Day
Given that most of drivers/usb/serial/Kconfig is wrapped inside: if USB_SERIAL ... endif # USB_SERIAL remove the consequently redundant dependencies on USB_SERIAL. Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: oti6858: fix TCFLSH ioctl handlingPaulius Zaleckas
Removes unimplemented TCFLSH handling from oti6858, because it was preventing TCFLSH handling by upper layer (line discipline) drivers (see drivers/char/tty_io.c line 3450). Signed-off-by: Paulius Zaleckas <paulius.zaleckas@teltonika.lt> Acked-by: Alan Cox <alan@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: add usb-serial spcp8x5 driverGreg Kroah-Hartman
Original version of the driver done by Linxb, changes by Harald, and lots of cleanups by me in order to get it into a mergable state. Cc: Linxb <xubin.lin@worldplus.com.cn> Cc: Harald Klein <hari@vt100.at> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24usb/usb-serial-sierra-add-new-dev-groupKevin Lloyd
This patch is for the sierra driver and adds support for a new group of devices that have a new USB configuration. This targets kernel 2.6.25-rc7 Signed-off-by: Kevin Lloyd <klloyd@sierrawireless.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: Serial: Sierra: C597 fixKevin Lloyd
This patch is for the sierra driver and fixes a Compass 597 bug that allows users to access the SD-Card. This targets kernel 2.6.25-rc7 Signed-off-by: Kevin Lloyd <klloyd@sierrawireless.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: Serial: Sierra: Clean upKevin Lloyd
This patch cleans up some of the sierra driver code. Please package this with the other patches in this group as I would like the driver version to reflect their changes as well. Signed-off-by: Kevin Lloyd <klloyd@sierrawireless.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: Remove EXPERIMENTAL designation from USB serial/ Kconfig entriesRobert P. J. Day
Since nothing under the USB serial/ directory seems to be obviously experimental, remove the EXPERIMENTAL dependency from all of those Kconfig entries. Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: cypress_m8: Speed handlingAlan Cox
The recent changes to this driver cleaned it up a lot, follow that up by sorting the speed side of things out as well Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: ipaq: fix devices having more than one endpointMatthias Geissert
The ipaq module supports devices with one endpoint only. Some devices, e.g. Yakumo Delta 300, have more than one endpoint. This patch fixes support for devices having up to 2 endpoints which used to work on older kernel versions. Signed-off-by: Matthias Geissert <matthias.geissert@web.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: io_ti.c: remove unneeded null tty checkRay Lee
The Coverity checker (and Adrian Bunk) spotted an inconsistent NULL check of port->tty (it's blindly dereferenced later without the check). Alan Cox confirmed the check can go. Signed-off-by: Ray Lee <ray-lk@madrabbit.org> Cc: Adrian Bunk <bunk@kernel.org> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: use DIV_ROUND_UPJulia Lawall
The kernel.h macro DIV_ROUND_UP performs the computation (((n) + (d) - 1) / (d)) but is perhaps more readable. An extract of the semantic patch that makes this change is as follows: (http://www.emn.fr/x-info/coccinelle/) // <smpl> @haskernel@ @@ #include <linux/kernel.h> @depends on haskernel@ expression n,d; @@ ( - (n + d - 1) / d + DIV_ROUND_UP(n,d) | - (n + (d - 1)) / d + DIV_ROUND_UP(n,d) ) @depends on haskernel@ expression n,d; @@ - DIV_ROUND_UP((n),d) + DIV_ROUND_UP(n,d) @depends on haskernel@ expression n,d; @@ - DIV_ROUND_UP(n,(d)) + DIV_ROUND_UP(n,d) // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: io_ti: lock mcr and msr shadows properlyAlan Cox
Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: ti_usb_3410_5052: Extend locking to msr and shadow mcrAlan Cox
Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: kobil_sct: Get rid of unneeded priv->line_stateAlan Cox
Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: iuu_phoenix: lock priv->tiostatus properlyAlan Cox
Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: serial: Note mos7480 and option don't lock modem statusAlan Cox
Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: ftdi_sio: Note missing lockingAlan Cox
The ftdi_sio driver has no internal locking on the dtr/rts state. Flag that up for someone to fix. Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: usb-serial: Prepare for BKL push downAlan Cox
Take the lock in usb-serial instead. As it relies on the BKL internally we can't push it any deeper yet. Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: cypress_m8: Limit baud rate to <=4800 for USB low speed devicesMike Isely
The cypress app note for the M8 states that for the USB low speed version of the part, throughput is effectively limited to 800 bytes/sec. So if we were to try a faster baud rate in such cases then we risk overrun errors on receive. Best to just identify this case and limit the rate to 4800 baud or less (by ignoring any request to set a faster rate). The old baud rate setting code was somewhat fragile; this change also hopefully makes it easier in the future to better checking / limiting. Signed-off-by: Mike Isely <isely@pobox.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: cypress_m8: Get rid of pointless NULL checkMike Isely
Remove a NULL check in cypress_m8; the check is useless in this context because it is referenced earlier in the same code path thus the kernel would be oops'ed before reaching this point anyway. (And it's really pointless here anyway; if this pointer somehow is NULL the driver is going to have serious problems in many other places.) Signed-off-by: Mike Isely <isely@pobox.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: cypress_m8: Don't issue GET_CONFIG for certain devicesMike Isely
Earthmate LT-20 devices (both "old" and "new" versions) can't tolerate a GET_CONFIG command. The original Earthmate has no trouble with this. Presumably other non-Earthmate devices are still OK as well. This change disables the use of GET_CONFIG for cases where it is known not to work. Signed-off-by: Mike Isely <isely@pobox.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: cypress_m8: Packet format is separate from characteristic sizeMike Isely
cypress_m8: Packet format is separate from characteristic size The Cypress app note states that when using an 8 byte packet buffer size that the packet format is modified (to be more compact). However I have since discovered that newer DeLorme Earthmate LT-20 devices (those that are low speed USB with 8 byte packet size) STILL use the format that is really supposed to correspond to 32 byte packets. Further confusing things is the subsequent discovery that there are actually two different types of LT-20 - older LT-20's use 32 byte packets which is probably why this issue wasn't originally encountered. The solution here is to flag the packet format separately from the buffer size. Then at initialization time, identify the correct combination and set it up. This is a critical fix for anyone with a newer LT-20. Older devices and non-Earthmate devices should remain unaffected by this change. (If other devices behave in this, uh, unexpected manner, it's now just a simple 1 line change to fix them as well (change the pkt_fmt member for that device). Default behavior with this patch is still to drive the format as per the app-note; of course for Earthmate devices this is overridden. Signed-off-by: Mike Isely <isely@pobox.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: cypress_m8: Feature buffer fixesMike Isely
cypress_m8: Feature buffer fixes From: Mike Isely <isely@pobox.com> Don't hardcode the feature buffer size; use sizeof() instead. That way we can easily specify the size in a single spot. Speaking of the feature buffer size, the Cypress app note (and further testing with a DeLorme Earthmate) suggests that this size should be 5 not 8 bytes. Signed-off-by: Mike Isely <isely@pobox.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: io_ti.c: remove pointless eye-candy in debug statementsAndrew Morton
These strings always come up as false positives whenever I'm doing git-conflict fixups (ie: about 1000 times/day). I don't think the zillion "<" and ">" characters are very useful and removing them makes my life that little bit easier. Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: Add HP hs2300 Broadband Wireless Module to sierra.cStefan Seyfried
Add the HP hs2300 Broadband Wireless Module (relabeled MC8775) USB IDs Signed-off-by: Stefan Seyfried <seife@suse.de> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-24USB: CP2101 Add new device IDsCraig Shelley
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-18drivers: Remove unnecessary inclusions of asm/semaphore.hMatthew Wilcox
None of these files use any of the functionality promised by asm/semaphore.h. It's possible that they rely on it dragging in some unrelated header file, but I can't build all these files, so we'll have fix any build failures as they come up. Signed-off-by: Matthew Wilcox <willy@linux.intel.com>
2008-04-15USB: remove broken usb-serial num_endpoints checkGreg Kroah-Hartman
The num_interrupt_in, num_bulk_in, and other checks in the usb-serial code are just wrong, there are too many different devices out there with different numbers of endpoints. We need to just be sticking with the device ids instead of trying to catch this kind of thing. It broke too many different devices. This fixes a large number of usb-serial devices to get them working properly again. Cc: Oliver Neukum <oliver@neukum.org> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-15USB: option: Add new vendor ID and device ID for AMOI HSDPA modemtang kai
This patch add new vendor ID and device ID for AMOI HSDPA modem. From: tang kai <tangk73@hotmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-15USB: support more Huawei data card product IDsfangxiaozhi
- declare the unusal device for Huawei data card devices in unusual_devs.h - disable the product ID matching for Huawei data card devices in usb_match_device function of driver.c - declare the product IDs in option.c. Signed-off-by: fangxiaozhi <huananhu@huawei.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-15USB: option.c: add more device IDsMatthias Urlichs
Add devices by AMOI and NovatelWireless. Signed-Off-By: Matthias Urlichs <matthias@urlichs.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-15USB: Obscure Maxon BP3-USB Device Support 16d8:6280 for option driverJames Cameron
The modem was detected, the ttyUSB{0,1,2} appeared, a call could be made, and the expected data rate was achieved. Tested for an hour or two, total of 100Mb. I shall do more testing. Signed-off-by: James Cameron <quozl@laptop.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-02USB: Allow initialization of broken keyspan serial adapters.Clark Rawlins
Fixes the keyspan driver after the addition of additional checking of driver requirements introduced in usb-serial.c commit 063a2da8f01806906f7d7b1a1424b9afddebc443. The initialization of the keyspan usb_serial_driver structs were not initializing the num_interrupt_out field and the additional checking was rejecting the end point so the driver wouldn't finish initializing. This commit initializes the fields to NUM_DONT_CARE. It works for the keyspan USA-49WG and doesn't break the USA-19HS which are the two keyspan devices I have to test with. Signed-off-by: Clark Rawlins <clark.rawlins@escient.com> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-02USB: serial: fix regression in Visor/Palm OS module for kernels >= 2.6.24Brad Sawatzky
Fixes a bug/inconsistency revealed by the additional sanity checking in commit 063a2da8f01806906f7d7b1a1424b9afddebc443 introduced in the original 2.6.24 branch. The Handspring Visor / PalmOS 4 device structure defines .num_bulk_out=2 but the usb-serial probe returns num_bulk_out=3, triggering the check in the above commit and forcing a bail out when the device (a Garmin iQue in my case) attempts to connect. The patch bumps the expected number of endpoints to 3. FWIW, this patch will probably solve the following kernel bug report for Treo users (identical symptoms, different model PalmOS units): <http://bugzilla.kernel.org/show_bug.cgi?id=10118> Signed-off-by: Brad Sawatzky <brad+kernel@swatter.net> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-02USB: cp2101: Add identifiers for the Telegesys ETRX2USBFlorian Fainelli
This patch adds support for the Telegesys ETRX2USB which works fine with the cp2101 driver. Signed-off-by: Florian Fainelli <florian.fainelli@telecomint.eu> Tested-by: Xavier Carcelle <xavier.carcelle@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-02USB: serial: ti_usb_3410_5052: Correct TUSB3410 endpoint requirements.Robert Spanton
The changes introduced in commit 063a2da8f01806906f7d7b1a1424b9afddebc443 changed the semantics of the num_interrupt_in, num_interrupt_out, num_bulk_in and num_bulk_out entries of the usb_serial_driver struct to be the number of endpoints the device has when probed. This patch changes the ti_1port_device usb_serial_driver struct to reflect this change. The single port devices only have 1 bulk_out endpoint in their initial configuration, and so this patch changes the number of other types to NUM_DONT_CARE. The same change probably needs doing to the ti_2port_device struct, but I don't have a two port device at hand. Signed-off-by: Robert Spanton <rspanton@zepler.net> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-03-24USB: sierra: add another device idKevin Lloyd
Add support for the MC8775 device to the sierra driver. Signed-off-by: Kevin Lloyd <klloyd@sierrawireless.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-03-24USB: sierra: dma fixesOliver Neukum
while I was adding autosuspend to that driver I noticed a few issues. You were having DMAed buffers as a part of a structure. This will fail on platforms that are not DMA-coherent (arm, sparc, ppc, ...) Please test this patch to fix it. Signed-off-by: Kevin Lloyd <klloyd@sierrawireless.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-03-24USB: pl2303: another product IDMax Arnold
Device like this http://aldiga.com/english/A-100-USB-EDGE10.htm contains Prolific 2303 chip. Actually their site a bit outdated - I have AlDiga AL-11U GSM/GPRS/EDGE modem and it works with pl2303 module after adding corresponding product ID. By default modem uses baud rate 460800. GSM chipset - SIMCom SIM600, quad band 850/900/1800/1900 MHz Device info: T: Bus=04 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 5 Spd=12 MxCh= 0 D: Ver= 1.10 Cls=00(>ifc ) Sub=00 Prot=00 MxPS= 8 #Cfgs= 1 P: Vendor=067b ProdID=0611 Rev= 0.00 C:* #Ifs= 1 Cfg#= 1 Atr=a0 MxPwr=500mA I:* If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=pl2303 E: Ad=81(I) Atr=03(Int.) MxPS= 10 Ivl=1ms E: Ad=02(O) Atr=02(Bulk) MxPS= 64 Ivl=0ms E: Ad=83(I) Atr=02(Bulk) MxPS= 64 Ivl=0ms From: Max Arnold <lwarxx@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-03-10USB: new ftdi_sio device idMirko Bordignon
Here is a patch that adds support for the propox jtagcable II dongle (http://www.propox.com/products/t_117.html): their PID was missing, therefore we were not able to have the device recognized though it uses a standard FTDI chip. Signed-off-by: Mirko Bordignon <mirko.bordignon@ieee.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-03-10USB: option: add novatel device idsDirk DeSchepper
This updates the option driver with a lot more novatel driver ids. From: Dirk DeSchepper <ddeschepper@nvtl.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-03-10USB: cypress_m8: add UPS Powercom (0d9f:0002)Dmitry Shapin
Add support for UPS Powercom USB interface (0d9f:0002) in chip CY7C63723. In my case, this Powercom BNT800AP. Signed-off-by: Dmitry Shapin <shapin@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-03-10USB: fix usb-serial generic recursive lockPete Zaitcev
Nobody should be using the generic usb-serial for anything other than testing. Still, it's not a good thing that it's easy to lock up. There is a traceback from NMI oopser here: https://bugzilla.redhat.com/show_bug.cgi?id=431379 But in short, if a line discipline has a chance to echo anything, input can loop back a write method. So, don't call tty_flip_buffer_push from under a lock taken on write path. Signed-off-by: Pete Zaitcev <zaitcev@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>