Re: [PATCH 1/2] dt-bindings: gpio: cdns: add clock-names property
From: Linus Walleij
Date: Wed Mar 11 2026 - 09:11:18 EST
On Wed, Mar 11, 2026 at 1:08 PM Zichar Zhang <zichar.zhang@xxxxxxxxxxx> wrote:
> On Fri, Mar 06, 2026 at 11:10:35AM +0100, Linus Walleij wrote:
> > [You don't often get email from linusw@xxxxxxxxxx. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
> >
> > EXTERNAL EMAIL
> >
> > Hi Zichar,
> >
> > On Fri, Mar 6, 2026 at 10:32 AM Zichar Zhang <zichar.zhang@xxxxxxxxxxx> wrote:
> >
> > > + clock-names:
> > > + description:
> > > + Optional name for the GPIO controller input clock.
> > > + minItems: 1
> > > + maxItems: 1
> >
> > I think clock-names: true should suffice, but the binding maintainers
> > can say how
> > they want it.
> >
> > I would suggest to also add:
> >
> > gpio-ranges:
> > minItems: 1
> > maxItems: 32
> >
> > At this point even if you're not using it FTM. This will make it
> > possible to later
> > map the GPIOs to the pin controller and control pin configuration from the
> > GPIO subsystem.
>
> Thanks. Given that cdns,gpio.yaml already defines "ngpios", would it make
> sense to use it for the "gpio-ranges" definition?
You mean like
maxItems: (ngpios) ? ngpios : 32
or something like that?
I don't think YAML can do variables that way, but Rob might know better.
We sure know 32 is a cap.
Yours,
Linus Walleij