linux-kernel-test/drivers
Stefan Becker de85422b94 USB: fix interrupt disabling for HCDs with shared interrupt handlers
USB: fix interrupt disabling for HCDs with shared interrupt handlers

As has been discussed several times on LKML, IRQF_SHARED | IRQF_DISABLED
doesn't work reliably, i.e. a shared interrupt handler CAN'T be certain to
be called with interrupts disabled. Most USB HCD handlers use IRQF_DISABLED
and therefore havoc can break out if they share their interrupt with a
handler that doesn't use it.

On my test machine the yenta_socket interrupt handler (no IRQF_DISABLED)
was registered before ehci_hcd and one uhci_hcd instance. Therefore all
usb_hcd_irq() invocations for ehci_hcd and for one uhci_hcd instance
happened with interrupts enabled. That led to random lockups as USB core
HCD functions that acquire the same spinlock could be called twice
from interrupt handlers.

This patch updates usb_hcd_irq() to always disable/restore interrupts.
usb_add_hcd() will silently remove any IRQF_DISABLED requested from HCD code.

Signed-off-by: Stefan Becker <stefan.becker@nokia.com>
Cc: stable <stable@kernel.org>
Acked-by: David Brownell <david-b@pacbell.net>
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-07-03 18:20:37 -07:00
..
accessibility
acorn/char
acpi dock: bay: Don't call acpi_walk_namespace() when ACPI is disabled. 2008-06-26 01:55:27 -04:00
amba
ata Merge git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6 2008-06-20 12:46:47 -07:00
atm atm: [he] send idle cells instead of unassigned when in SDH mode 2008-06-16 17:21:27 -07:00
auxdisplay
base dev_set_name: fix missing kernel-doc 2008-06-11 16:50:40 -07:00
block cciss: add new hardware support 2008-06-12 18:05:40 -07:00
bluetooth
cdrom
char tty: Fix inverted logic in send_break 2008-07-02 19:21:48 -07:00
clocksource
connector CONNECTOR: add a proc entry to list connectors 2008-06-27 20:03:24 -07:00
cpufreq Merge branch 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/davej/cpufreq 2008-06-09 11:27:55 -07:00
cpuidle cpuidle acpi driver: fix oops on AC<->DC 2008-06-11 19:13:45 -04:00
crypto
dca
dio
dma
edac
eisa
firewire firewire: fw-sbp2: fix parsing of logical unit directories 2008-06-27 20:55:00 +02:00
firmware edd: fix incorrect return of 1 from module_init 2008-06-06 11:29:09 -07:00
gpio
hid
hwmon hwmon: (lm75) sensor reading bugfix 2008-06-19 06:50:32 -04:00
i2c I2C: S3C2410: Add MODULE_ALIAS() for s3c2440 device. 2008-07-01 14:30:38 +01:00
ide ide: fix /proc/ide/ide?/mate reporting 2008-06-30 20:14:45 +02:00
ieee1394 ieee1394: Kconfig menu touch-up 2008-06-19 00:12:36 +02:00
infiniband IB/mthca: Clear ICM pages before handing to FW 2008-06-23 09:29:58 -07:00
input drivers/input/ff-core.c needs <linux/sched.h> 2008-07-02 18:40:08 -07:00
isdn drivers/isdn/sc/ioctl.c: add missing kfree 2008-06-12 18:05:41 -07:00
leds
lguest x86: fix NULL pointer deref in __switch_to 2008-06-20 13:26:18 +02:00
macintosh [POWERPC] Build fix for drivers/macintosh/mediabay.c 2008-06-16 15:00:47 +10:00
mca
md Merge git://git.kernel.org/pub/scm/linux/kernel/git/agk/linux-2.6-dm 2008-07-02 18:55:17 -07:00
media V4L/DVB (8178): uvc: Fix compilation breakage for the other drivers, if uvc is selected 2008-07-02 08:58:15 -03:00
memstick
message
mfd
misc thinkpad-acpi: fix LED handling on older ThinkPads 2008-06-11 19:13:45 -04:00
mmc mmc: wbsd: initialize tasklets before requesting interrupt 2008-06-12 18:05:41 -07:00
mtd Merge git://git.infradead.org/~dwmw2/mtd-2.6.26 2008-06-06 11:31:18 -07:00
net hostap: fix sparse warnings 2008-06-30 15:43:52 -04:00
nubus
of rtc-ds1374: rename device to just "ds1374" 2008-06-06 11:29:10 -07:00
oprofile
parisc
parport
pci PCI: acpiphp: cleanup notify handler on all root bridges 2008-07-02 11:27:30 -07:00
pcmcia
pnp PNPACPI: use _CRS IRQ descriptor length for _SRS 2008-06-11 19:13:46 -04:00
power power_supply: Fix race in power_supply_uevent 2008-06-10 02:13:51 +04:00
ps3
rapidio
rtc [ARM] 5109/1: Mark rtc sa1100 driver as wakeup source before registering it 2008-06-22 14:32:12 +01:00
s390 Merge branch 'kvm-updates-2.6.26' of git://git.kernel.org/pub/scm/linux/kernel/git/avi/kvm 2008-06-11 10:35:44 -07:00
sbus
scsi [SCSI] esp: tidy up target reference counting 2008-06-25 12:36:13 -05:00
serial Blackfin Serial Driver: Use timer to poll CTS PIN instead of workqueue. 2008-06-19 17:46:39 +08:00
sh
sn
spi spi: fix refcount-related spidev oops-on-rmmod 2008-06-06 11:29:08 -07:00
ssb ssb: Fix coherent DMA mask for PCI devices 2008-06-13 16:14:52 -04:00
tc
telephony
thermal thermal: Create CONFIG_THERMAL_HWMON=n 2008-06-25 19:25:42 -04:00
uio
usb USB: fix interrupt disabling for HCDs with shared interrupt handlers 2008-07-03 18:20:37 -07:00
video [ARM] 5117/1: pxafb: fix __devinit/exit annotations 2008-06-25 18:50:14 +01:00
virtio virtio: Complete feature negotation before updating status 2008-06-15 13:46:16 -07:00
w1
watchdog Revert "[WATCHDOG] hpwdt: Add CFLAGS to get driver working" 2008-06-24 13:09:26 +00:00
xen xen: Use wmb instead of rmb in xen_evtchn_do_upcall(). 2008-06-20 14:56:30 +02:00
zorro
Kconfig
Makefile