[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHp75VfGwQ7G2b39GO4tN=sxQoiahO2uudy25ALxEkrNcP9eVw@mail.gmail.com>
Date: Sat, 25 Dec 2021 18:45:33 +0200
From: Andy Shevchenko <andy.shevchenko@...il.com>
To: Lad Prabhakar <prabhakar.mahadev-lad.rj@...renesas.com>
Cc: Thomas Gleixner <tglx@...utronix.de>,
Marc Zyngier <maz@...nel.org>,
Rob Herring <robh+dt@...nel.org>,
Geert Uytterhoeven <geert+renesas@...der.be>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Prabhakar <prabhakar.csengg@...il.com>
Subject: Re: [PATCH] irqchip/renesas-irqc: Use platform_get_irq_optional() to
get the interrupt
On Thu, Dec 16, 2021 at 9:52 AM Lad Prabhakar
<prabhakar.mahadev-lad.rj@...renesas.com> wrote:
>
> platform_get_resource(pdev, IORESOURCE_IRQ, ..) relies on static
> allocation of IRQ resources in DT core code, this causes an issue
> when using hierarchical interrupt domains using "interrupts" property
> in the node as this bypassed the hierarchical setup and messed up the
> irq chaining.
>
> In preparation for removal of static setup of IRQ resource from DT core
> code use platform_get_irq_optional().
> + ret = platform_get_irq_optional(pdev, k);
> + if (ret == -EPROBE_DEFER)
> + goto err_runtime_pm_disable;
> + if (ret < 0)
> break;
The best approach is
ret = platform_get_irq_optional(...);
if (ret < 0 && ret != -ENXIO)
return ret;
if (ret > 0)
...we got it...
It will allow the future API fix of platform_get_irq_optional() to be
really optional.
--
With Best Regards,
Andy Shevchenko
Powered by blists - more mailing lists