android_kernel_xiaomi_sdm845/drivers
Elina Pasheva b9a44bc19f sierra: driver urb handling improvements
[Folded from eight patches into one as the original set according to the
 author "All of the patches need to be applied to obtain a working product"
 so keeping them split seems unhelpful

 Merge fixes done versus other conflicting changes and moved the
 spin_lock_init from open to setup time -- Alan]

Summary of the changes and code re-organization in this patch:

- The memory for urbs is allocated and urbs are submitted only for the active
  interfaces (instead of pre-allocating these for all interfaces). This will
  save memory especially in the case of using composite devices.
- The code has been re-organized and functionality has been extracted from
  sierra_startup(), sierra_shutdown(), sierra_open(), sierra_close() and added
  in helper functions sierra_release_urb(), sierra_stop_rx_urbs(),
  sierra_submit_rx_urbs() and sierra_setup_urb()

- Added function sierra_release_urb() to free an urb and its transfer
buffer.
- Removed unecessary include file reference and comment.
- Added function sierra_stop_rx_urbs() that takes care of the release of
receive and interrupt urbs. This function is to be called by sierra_close()
whenever an interface is de-activated.
- Added new function sierra_submit_rx_urbs() that handles the submission of
receive urbs and interrupt urbs (if any) during the interface activation.
This function is to be called by sierra_open(). Added a second parameter to
pass the memory allocation (as suggested by Oliver Neukum) so that this
function can be used in post_reset() and resume().
- Added new function sierra_setup_urb() that contains the functionality to
allocate an urb, fill bulk urb using the supplied memory allocation flag
and release urb upon error. Added parameter so that the caller pass the
memory allocation flag for flexibility.
- Moved sierra_close() before sierra_open() to resolve dependencies
introduced by the code reorganization.
- Modified sierra_close() to call sierra_stop_rx_urbs() and
sierra_release_urb() functions added in previous patch.
- Modified sierra_open() to call sierra_setup_urb() and sierra_submit_rx_urbs()
functions; note urbs are allocated and submitted for each activated interface.
- Modified sierra_startup() so that allocation of urbs happens whenever an
interface is activated (urb allocation is moved to sierra_open()).
- Modified sierra_shutdown() so that urbs are freed whenever an interface is
de-activated (urb freeing moved to sierra_close() as shown in previous patch
from the series)
- Removed unecessary data structure from sierra_port_private_data
- Suppress an entry in logs by not re-submitting an urb when usb_submit_urb()
returns -EPERM, as this shows that usb_kill_urb() is running (as suggested by
Oliver Neukum)

Signed-off-by: Elina Pasheva <epasheva@sierrawireless.com>
Signed-off-by: Alan Cox <alan.cox@linux.intel.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-06-11 08:51:07 -07:00
..
accessibility
acpi cpumask: alloc zeroed cpumask for static cpumask_var_ts 2009-06-09 22:30:27 +09:30
amba
ata pata_netcell: Fix typo 2009-06-08 09:12:28 -07:00
atm Replace all DMA_nBIT_MASK macro with DMA_BIT_MASK(n) 2009-04-13 15:04:33 -07:00
auxdisplay
base Driver Core: do not oops when driver_unregister() is called for unregistered drivers 2009-05-28 14:24:07 -07:00
block xen/blkfront: fix warning when deleting gendisk on unplug/shutdown 2009-05-19 08:27:42 +02:00
bluetooth tty: fix bluetooth scribbling on low latency flags 2009-06-11 08:51:05 -07:00
cdrom cdrom: beyond ARRAY_SIZE of viocd_diskinfo 2009-05-20 08:42:06 +02:00
char tty: Untangle termios and mm mutex dependencies 2009-06-11 08:51:06 -07:00
clocksource clocksource: pass clocksource to read() callback 2009-04-21 13:41:47 -07:00
connector
cpufreq cpumask: alloc zeroed cpumask for static cpumask_var_ts 2009-06-09 22:30:27 +09:30
cpuidle
crypto Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 2009-05-17 15:48:05 -07:00
dca
dio
dma Merge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6 2009-05-30 07:57:44 -07:00
edac edac: AMD8111 & AMD8131 Kconfig fixup 2009-05-29 08:40:03 -07:00
eisa
firewire
firmware ibft: fix the display of a few fields in the NIC attribute structure in sysfs 2009-05-02 15:36:10 -07:00
gpio
gpu Revert "drm: don't associate _DRM_DRIVER maps with a master" 2009-06-05 10:21:52 -07:00
hid HID: add NOGET quirk for devices from CH Products 2009-05-11 17:09:21 +02:00
hwmon hwmon: (lm78) Add missing __devexit_p() 2009-06-01 13:46:49 +02:00
i2c Merge branch 'i2c-for-2630-rc5' of git://aeryn.fluff.org.uk/bjdooks/linux 2009-05-12 11:21:51 -07:00
ide pdc202xx_old: fix resetproc() method 2009-06-07 13:52:50 +02:00
idle i7300_idle: allow testing on i5000-series hardware w/o re-compile 2009-05-28 20:52:40 -04:00
ieee1394 dma-mapping: replace all DMA_32BIT_MASK macro with DMA_BIT_MASK(32) 2009-04-07 08:31:11 -07:00
infiniband Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband 2009-05-13 16:31:12 -07:00
input Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input 2009-05-29 08:48:25 -07:00
isdn gigaset: beyond ARRAY_SIZE of iwb->data 2009-05-21 15:04:15 -07:00
leds leds: just ignore invalid GPIOs in leds-gpio 2009-04-08 14:13:48 +01:00
lguest lguest: fix on Intel when KVM loaded (unhandled trap 13) 2009-05-26 12:13:11 -07:00
macintosh Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6 2009-04-24 08:16:05 -07:00
mca
md md/raid5: fix bug in reshape code when chunk_size decreases. 2009-06-09 16:32:22 +10:00
media ivtv: Fix PCI DMA direction 2009-06-05 08:05:23 -07:00
memstick dma-mapping: replace all DMA_32BIT_MASK macro with DMA_BIT_MASK(32) 2009-04-07 08:31:11 -07:00
message scsi: mpt: suppress debugobjects warning 2009-04-21 13:41:50 -07:00
mfd mfd: pcf50633: fix unsafe disable_irq() 2009-05-19 22:22:28 +02:00
misc [SCSI] ses: fix problems caused by empty SES provided name 2009-05-15 12:20:57 -04:00
mmc sdhci-of: Fix the wrong accessor to HOSTVER register 2009-06-03 21:56:22 +02:00
mtd mtd: davinci nand: update clock naming 2009-06-05 11:54:17 -07:00
net r8169: fix crash when large packets are received 2009-06-09 04:01:02 -07:00
nubus
of
oprofile oprofile: fix cpu buffer size 2009-05-07 17:28:59 +02:00
parisc parport: Fix various uses of parport_pc 2009-04-14 08:48:50 -07:00
parport parport_pc: clean up the modified while loops using for 2009-06-11 08:51:03 -07:00
pci PCI: use fixed-up device class when configuring device 2009-06-04 11:29:43 +01:00
pcmcia [ARM] 5458/1: pcmcia: pxa2xx-sharpsl: check if we do have Scoop config 2009-04-23 23:25:40 +01:00
platform eeepc-laptop: unregister_rfkill_notifier on failure 2009-05-14 11:28:27 -04:00
pnp ACPI: suspend: don't let device _PS3 failure prevent suspend 2009-05-08 00:22:29 -04:00
power Merge git://git.infradead.org/battery-2.6 2009-04-08 17:45:02 -07:00
ps3
rapidio dma-mapping: replace all DMA_32BIT_MASK macro with DMA_BIT_MASK(32) 2009-04-07 08:31:11 -07:00
regulator regulator: da903x: add missing __devexit_p() 2009-05-18 11:21:10 +01:00
rtc [ARM] 5519/1: amba probe: pass "struct amba_id *" instead of void * 2009-05-20 23:26:51 +01:00
s390 [SCSI] zfcp: Fix oops when port disappears 2009-04-27 10:07:37 -05:00
sbus sbus: changed ioctls to unlocked 2009-04-14 19:46:19 -07:00
scsi [SCSI] mpt2sas: fix driver version inconsistency 2009-05-18 14:17:17 -05:00
serial timbuart: Fix the termios logic 2009-06-11 08:51:06 -07:00
sh sh: intc: Added resume from hibernation support to the intc 2009-04-06 08:55:19 -07:00
sn dma-mapping: replace all DMA_64BIT_MASK macro with DMA_BIT_MASK(64) 2009-04-07 08:31:10 -07:00
spi pxa2xx_spi: prevent panic case setup() fails 2009-05-12 14:11:34 -07:00
ssb SSB: BCM47xx: Export ssb_watchdog_timer_set 2009-06-08 16:57:50 +01:00
staging Staging: comedi: David doesn't want to get comedi patches 2009-05-08 19:39:28 -07:00
tc
telephony
thermal thermal: fix off-by-1 error in trip point trigger condition 2009-05-14 13:40:53 -04:00
uio UIO: fix specific device driver missing statement for depmod 2009-04-16 16:17:11 -07:00
usb sierra: driver urb handling improvements 2009-06-11 08:51:07 -07:00
uwb dma-mapping: replace all DMA_32BIT_MASK macro with DMA_BIT_MASK(32) 2009-04-07 08:31:11 -07:00
video atmel_lcdfb: correct fifo size for some products 2009-05-29 08:40:03 -07:00
virtio virtio: fix suspend when using virtio_balloon 2009-04-19 23:14:01 +09:30
w1
watchdog [ARM] 5460/1: Orion: reduce namespace pollution 2009-04-23 23:25:41 +01:00
xen [IA64] xen_domu_defconfig: fix build issues/warnings 2009-05-05 11:43:13 -07:00
zorro
Kconfig
Makefile V4L/DVB (11561a): move media after i2c 2009-04-29 15:41:13 -03:00