linux-stable/arch/m68k
Thomas Gleixner 09c5cb942f m68k/psc: 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: Joshua Thompson <funaho@jurai.org>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: linux-m68k@lists.linux-m68k.org
2015-06-25 11:57:54 +02:00
..
68000 m68k: fix crufty 68000 and 68360 intro comments 2014-09-29 09:18:35 +10:00
68360 arch: m68k: 68360: config: Remove unused function 2015-02-03 14:16:23 +10:00
amiga m68k/amiga: Convert printk(foo to pr_foo() 2014-05-28 10:11:54 +02:00
apollo m68k/apollo: Convert printk to pr_foo() 2014-05-28 10:11:55 +02:00
atari m68k/atari: Remove obsolete IRQ_TYPE_* 2015-01-15 13:44:51 +01:00
bvme6000 m68k/UAPI: Use proper types (endianness/size) in <asm/bootinfo*.h> 2013-11-26 11:09:21 +01:00
coldfire Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu 2015-04-20 10:12:29 -07:00
configs m68k/defconfig: Update defconfigs for v4.0-rc1 2015-03-15 10:24:48 +01:00
emu Merge branch 'for-3.14/core' of git://git.kernel.dk/linux-block 2014-01-30 11:19:05 -08:00
fpsp040
hp300 m68k/hp300: Convert printk to pr_foo() 2014-05-28 10:11:55 +02:00
ifpsp060
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 Merge branch 'exec_domain_rip_v2' of git://git.kernel.org/pub/scm/linux/kernel/git/rw/misc 2015-04-15 13:53:55 -07:00
lib m68k: Remove FSF address 2015-03-15 10:23:30 +01:00
mac m68k/psc: Fix race in installing chained IRQ handler 2015-06-25 11:57:54 +02:00
math-emu m68k/math-emu: unsigned issue, 'unsigned long' will never be less than zero 2013-06-24 19:44:19 +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
mvme16x m68k/mvme16x: rtc - Don't use module_init in non-modular code 2015-01-11 11:38:41 +01:00
mvme147 m68k/mvme147: config.c - Remove unused functions 2015-01-11 11:38:45 +01:00
q40 m68k: Mark functions only called from setup_arch() __init 2013-11-26 11:08:54 +01:00
sun3 sun3_scsi: Convert to platform device 2014-11-20 09:11:15 +01:00
sun3x m68k: Remove superfluous inclusions of <asm/bootinfo.h> 2013-11-26 11:09:22 +01:00
tools/amiga
install.sh
Kconfig m68k: mark PMD folded and expose number of page table levels 2015-04-14 16:49:02 -07:00
Kconfig.bus
Kconfig.cpu
Kconfig.debug m68k: Multi-platform EARLY_PRINTK 2014-05-28 10:10:04 +02:00
Kconfig.devices Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/linux-m68k 2014-10-08 05:40:17 -04:00
Kconfig.machine m68k: remove 16 unused boards in Kconfig.machine 2013-08-26 16:51:14 +10:00
Makefile m68k: move non-mmu 68360 platform code 2014-09-29 09:18:35 +10:00