linux/arch/avr32
Thomas Gleixner bf54da7d3a avr32/at32ap: Fix race in installing chained IRQ handler
Fix a race where a pending interrupt could be received and the handler
called before the handler's data has been setup, by converting to
irq_set_chained_handler_and_data().

Search and conversion was done with coccinelle:

@@
expression E1, E2, E3;
@@
(
-if (irq_set_chained_handler(E1, E3) != 0)
-   BUG();
|
-irq_set_chained_handler(E1, E3);
)
-irq_set_handler_data(E1, E2);
+irq_set_chained_handler_and_data(E1, E3, E2);

@@
expression E1, E2, E3;
@@
(
-if (irq_set_chained_handler(E1, E3) != 0)
-   BUG();
...
|
-irq_set_chained_handler(E1, E3);
...
)
-irq_set_handler_data(E1, E2);
+irq_set_chained_handler_and_data(E1, E3, E2);

Reported-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Julia Lawall <Julia.Lawall@lip6.fr>
Cc: Haavard Skinnemoen <hskinnemoen@gmail.com>
Cc: Hans-Christian Egtvedt <egtvedt@samfundet.no>
2015-06-25 11:57:52 +02:00
..
boards ARM: SoC driver changes for 3.17 2014-08-08 11:34:32 -07:00
boot avr32: fix out-of-range jump in large kernels 2013-11-20 09:53:21 +01:00
configs avr32: update all default configurations 2015-02-09 15:27:45 +01:00
include Merge branch 'x86-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2015-06-22 17:59:09 -07:00
kernel arch: Remove exec_domain from remaining archs 2015-04-12 21:03:30 +02:00
lib ARCH: drivers remove __dev* attributes. 2013-01-03 15:57:13 -08:00
mach-at32ap avr32/at32ap: Fix race in installing chained IRQ handler 2015-06-25 11:57:52 +02:00
mm mm/fault, arch: Use pagefault_disable() to check for disabled pagefaults in the handler 2015-05-19 08:39:15 +02:00
oprofile oprofilefs_create_...() do not need superblock argument 2013-09-03 22:52:48 -04:00
Kconfig Remove GENERIC_HARDIRQ config option 2013-09-13 15:09:52 +02:00
Kconfig.debug [AVR32] Include instrumentation menu 2008-01-25 08:31:40 +01:00
Makefile avr32: Makefile: add '-D__linux__' flag for gcc-4.4.7 use 2014-02-17 11:24:43 +01:00