On Sat, Mar 29, 2014 at 4:44 AM, Linus Walleij <linus.walleij@xxxxxxxxxx> wrote: > When using the irqchip helper inside the gpiolib, make sure > the IRQs are unmapped/disposed before the irqdomain is removed > as part of removing the gpiochip. Acked-by: Alexandre Courbot <acourbot@xxxxxxxxxx> > Signed-off-by: Linus Walleij <linus.walleij@xxxxxxxxxx> > --- > drivers/gpio/gpiolib.c | 33 +++++++++++++++++++++++++++++---- > include/linux/gpio/driver.h | 1 + > 2 files changed, 30 insertions(+), 4 deletions(-) > > diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c > index f41cb4f3d715..761013f8b82f 100644 > --- a/drivers/gpio/gpiolib.c > +++ b/drivers/gpio/gpiolib.c > @@ -1399,8 +1399,18 @@ static int gpiochip_irq_map(struct irq_domain *d, unsigned int irq, > return 0; > } > > +static void gpiochip_irq_unmap(struct irq_domain *d, unsigned int irq) > +{ > +#ifdef CONFIG_ARM > + set_irq_flags(irq, 0); > +#endif Just curious here, why is a special case needed for ARM? I would not expect architecture-specific code on gpiolib, but I'm sure you have your reasons for that. -- To unsubscribe from this list: send the line "unsubscribe linux-gpio" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html