summaryrefslogtreecommitdiff
path: root/include/linux/gpio
diff options
context:
space:
mode:
authorMichael Walle <michael@walle.cc>2020-05-28 16:58:43 +0200
committerLinus Walleij <linus.walleij@linaro.org>2020-06-03 10:48:37 +0200
commit6a45b0e2589fafd7fc501a5fbd0ab56689a08124 (patch)
tree354473198d7559b15863615df6963a840d2b9998 /include/linux/gpio
parenta8173820f441ab3e2a45c4bb66b70da9a57a349e (diff)
gpiolib: Introduce gpiochip_irqchip_add_domain()
The function connects an IRQ domain to a gpiochip and reuses gpiochip_to_irq() which is provided by gpiolib. gpiochip_irqchip_* and regmap_irq partially provide the same functionality. This function will help to connect just the minimal functionality of the gpiochip_irqchip which is needed to work together with regmap-irq. Signed-off-by: Michael Walle <michael@walle.cc> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Link: https://lore.kernel.org/r/20200528145845.31436-2-michael@walle.cc Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'include/linux/gpio')
-rw-r--r--include/linux/gpio/driver.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/gpio/driver.h b/include/linux/gpio/driver.h
index c8bcaf315d03..c4f272af7af5 100644
--- a/include/linux/gpio/driver.h
+++ b/include/linux/gpio/driver.h
@@ -612,6 +612,9 @@ int gpiochip_irqchip_add_key(struct gpio_chip *gc,
bool gpiochip_irqchip_irq_valid(const struct gpio_chip *gc,
unsigned int offset);
+int gpiochip_irqchip_add_domain(struct gpio_chip *gc,
+ struct irq_domain *domain);
+
#ifdef CONFIG_LOCKDEP
/*