[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20241124192611.3b74915b@jic23-huawei>
Date: Sun, 24 Nov 2024 19:26:11 +0000
From: Jonathan Cameron <jic23@...nel.org>
To: Krzysztof Kozlowski <krzk@...nel.org>
Cc: mgonellabolduc@...onoff.com, Lars-Peter Clausen <lars@...afoo.de>, Rob
Herring <robh@...nel.org>, Krzysztof Kozlowski <krzk+dt@...nel.org>, Conor
Dooley <conor+dt@...nel.org>, Nathan Chancellor <nathan@...nel.org>, Nick
Desaulniers <ndesaulniers@...gle.com>, Bill Wendling <morbo@...gle.com>,
Justin Stitt <justinstitt@...gle.com>, Mikael Gonella-Bolduc
<m.gonella.bolduc@...il.com>, linux-iio@...r.kernel.org,
devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
llvm@...ts.linux.dev, Hugo Villeneuve <hvilleneuve@...onoff.com>
Subject: Re: [PATCH 1/2] dt-bindings: iio: light: Add APDS9160 binding
On Wed, 20 Nov 2024 18:22:43 +0100
Krzysztof Kozlowski <krzk@...nel.org> wrote:
> On 19/11/2024 21:36, Mikael Gonella-Bolduc via B4 Relay wrote:
> > +
> > + reg:
> > + maxItems: 1
> > +
> > + interrupts:
> > + maxItems: 1
> > +
> > + vdd-supply: true
> > +
> > +additionalProperties: false
>
> This goes after required:
>
> > +
> > +required:
> > + - compatible
> > + - reg
>
> Supply not required?
Just for background on this. Linux will happily provide
you a stub regulator if the supply is not in dt, but we decided a while ago
that it was more accurate to have the supplies as required properties as that
would allow us to distinguish between those that are needed for operation
and those that are actually optional like reference voltages where there
is the option of an on chip reference if the external one isn't connected.
So almost certainly just make it required here.
Jonathan
>
> > +
> > +examples:
> > + - |
> > + #include <dt-bindings/interrupt-controller/irq.h>
> > +
> > + i2c {
> > + #address-cells = <1>;
> > + #size-cells = <0>;
> > +
> > + apds9160@53 {
>
> Node names should be generic. See also an explanation and list of
> examples (not exhaustive) in DT specification:
> https://devicetree-specification.readthedocs.io/en/latest/chapter2-devicetree-basics.html#generic-names-recommendation
>
>
> > + compatible = "broadmobi,apds9160";
>
> Use 4 spaces for example indentation. Or at least something consistent.
>
>
> Best regards,
> Krzysztof
>
Powered by blists - more mailing lists