alistair23-linux/drivers
Javier Martinez Canillas fac7fa162a gpio/omap: auto-setup a GPIO when used as an IRQ
The OMAP GPIO controller HW requires a pin to be configured in GPIO
input mode in order to operate as an interrupt input. Since drivers
should not be aware of whether an interrupt pin is also a GPIO or not,
the HW should be fully configured/enabled as an IRQ if a driver solely
uses IRQ APIs such as request_irq(), and never calls any GPIO-related
APIs. As such, add the missing HW setup to the OMAP GPIO controller's
irq_chip driver.

Since this bypasses the GPIO subsystem we have to ensure that another
driver won't be able to request the same GPIO pin that is used as an
IRQ and set its direction as output. Requesting the GPIO and setting
its direction as input is allowed though.

This fixes smsc911x ethernet support for tobi and igep OMAP3 boards
and OMAP4 SDP SPI based ethernet that use a GPIO as an interrupt line.

Cc: stable@vger.kernel.org
Acked-by: Stephen Warren <swarren@nvidia.com>
Tested-by: George Cherian <george.cherian@ti.com>
Tested-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Tested-by: Lars Poeschel <poeschel@lemonage.de>
Reviewed-by: Kevin Hilman <khilman@linaro.org>
Tested-by: Kevin Hilman <khilman@linaro.org>
Acked-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Acked-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2013-10-01 13:16:02 +02:00
..
accessibility
acpi ACPI and power management fixes for 3.12-rc1 2013-09-12 11:22:45 -07:00
amba
ata
atm
auxdisplay
base thp: account anon transparent huge pages into NR_ANON_PAGES 2013-09-12 15:38:03 -07:00
bcma
block Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
bluetooth
bus
cdrom
char Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
clk
clocksource Merge branch 'timers/core' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2013-09-16 16:10:26 -04:00
connector
cpufreq Merge branch 'pm-cpufreq' 2013-09-12 13:04:11 +02:00
cpuidle ACPI and power management fixes for 3.12-rc1 2013-09-12 11:22:45 -07:00
crypto
dca
devfreq
dio
dma Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
edac
eisa
extcon
firewire
firmware firmware/dmi_scan: drop OOM messages 2013-09-11 15:58:51 -07:00
fmc
gpio gpio/omap: auto-setup a GPIO when used as an IRQ 2013-10-01 13:16:02 +02:00
gpu Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs 2013-09-12 15:01:38 -07:00
hid Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
hsi
hv
hwmon hwmon: (k10temp) remove unnecessary pci_set_drvdata() 2013-09-12 08:17:40 -07:00
hwspinlock
i2c Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
ide
idle
iio Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
infiniband Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
input Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input 2013-09-15 07:13:39 -04:00
iommu IOMMU Updates for Linux v3.12 2013-09-12 11:29:26 -07:00
ipack
irqchip
isdn
leds Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/linux-leds 2013-09-12 11:35:33 -07:00
lguest
macintosh
mailbox
md Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs 2013-09-12 15:01:38 -07:00
media Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
memory
memstick memstick: add support for legacy memorysticks 2013-09-11 15:59:35 -07:00
message
mfd Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
misc Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
mmc Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
mtd Just a single fastmap fix plus a regression fix. 2013-09-16 15:37:52 -04:00
net Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus 2013-09-15 17:45:52 -04:00
nfc
ntb
nubus
of Merge branch 'for-v3.12-fix' of git://git.linaro.org/people/mszyprowski/linux-dma-mapping 2013-09-11 19:11:59 -07:00
oprofile
parisc
parport
pci Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
pcmcia
pinctrl
platform Merge branch 'for_linus' of git://cavan.codon.org.uk/platform-drivers-x86 2013-09-15 17:42:59 -04:00
pnp pnp: change pnp bus pm_ops to invoke pnp driver dev_pm_ops if specified 2013-09-11 15:58:15 -07:00
power Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
pps Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
ps3
ptp
pwm
rapidio
regulator
remoteproc
reset
rpmsg
rtc rtc: simplify devm_request_mem_region/devm_ioremap 2013-09-11 15:58:59 -07:00
s390 s390/vmcore: use vmcore for zfcpdump 2013-09-11 15:59:15 -07:00
sbus
scsi SCSI misc on 20130915 2013-09-15 17:41:30 -04:00
sfi
sh
sn
spi Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
ssb
staging Merge git://git.kvack.org/~bcrl/aio-next 2013-09-13 10:55:58 -07:00
target Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending 2013-09-12 16:11:45 -07:00
tc
thermal
tty Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
uio
usb Merge git://git.kvack.org/~bcrl/aio-next 2013-09-13 10:55:58 -07:00
uwb
vfio
vhost Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending 2013-09-12 16:11:45 -07:00
video Bye, bye, WfW flag 2013-09-11 19:55:12 -07:00
virt
virtio
vlynq
vme
w1 Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
watchdog Merge git://www.linux-watchdog.org/linux-watchdog 2013-09-12 08:45:53 -07:00
xen Bug-fixes: 2013-09-12 11:28:24 -07:00
zorro
Kconfig
Makefile