lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAL_JsqL3kON+0p8PeYeAJO2GdW053aYFo2C20SWQSGQTGV5hag@mail.gmail.com>
Date: Wed, 3 Dec 2025 08:55:28 -0600
From: Rob Herring <robh@...nel.org>
To: Geert Uytterhoeven <geert@...ux-m68k.org>
Cc: Ioana Ciornei <ioana.ciornei@....com>, Geert Uytterhoeven <geert+renesas@...der.be>, 
	Saravana Kannan <saravanak@...gle.com>, Krzysztof Kozlowski <krzk+dt@...nel.org>, 
	Conor Dooley <conor+dt@...nel.org>, Paul Walmsley <pjw@...nel.org>, 
	Palmer Dabbelt <palmer@...belt.com>, Albert Ou <aou@...s.berkeley.edu>, 
	Alexandre Ghiti <alex@...ti.fr>, Samuel Holland <samuel@...lland.org>, Marc Zyngier <maz@...nel.org>, 
	Lad Prabhakar <prabhakar.mahadev-lad.rj@...renesas.com>, 
	Magnus Damm <magnus.damm@...il.com>, devicetree@...r.kernel.org, 
	linux-renesas-soc@...r.kernel.org, linux-riscv@...ts.infradead.org, 
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2] of/irq: Ignore interrupt parent for nodes without interrupts

On Wed, Dec 3, 2025 at 3:58 AM Geert Uytterhoeven <geert@...ux-m68k.org> wrote:
>
> Hi Ionana,
>
> On Wed, 3 Dec 2025 at 10:48, Ioana Ciornei <ioana.ciornei@....com> wrote:
> > On Tue, Dec 02, 2025 at 03:19:17PM -0600, Rob Herring wrote:
> > > On Tue, Dec 2, 2025 at 10:36 AM Ioana Ciornei <ioana.ciornei@....com> wrote:
> > > > On Mon, Dec 01, 2025 at 06:09:19AM -0600, Rob Herring wrote:
> > > > > On Fri, Nov 28, 2025 at 10:43 AM Ioana Ciornei <ioana.ciornei@....com> wrote:
> > > > > > On Fri, Nov 14, 2025 at 11:47:54AM +0100, Geert Uytterhoeven wrote:
> > > > > > > The Devicetree Specification states:
> > > > > > >
> > > > > > >     The root of the interrupt tree is determined when traversal of the
> > > > > > >     interrupt tree reaches an interrupt controller node without an
> > > > > > >     interrupts property and thus no explicit interrupt parent.
> > > > > > >
> > > > > > > However, of_irq_init() gratuitously assumes that a node without
> > > > > > > interrupts has an actual interrupt parent if it finds an
> > > > > > > interrupt-parent property higher up in the device tree.  Hence when such
> > > > > > > a property is present (e.g. in the root node), the root interrupt
> > > > > > > controller may not be detected as such, causing a panic:
> > > > > > >
> > > > > > >     OF: of_irq_init: children remain, but no parents
> > > > > > >     Kernel panic - not syncing: No interrupt controller found.
> > > > > > >
> > > > > > > Commit e91033621d56e055 ("of/irq: Use interrupts-extended to find
> > > > > > > parent") already fixed a first part, by checking for the presence of an
> > > > > > > interrupts-extended property.  Fix the second part by only calling
> > > > > > > of_irq_find_parent() when an interrupts property is present.
> > > > > > >
> > > > > > > Signed-off-by: Geert Uytterhoeven <geert+renesas@...der.be>
>
> > > > > > This change irq-ls-extirq and commit 6ba51b7b34ca ("of/irq: Handle
> > > > > > explicit interrupt parent") does not help with the issue.
>
> > > > I just tried converting ls-extirq to a proper platform driver and it's
> > > > pretty straightforward. The problem is getting that driver to probe on
> > > > the ls-extirq dt node since of_platform_populate() is not called on its
> > > > parent node.
> > > >
> > > > I would avoid changing the DT and adding a "simple-bus" compatible to
> > > > the parent nodes. The other option is to add another simple driver which
> > > > just calls of_platform_populate() for all compatible strings defined in
> > > > fsl,layerscape-scfg.yaml.
> > >
> > > The simplest solution might be adding 'syscon' to the default match
> > > list for of_platform_populate(). That's kind of a big hammer though
> > > and could break something. Not sure, but I'm willing to stick that in
> > > linux-next and see.
> > >
> > > Another option is hijack the simple-pm-bus driver which already does
> > > just what you said.
> >
> > I would prefer the second option since that doesn't impact other
> > platforms.
> >
> > Geert, since you are the module author, are you ok with the following
> > diff?
> >
> > --- a/drivers/bus/simple-pm-bus.c
> > +++ b/drivers/bus/simple-pm-bus.c
> > @@ -142,6 +142,12 @@ static const struct of_device_id simple_pm_bus_of_match[] = {
> >         { .compatible = "simple-mfd",   .data = ONLY_BUS },
> >         { .compatible = "isa",          .data = ONLY_BUS },
> >         { .compatible = "arm,amba-bus", .data = ONLY_BUS },
> > +       { .compatible = "fsl,ls1021a-scfg", },
> > +       { .compatible = "fsl,ls1043a-scfg", },
> > +       { .compatible = "fsl,ls1046a-scfg", },
> > +       { .compatible = "fsl,ls1088a-isc", },
> > +       { .compatible = "fsl,ls2080a-isc", },
> > +       { .compatible = "fsl,lx2160a-isc", },
> >         { /* sentinel */ }
> >  };
> >  MODULE_DEVICE_TABLE(of, simple_pm_bus_of_match);
>
> Fine for me.
>
> Alternatively, these could be added to the match_table[] in
> drivers/of/platform.c:of_platform_default_populate()?

That would work too, but I think the direction we should go is using a
driver as we've also been discussing on Herve's series.

Rob

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ