]> git.baikalelectronics.ru Git - kernel.git/commit
regmap: irq: handle HW using separate rising/falling edge interrupts
authorBartosz Golaszewski <bgolaszewski@baylibre.com>
Fri, 7 Dec 2018 13:04:52 +0000 (14:04 +0100)
committerMark Brown <broonie@kernel.org>
Thu, 13 Dec 2018 17:07:46 +0000 (17:07 +0000)
commit96e4daf20f57658a45002462c292ae13ef1039ec
tree5229268e52f3dedd06da31bb9aabe430a6aeeac4
parent194a7d8671504caa9cdf4f5e5ed86741e52a2f14
regmap: irq: handle HW using separate rising/falling edge interrupts

Some interrupt controllers use separate bits for controlling rising
and falling edge interrupts in the mask register i.e. they have one
interrupt for rising edge and one for falling.

We already handle the case where we have a single interrupt in the
mask register and a separate type configuration register.

Add a new switch to regmap_irq_chip which tells the framework to use
the mask_base address for configuring the edge of the interrupts that
define type_falling/rising_mask values.

For such interrupts we never update the type_base bits. For interrupts
that don't define type masks or their regmap irq chip doesn't set the
type_in_mask to true everything stays the same.

Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/base/regmap/regmap-irq.c
include/linux/regmap.h