aboutsummaryrefslogtreecommitdiff
path: root/drivers/usb
AgeCommit message (Collapse)Author
2007-07-12USB: sierra: cleanup the startup and shutdown pathGreg Kroah-Hartman
This removes the ugly code that was copied from the keyspan driver and allocates the in urbs in a much shorter code path that can be understood easier. Also turned off the interrupt urb when no port was open as it's not nice to keep the bus busy for no good reason at all (this should be a power savings.) All in all, this saved over 40 lines of code and cleaned things up better. Cc: Kevin Lloyd <linux@sierrawireless.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: sierra: remove incorrect usage of the urb status fieldGreg Kroah-Hartman
You can't rely on the fact that the status really is correct like it was. Also simplified the write path and now we allocate the urb and data on the fly, instead of trying to do that really odd timeout check which I am guessing doesn't really work properly. This should speed up the device by keeping the hardware queue full easier. As a benefit, this reduces the size of the driver. Cc: Kevin Lloyd <linux@sierrawireless.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: whiteheat: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: visor: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: ti_usb_3410_5052: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Al Borchers <alborchers@steinerpoint.com> Cc: Peter Berger <pberger@brimson.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: sierra: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Kevin Lloyd <linux@sierrawireless.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: safe_serial: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Stuart Lynne <sl@lineo.com> Cc: Tom Rushworth <tbr@lineo.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: pl2303: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: oti6858: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: option: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Matthias Urlichs <smurf@smurf.noris.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: omninet: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: navman: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: mos7840: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Paul Schroeder <pschroeder@uplogix.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: mos7720: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: VijayaKumar G.N. <vijaykumar@aspirecom.net> Cc: AjayKumar <ajay@aspirecom.net> Cc: Gurudeva N. <gurudev@aspirecom.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: mct_u232: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Wolfgang Grandegger <wolfgang@ces.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: kobil_sct: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Thomas Wahrenbruch <linuxusb@kobil.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: kl5kusb105: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Utz-Uwe Haus <haus@uuhaus.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: keyspan_pda: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: keyspan: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: ir-usb: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Gary Brubaker <xavyer@ix.netcom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: ipw: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Roelf Diedericks <roelfd@inet.co.za> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: ipaq: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Ganesh Varadarajan <ganesh@veritas.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: io_ti: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Al Borchers <alborchers@steinerpoint.com> Cc: Peter Berger <pberger@brimson.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: io_edgeport: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Al Borchers <alborchers@steinerpoint.com> Cc: Peter Berger <pberger@brimson.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: generic: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: garmin_gps: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Hermann Kneissel <herkne@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: ftdi_sio: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Kuba Ober <kuba@mareimbrium.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: empeg: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Gary Brubaker <xavyer@ix.netcom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: digi_acceleport: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Peter Berger <pberger@brimson.com> Cc: Al Borchers <borchers@steinerpoint.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: cypress_m8: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Lonnie Mendez <dignome@gmail.com> Cc: Neil Whelchel <koyama@firstlight.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: cyberjack: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: <support@reiner-sct.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: belkin_sa: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: airprime: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: serial: aircable: clean up urb->status usageGreg Kroah-Hartman
This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: fix up license wording on some of my usb-serial driversGreg Kroah-Hartman
Also update the copyright date on the pl2303 driver, as it was out of date. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12usb: free DMA mappings if enqueue failsPete Zaitcev
This patch releases DMA resources if enqueue fails in the HCD. Linux had this bug ever since we converted from virt_to_bus for 2.4. It is difficult to hit. A user would need a significant memory pressure or some other unusual condition. It was reported to me by IBM. They ran a management application for RSA II adapters which sent Bulk requests to an Interrupt endpoint. Submissions got rejected by HCD due to an invalid interval value and the swiotlb pool became depleted in the matter of hours. We fixed the invalid interval issue in devio.c separately, but this seems to be a bug worth fixing as well. Signed-off-by: Pete Zaitcev <zaitcev@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: Handle bogus low-speed Bulk endpointsAlan Stern
A noticeable number of low-speed devices mistakenly include descriptors for Bulk endpoints, which is forbidden by the USB spec. In an attempt to make such devices more usable, this patch (as924) converts the descriptors to Interrupt with an interval of 1 ms. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12synchronization in usb_serial_putBenny Halevy
I think there is a race between usb_serial_put() and usb_serial_get_by_index() (and get_free_serial()) with regards to handling the serial port refcount. usb_serial_get_by_index() gets a reference on the serial port under table_lock while return_serial releases all the returned ports from the table under the same lock. However, the table_lock is not taken around the call to kref_put, theoretically allowing to sneak in and grab a reference after kref_put has already determined that the reference count is zero (and before calling destroy_serial) causing use after free. Signed-off-by: Benny Halevy <bhalevy@ns1.bhalevy.com> Cc: Oliver Neukum <oneukum@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: io_ti: sleep with spinlock held detected by automatic toolOliver Neukum
this fixes the sleep found with the automatic tool. Signed-off-by: Oliver Neukum <oneukum@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12ehci-hub: improved over-current recoveryChristian Engelmayer
According to the USB Specification Revision 2.0 chapter 11.12.5 a hub experiencing an over-current condition must place all affected ports in the powered-off state. It seems that some root hubs need port power to be cycled by software in order to get back to normal functionality after an over-current condition ... like the EHCI implementation on an MPC8343E. Signed-off-by: Christian Engelmayer <christian.engelmayer@frequentis.com> Signed-off-by: David Brownell <david-b@pacbell.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: usb host side can be configured given PCMCIADavid Brownell
Platforms with PCMCIA support can implement host-side USB with "sl811_cs", so make sure this menu shows up on platforms with PCMCIA. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: usb-storage: use kthread_stop() for the control threadAlan Stern
This patch (as923) makes usb-storage's control thread use kthread_should_stop()/kthread_stop(). The scanning thread can't be similarly converted until the core kthread implementation allows threads to call do_exit(). The advantage of this change is that we can now be certain the control thread has terminated before storage_disconnect() returns. This will simplify the locking requirements when autosuspend support is added. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Matthew Dharm <mdharm-usb@one-eyed-alien.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB Gadget driver for Samsung s3c2410 ARM SoCArnaud Patard
This patch adds the support for the Usb Device Controller on Samsung S3C24xx SoCs. This driver passes all tests from testusb (including #13) and has been tested on S3C2410, S3C24212, and S3C2440 SoCs. Whitespace updates, minor cleanups by David Signed-off-by: Arnaud Patard <arnaud.patard@rtp-net.org> Signed-off-by: Ben Dooks <ben-linux@fluff.org> Cc: Herbert Pƶtzl <herbert@13thfloor.at> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: PS3: USB system-bus reworkGeoff Levand
USB HCD glue updates to reflect the new PS3 unifed device support. - Fixed remove() routine. - Added shutdown() routine. - Added request_mem_region() call. - Fixed MODULE_ALIAS(). - Made a proper fix for the hack done to support muti-platform in commit 48fda45120a819ca40cadc50144b55bff1c4c78d. Signed-off-by: Geoff Levand <geoffrey.levand@am.sony.com> Cc: Paul Mackerras <paulus@samba.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: option: fix usage of urb->status abuseAlan Stern
Might fix bug 8561 On Mon, 4 Jun 2007, Paulo Pereira wrote: > The patch that you send is not resolving the problem... :( > I stil have Kernel panic after 45/60 min of work with Ktorrent/Amule... > > The Drump is: > > Call Trace: > [<c055fb36>] usb_hcd_submit+0xb1/0x763 > [<f9276488>] ipt_do_table+0x2c7/0x2ef [ip_tables] > [<f929a6d7>] nf_ct_deliver_cached_events+0x41/0x96 [nf_conntrak] > [<f9288254>] ipv4_confirm+0x36/0c3b [nf_conntrack_ipv4] > [<c05ce7c2>] tcp_v4_rcv+0x827/0x899 > [<c05afcc0>] nf_hook_slow+0x4d/0xb5 > [<c042826f>] irq_enter+0x19/0x23 > [<c042826f>] irq_enter+0x19/0x23 > [<c040794c>] do_IRQ+0xbd/0xd1 > [<f90893c9>] option_write+0xa7/0xef [option] Okay, from this it looks like there's a problem in the option.c serial driver. Glancing at the code, it's obvious why: The thing totally abuses the USB API. Try applying this patch; it should help. From: Alan Stern <stern@rowland.harvard.edu> Cc: Paulo Pereira <pfmp.404@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: fsl_usb2_udc: Get max ep number from DCCPARAMS registerLi Yang
Currently the driver is expecting max ep number in platform data which isn't passing this information. This patch fix the problem by reading it from DCCPARAMS(Device Controller Capability Parameters) register. The change also need some reordering of the probe code. Signed-off-by: Li Yang <leoli@freescale.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: fsl_usb2_udc: replace deprecated irq flagLi Yang
Signed-off-by: Li Yang <leoli@freescale.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: add power/persist device attributeAlan Stern
This patch (as920) adds an extra level of protection to the USB-Persist facility. Now it will apply by default only to hubs; for all other devices the user must enable it explicitly by setting the power/persist device attribute. The disconnect_all_children() routine in hub.c has been removed and its code placed inline. This is the way it was originally as part of hub_pre_reset(); the revised usage in hub_reset_resume() is sufficiently different that the code can no longer be shared. Likewise, mark_children_for_reset() is now inline as part of hub_reset_resume(). The end result looks much cleaner than before. The sysfs interface is updated to add the new attribute file, and there are corresponding documentation updates. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: unify reset_resume and normal resumeAlan Stern
This patch (as919) unifies the code paths used for normal resume and for reset-resume. Earlier I had failed to note a section in the USB spec which requires the host to resume a suspended port before resetting it if the attached device is enabled for remote wakeup. Since the port has to be resumed anyway, we might as well reuse the existing code. The main changes are: usb_reset_suspended_device() is eliminated. usb_root_hub_lost_power() is moved down next to the hub_reset_resume() routine, to which it is logically related. finish_port_resume() does a port reset() if the device's reset_resume flag is set. usb_port_resume() doesn't check whether the port is initially enabled if this is a USB-Persist sort of resume. Code to perform the port reset is added to the resume pathway for the non-CONFIG_USB_SUSPEND case. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-12USB: add reset_resume methodAlan Stern
This patch (as918) introduces a new USB driver method: reset_resume. It is called when a device needs to be reset as part of a resume procedure (whether because of a device quirk or because of the USB-Persist facility), thereby taking over a role formerly assigned to the post_reset method. As a consequence, post_reset no longer needs an argument indicating whether it is being called as part of a reset-resume. This separation of functions makes the code clearer. In addition, the pre_reset and post_reset method return types are changed; they now must return an error code. The return value is unused at present, but at some later time we may unbind drivers and re-probe if they encounter an error during reset handling. The existing pre_reset and post_reset methods in the usbhid, usb-storage, and hub drivers are updated to match the new requirements. For usbhid the post_reset routine is also used for reset_resume (duplicate method pointers); for the other drivers a new reset_resume routine is added. The change to hub.c looks bigger than it really is, because mark_children_for_reset_resume() gets moved down next to the new hub_reset_resume() routine. A minor change to usb-storage makes the usb_stor_report_bus_reset() routine acquire the host lock instead of requiring the caller to hold it already. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Jiri Kosina <jkosina@suse.cz> CC: Matthew Dharm <mdharm-usb@one-eyed-alien.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>