RE: [PATCH] gpiolib:change to use irq_alloc_descs_from to alloc virqs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> From: Linus Walleij [mailto:linus.walleij@xxxxxxxxxx]
> 
> On Tue, Sep 23, 2014 at 2:59 PM, Grygorii Strashko
> <grygorii.strashko@xxxxxx> wrote:
> 
> > Now the "irq_base" is used only twice in gpiolib code and below diff
> > should allow to drop it completely from gpiolib code.
> >
> > diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c index
> > 15cc0bb..81762ed 100644
> > --- a/drivers/gpio/gpiolib.c
> > +++ b/drivers/gpio/gpiolib.c
> > @@ -524,7 +524,7 @@ static void gpiochip_irqchip_remove(struct gpio_chip
> *gpiochip)
> >         /* Remove all IRQ mappings and delete the domain */
> >         if (gpiochip->irqdomain) {
> >                 for (offset = 0; offset < gpiochip->ngpio; offset++)
> > -                       irq_dispose_mapping(gpiochip->irq_base + offset);
> > +
> > + irq_dispose_mapping(irq_find_mapping(gpiochip->irqdomain, offset));
> >                 irq_domain_remove(gpiochip->irqdomain);
> >         }
> >
> > not tested.
> 
> I like the looks of this.
> 
> Grygorii, can you send a proper, tested patch for this? Thansk!

Could we also remove gpiochip->irq_base if use this solution?
It seems gpiochip->irq_base is useless .

Thanks
��.n��������+%������w��{.n�����{��
b���ܨ}���Ơz�j:+v�����w����ޙ��&�)ߡ�a����z�ޗ���ݢj��w�f





[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux