diff options
author | Thierry Reding <treding@nvidia.com> | 2017-11-07 13:15:55 -0500 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2017-11-08 08:14:09 -0500 |
commit | 1b95b4eb567aab1cafcdcb14c60a7dd9d56236a9 (patch) | |
tree | 02b39bdee7fac6fe8bcd485fdbce2a1ac9b6d982 /drivers/gpio/gpiolib.c | |
parent | e0d89728981393b7d694bd3419b7794b9882c92d (diff) |
gpio: Export gpiochip_irq_{map,unmap}()
Export these functions so that drivers can explicitly use these when
setting up their IRQ domain.
Signed-off-by: Thierry Reding <treding@nvidia.com>
Acked-by: Grygorii Strashko <grygorii.strashko@ti.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/gpio/gpiolib.c')
-rw-r--r-- | drivers/gpio/gpiolib.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c index 003d1bb85165..7347ea1c699a 100644 --- a/drivers/gpio/gpiolib.c +++ b/drivers/gpio/gpiolib.c | |||
@@ -1638,8 +1638,8 @@ EXPORT_SYMBOL_GPL(gpiochip_set_nested_irqchip); | |||
1638 | * gpiochip by assigning the gpiochip as chip data, and using the irqchip | 1638 | * gpiochip by assigning the gpiochip as chip data, and using the irqchip |
1639 | * stored inside the gpiochip. | 1639 | * stored inside the gpiochip. |
1640 | */ | 1640 | */ |
1641 | static int gpiochip_irq_map(struct irq_domain *d, unsigned int irq, | 1641 | int gpiochip_irq_map(struct irq_domain *d, unsigned int irq, |
1642 | irq_hw_number_t hwirq) | 1642 | irq_hw_number_t hwirq) |
1643 | { | 1643 | { |
1644 | struct gpio_chip *chip = d->host_data; | 1644 | struct gpio_chip *chip = d->host_data; |
1645 | int err = 0; | 1645 | int err = 0; |
@@ -1676,8 +1676,9 @@ static int gpiochip_irq_map(struct irq_domain *d, unsigned int irq, | |||
1676 | 1676 | ||
1677 | return 0; | 1677 | return 0; |
1678 | } | 1678 | } |
1679 | EXPORT_SYMBOL_GPL(gpiochip_irq_map); | ||
1679 | 1680 | ||
1680 | static void gpiochip_irq_unmap(struct irq_domain *d, unsigned int irq) | 1681 | void gpiochip_irq_unmap(struct irq_domain *d, unsigned int irq) |
1681 | { | 1682 | { |
1682 | struct gpio_chip *chip = d->host_data; | 1683 | struct gpio_chip *chip = d->host_data; |
1683 | 1684 | ||
@@ -1686,6 +1687,7 @@ static void gpiochip_irq_unmap(struct irq_domain *d, unsigned int irq) | |||
1686 | irq_set_chip_and_handler(irq, NULL, NULL); | 1687 | irq_set_chip_and_handler(irq, NULL, NULL); |
1687 | irq_set_chip_data(irq, NULL); | 1688 | irq_set_chip_data(irq, NULL); |
1688 | } | 1689 | } |
1690 | EXPORT_SYMBOL_GPL(gpiochip_irq_unmap); | ||
1689 | 1691 | ||
1690 | static const struct irq_domain_ops gpiochip_domain_ops = { | 1692 | static const struct irq_domain_ops gpiochip_domain_ops = { |
1691 | .map = gpiochip_irq_map, | 1693 | .map = gpiochip_irq_map, |