]> git.baikalelectronics.ru Git - kernel.git/commit
[media] media: rc: nuvoton-cir: fix interrupt handling
authorHeiner Kallweit <hkallweit1@gmail.com>
Wed, 30 Dec 2015 16:45:51 +0000 (14:45 -0200)
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>
Mon, 1 Feb 2016 10:51:33 +0000 (08:51 -0200)
commit5bf3fdca3ea43dc37e7df262d77ced87da189a64
tree6ed50b0f397471a2ae7604929af50dfa5a3cd131
parent1015e100ec7dafe2cbb63194a87db7784cca820c
[media] media: rc: nuvoton-cir: fix interrupt handling

Only handle an interrupt if at least one combination of event bit
and related interrupt bit is set.
Previously it was just checked that at least one event bit and
at least one interrupt bit are set.

This fixes issues like the following which was caused by
interrupt sharing:
An interrupt intended for nvt_cir_isr was handled by nvt_cir_wake_isr
first and because status bit CIR_WAKE_IRSTS_IR_PENDING was set
the wake fifo was accidently cleared.

This patch also fixes the bug that nvt_cir_wake_isr returned IRQ_HANDLED
even if it detected that the (shared) interrupt was meant for another
handler.

Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
drivers/media/rc/nuvoton-cir.c