devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 1/5] dt-bindings: vendor-prefixes: add Diodes
@ 2022-09-06  8:28 Martyn Welch
  2022-09-06  8:28 ` [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q Martyn Welch
  2022-09-09 13:27 ` [PATCH v2 1/5] dt-bindings: vendor-prefixes: add Diodes Bartosz Golaszewski
  0 siblings, 2 replies; 14+ messages in thread
From: Martyn Welch @ 2022-09-06  8:28 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski
  Cc: Bartosz Golaszewski, Martyn Welch, Krzysztof Kozlowski,
	Rob Herring, devicetree, linux-kernel

From: Martyn Welch <martyn.welch@collabora.com>

Diodes Incorporated is a manufacturer of application specific standard
products within the discrete, logic, analog, and mixed-signal semiconductor
markets.

https://www.diodes.com/

Signed-off-by: Martyn Welch <martyn.welch@collabora.com>
Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---

Changes in v2:
 - None

 Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/Documentation/devicetree/bindings/vendor-prefixes.yaml b/Documentation/devicetree/bindings/vendor-prefixes.yaml
index 2f0151e9f6be..7ee9b7692ed1 100644
--- a/Documentation/devicetree/bindings/vendor-prefixes.yaml
+++ b/Documentation/devicetree/bindings/vendor-prefixes.yaml
@@ -328,6 +328,8 @@ patternProperties:
     description: Digi International Inc.
   "^digilent,.*":
     description: Diglent, Inc.
+  "^diodes,.*":
+    description: Diodes, Inc.
   "^dioo,.*":
     description: Dioo Microcircuit Co., Ltd
   "^dlc,.*":
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q
  2022-09-06  8:28 [PATCH v2 1/5] dt-bindings: vendor-prefixes: add Diodes Martyn Welch
@ 2022-09-06  8:28 ` Martyn Welch
  2022-09-06  8:37   ` Krzysztof Kozlowski
                     ` (3 more replies)
  2022-09-09 13:27 ` [PATCH v2 1/5] dt-bindings: vendor-prefixes: add Diodes Bartosz Golaszewski
  1 sibling, 4 replies; 14+ messages in thread
From: Martyn Welch @ 2022-09-06  8:28 UTC (permalink / raw)
  To: Linus Walleij, Bartosz Golaszewski, Rob Herring,
	Krzysztof Kozlowski
  Cc: Martyn Welch, Krzysztof Kozlowski, linux-gpio, devicetree,
	linux-kernel

From: Martyn Welch <martyn.welch@collabora.com>

The NXP PCAL6534 is a 34-bit I2C I/O expander similar to the PCAL6524. The
Diodes PI4IOE5V6534Q is a functionally identical chip provided by Diodes
Inc.

Signed-off-by: Martyn Welch <martyn.welch@collabora.com>
---

Changes in v2:
 - Enumerate pi4ioe5v6534q as requiring pcal6534 fallback

 .../bindings/gpio/gpio-pca95xx.yaml           | 98 ++++++++++---------
 1 file changed, 52 insertions(+), 46 deletions(-)

diff --git a/Documentation/devicetree/bindings/gpio/gpio-pca95xx.yaml b/Documentation/devicetree/bindings/gpio/gpio-pca95xx.yaml
index 977b14db09b0..81140b066683 100644
--- a/Documentation/devicetree/bindings/gpio/gpio-pca95xx.yaml
+++ b/Documentation/devicetree/bindings/gpio/gpio-pca95xx.yaml
@@ -15,52 +15,58 @@ description: |+
 
 properties:
   compatible:
-    enum:
-      - exar,xra1202
-      - maxim,max7310
-      - maxim,max7312
-      - maxim,max7313
-      - maxim,max7315
-      - maxim,max7319
-      - maxim,max7320
-      - maxim,max7321
-      - maxim,max7322
-      - maxim,max7323
-      - maxim,max7324
-      - maxim,max7325
-      - maxim,max7326
-      - maxim,max7327
-      - nxp,pca6408
-      - nxp,pca6416
-      - nxp,pca9505
-      - nxp,pca9506
-      - nxp,pca9534
-      - nxp,pca9535
-      - nxp,pca9536
-      - nxp,pca9537
-      - nxp,pca9538
-      - nxp,pca9539
-      - nxp,pca9554
-      - nxp,pca9555
-      - nxp,pca9556
-      - nxp,pca9557
-      - nxp,pca9574
-      - nxp,pca9575
-      - nxp,pca9698
-      - nxp,pcal6416
-      - nxp,pcal6524
-      - nxp,pcal9535
-      - nxp,pcal9554b
-      - nxp,pcal9555a
-      - onnn,cat9554
-      - onnn,pca9654
-      - ti,pca6107
-      - ti,pca9536
-      - ti,tca6408
-      - ti,tca6416
-      - ti,tca6424
-      - ti,tca9539
-      - ti,tca9554
+    oneOf:
+      - items:
+        - const: diodes,pi4ioe5v6534q
+        - const: nxp,pcal6534
+      - items:
+        - enum:
+          - exar,xra1202
+          - maxim,max7310
+          - maxim,max7312
+          - maxim,max7313
+          - maxim,max7315
+          - maxim,max7319
+          - maxim,max7320
+          - maxim,max7321
+          - maxim,max7322
+          - maxim,max7323
+          - maxim,max7324
+          - maxim,max7325
+          - maxim,max7326
+          - maxim,max7327
+          - nxp,pca6408
+          - nxp,pca6416
+          - nxp,pca9505
+          - nxp,pca9506
+          - nxp,pca9534
+          - nxp,pca9535
+          - nxp,pca9536
+          - nxp,pca9537
+          - nxp,pca9538
+          - nxp,pca9539
+          - nxp,pca9554
+          - nxp,pca9555
+          - nxp,pca9556
+          - nxp,pca9557
+          - nxp,pca9574
+          - nxp,pca9575
+          - nxp,pca9698
+          - nxp,pcal6416
+          - nxp,pcal6524
+          - nxp,pcal6534
+          - nxp,pcal9535
+          - nxp,pcal9554b
+          - nxp,pcal9555a
+          - onnn,cat9554
+          - onnn,pca9654
+          - ti,pca6107
+          - ti,pca9536
+          - ti,tca6408
+          - ti,tca6416
+          - ti,tca6424
+          - ti,tca9539
+          - ti,tca9554
 
   reg:
     maxItems: 1
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q
  2022-09-06  8:28 ` [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q Martyn Welch
@ 2022-09-06  8:37   ` Krzysztof Kozlowski
  2022-09-06 12:19   ` Andy Shevchenko
                     ` (2 subsequent siblings)
  3 siblings, 0 replies; 14+ messages in thread
From: Krzysztof Kozlowski @ 2022-09-06  8:37 UTC (permalink / raw)
  To: Martyn Welch, Linus Walleij, Bartosz Golaszewski, Rob Herring,
	Krzysztof Kozlowski
  Cc: Martyn Welch, Krzysztof Kozlowski, linux-gpio, devicetree,
	linux-kernel

On 06/09/2022 10:28, Martyn Welch wrote:
> From: Martyn Welch <martyn.welch@collabora.com>
> 
> The NXP PCAL6534 is a 34-bit I2C I/O expander similar to the PCAL6524. The
> Diodes PI4IOE5V6534Q is a functionally identical chip provided by Diodes
> Inc.
> 
> Signed-off-by: Martyn Welch <martyn.welch@collabora.com>


Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>


Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q
  2022-09-06  8:28 ` [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q Martyn Welch
  2022-09-06  8:37   ` Krzysztof Kozlowski
@ 2022-09-06 12:19   ` Andy Shevchenko
  2022-09-06 13:08     ` Linus Walleij
  2022-09-06 13:05   ` Linus Walleij
  2022-09-06 13:40   ` Rob Herring
  3 siblings, 1 reply; 14+ messages in thread
From: Andy Shevchenko @ 2022-09-06 12:19 UTC (permalink / raw)
  To: Martyn Welch
  Cc: Linus Walleij, Bartosz Golaszewski, Rob Herring,
	Krzysztof Kozlowski, Martyn Welch, Krzysztof Kozlowski,
	linux-gpio, devicetree, linux-kernel

On Tue, Sep 06, 2022 at 09:28:16AM +0100, Martyn Welch wrote:
> From: Martyn Welch <martyn.welch@collabora.com>
> 
> The NXP PCAL6534 is a 34-bit I2C I/O expander similar to the PCAL6524. The
> Diodes PI4IOE5V6534Q is a functionally identical chip provided by Diodes
> Inc.

...

> +    oneOf:
> +      - items:
> +        - const: diodes,pi4ioe5v6534q
> +        - const: nxp,pcal6534

^^^

> +      - items:
> +        - enum:

> +          - nxp,pcal6534

^^^

Not sure why is this dup?

-- 
With Best Regards,
Andy Shevchenko



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q
  2022-09-06  8:28 ` [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q Martyn Welch
  2022-09-06  8:37   ` Krzysztof Kozlowski
  2022-09-06 12:19   ` Andy Shevchenko
@ 2022-09-06 13:05   ` Linus Walleij
  2022-09-06 13:40   ` Rob Herring
  3 siblings, 0 replies; 14+ messages in thread
From: Linus Walleij @ 2022-09-06 13:05 UTC (permalink / raw)
  To: Martyn Welch
  Cc: Bartosz Golaszewski, Rob Herring, Krzysztof Kozlowski,
	Martyn Welch, Krzysztof Kozlowski, linux-gpio, devicetree,
	linux-kernel

On Tue, Sep 6, 2022 at 10:28 AM Martyn Welch
<martyn.welch@collabora.co.uk> wrote:

> From: Martyn Welch <martyn.welch@collabora.com>
>
> The NXP PCAL6534 is a 34-bit I2C I/O expander similar to the PCAL6524. The
> Diodes PI4IOE5V6534Q is a functionally identical chip provided by Diodes
> Inc.
>
> Signed-off-by: Martyn Welch <martyn.welch@collabora.com>
> ---
>
> Changes in v2:
>  - Enumerate pi4ioe5v6534q as requiring pcal6534 fallback

Reviewed-by: Linus Walleij <linus.walleij@linaro.org>

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q
  2022-09-06 12:19   ` Andy Shevchenko
@ 2022-09-06 13:08     ` Linus Walleij
  2022-09-06 13:19       ` Andy Shevchenko
  0 siblings, 1 reply; 14+ messages in thread
From: Linus Walleij @ 2022-09-06 13:08 UTC (permalink / raw)
  To: Andy Shevchenko
  Cc: Martyn Welch, Bartosz Golaszewski, Rob Herring,
	Krzysztof Kozlowski, Martyn Welch, Krzysztof Kozlowski,
	linux-gpio, devicetree, linux-kernel

On Tue, Sep 6, 2022 at 2:19 PM Andy Shevchenko
<andriy.shevchenko@intel.com> wrote:
> On Tue, Sep 06, 2022 at 09:28:16AM +0100, Martyn Welch wrote:
> > From: Martyn Welch <martyn.welch@collabora.com>
> >
> > The NXP PCAL6534 is a 34-bit I2C I/O expander similar to the PCAL6524. The
> > Diodes PI4IOE5V6534Q is a functionally identical chip provided by Diodes
> > Inc.
>
> ...
>
> > +    oneOf:
> > +      - items:
> > +        - const: diodes,pi4ioe5v6534q
> > +        - const: nxp,pcal6534
>
> ^^^
>
> > +      - items:
> > +        - enum:
>
> > +          - nxp,pcal6534
>
> ^^^
>
> Not sure why is this dup?

No that is how DT compatibles work. One version of the component,
bought from NXP will look like this:

compatible = "nxp,pcal6534";

Another version bought from diodes will look like this:

compatible = "diodes,pi4ioe5v6534q", "nxp,pcal6534";

Then the drivers are probed matching from left to right,
with the "most compatible" matching first.

This also answers your question on the implementation.

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q
  2022-09-06 13:08     ` Linus Walleij
@ 2022-09-06 13:19       ` Andy Shevchenko
  2022-09-06 13:33         ` Linus Walleij
  0 siblings, 1 reply; 14+ messages in thread
From: Andy Shevchenko @ 2022-09-06 13:19 UTC (permalink / raw)
  To: Linus Walleij
  Cc: Martyn Welch, Bartosz Golaszewski, Rob Herring,
	Krzysztof Kozlowski, Martyn Welch, Krzysztof Kozlowski,
	linux-gpio, devicetree, linux-kernel

On Tue, Sep 06, 2022 at 03:08:00PM +0200, Linus Walleij wrote:
> On Tue, Sep 6, 2022 at 2:19 PM Andy Shevchenko
> <andriy.shevchenko@intel.com> wrote:
> > On Tue, Sep 06, 2022 at 09:28:16AM +0100, Martyn Welch wrote:
> > > From: Martyn Welch <martyn.welch@collabora.com>
> > >
> > > The NXP PCAL6534 is a 34-bit I2C I/O expander similar to the PCAL6524. The
> > > Diodes PI4IOE5V6534Q is a functionally identical chip provided by Diodes
> > > Inc.
> >
> > ...
> >
> > > +    oneOf:
> > > +      - items:
> > > +        - const: diodes,pi4ioe5v6534q
> > > +        - const: nxp,pcal6534
> >
> > ^^^
> >
> > > +      - items:
> > > +        - enum:
> >
> > > +          - nxp,pcal6534
> >
> > ^^^
> >
> > Not sure why is this dup?
> 
> No that is how DT compatibles work. One version of the component,
> bought from NXP will look like this:
> 
> compatible = "nxp,pcal6534";
> 
> Another version bought from diodes will look like this:
> 
> compatible = "diodes,pi4ioe5v6534q", "nxp,pcal6534";
> 
> Then the drivers are probed matching from left to right,
> with the "most compatible" matching first.
> 
> This also answers your question on the implementation.

Then I don't understand why the const list above is only for new chips
and not for the old one where the same can be applied.

Mysterious ways of DT...

-- 
With Best Regards,
Andy Shevchenko



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q
  2022-09-06 13:19       ` Andy Shevchenko
@ 2022-09-06 13:33         ` Linus Walleij
  2022-09-06 13:53           ` Andy Shevchenko
  2022-09-06 14:19           ` Rob Herring
  0 siblings, 2 replies; 14+ messages in thread
From: Linus Walleij @ 2022-09-06 13:33 UTC (permalink / raw)
  To: Andy Shevchenko
  Cc: Martyn Welch, Bartosz Golaszewski, Rob Herring,
	Krzysztof Kozlowski, Martyn Welch, Krzysztof Kozlowski,
	linux-gpio, devicetree, linux-kernel

On Tue, Sep 6, 2022 at 3:20 PM Andy Shevchenko
<andriy.shevchenko@intel.com> wrote:
> On Tue, Sep 06, 2022 at 03:08:00PM +0200, Linus Walleij wrote:
> > On Tue, Sep 6, 2022 at 2:19 PM Andy Shevchenko
> > <andriy.shevchenko@intel.com> wrote:
> > > On Tue, Sep 06, 2022 at 09:28:16AM +0100, Martyn Welch wrote:
> > > > From: Martyn Welch <martyn.welch@collabora.com>
> > > >
> > > > The NXP PCAL6534 is a 34-bit I2C I/O expander similar to the PCAL6524. The
> > > > Diodes PI4IOE5V6534Q is a functionally identical chip provided by Diodes
> > > > Inc.
> > >
> > > ...
> > >
> > > > +    oneOf:
> > > > +      - items:
> > > > +        - const: diodes,pi4ioe5v6534q
> > > > +        - const: nxp,pcal6534
> > >
> > > ^^^
> > >
> > > > +      - items:
> > > > +        - enum:
> > >
> > > > +          - nxp,pcal6534
> > >
> > > ^^^
> > >
> > > Not sure why is this dup?
> >
> > No that is how DT compatibles work. One version of the component,
> > bought from NXP will look like this:
> >
> > compatible = "nxp,pcal6534";
> >
> > Another version bought from diodes will look like this:
> >
> > compatible = "diodes,pi4ioe5v6534q", "nxp,pcal6534";
> >
> > Then the drivers are probed matching from left to right,
> > with the "most compatible" matching first.
> >
> > This also answers your question on the implementation.
>
> Then I don't understand why the const list above is only for new chips
> and not for the old one where the same can be applied.

That's YAML. It's because the const list is the most compact way
to express two precise items following after each other, and the enum
list is an implicit list of single-item const:s, as you cannot enum
tuples.

> Mysterious ways of DT...

It's not DT, it's YAML that is mysterious. DT itself is a pretty
straight-forward
grammar, while YAML is a meta-grammar describing the DT grammar
(ML stands for Meta Language).

All meta languages are mysterious.

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q
  2022-09-06  8:28 ` [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q Martyn Welch
                     ` (2 preceding siblings ...)
  2022-09-06 13:05   ` Linus Walleij
@ 2022-09-06 13:40   ` Rob Herring
  3 siblings, 0 replies; 14+ messages in thread
From: Rob Herring @ 2022-09-06 13:40 UTC (permalink / raw)
  To: Martyn Welch
  Cc: Linus Walleij, Krzysztof Kozlowski, linux-gpio, Rob Herring,
	devicetree, linux-kernel, Martyn Welch, Bartosz Golaszewski,
	Krzysztof Kozlowski

On Tue, 06 Sep 2022 09:28:16 +0100, Martyn Welch wrote:
> From: Martyn Welch <martyn.welch@collabora.com>
> 
> The NXP PCAL6534 is a 34-bit I2C I/O expander similar to the PCAL6524. The
> Diodes PI4IOE5V6534Q is a functionally identical chip provided by Diodes
> Inc.
> 
> Signed-off-by: Martyn Welch <martyn.welch@collabora.com>
> ---
> 
> Changes in v2:
>  - Enumerate pi4ioe5v6534q as requiring pcal6534 fallback
> 
>  .../bindings/gpio/gpio-pca95xx.yaml           | 98 ++++++++++---------
>  1 file changed, 52 insertions(+), 46 deletions(-)
> 

My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check'
on your patch (DT_CHECKER_FLAGS is new in v5.13):

yamllint warnings/errors:
./Documentation/devicetree/bindings/gpio/gpio-pca95xx.yaml:20:9: [warning] wrong indentation: expected 10 but found 8 (indentation)
./Documentation/devicetree/bindings/gpio/gpio-pca95xx.yaml:23:9: [warning] wrong indentation: expected 10 but found 8 (indentation)
./Documentation/devicetree/bindings/gpio/gpio-pca95xx.yaml:24:11: [warning] wrong indentation: expected 12 but found 10 (indentation)

dtschema/dtc warnings/errors:

doc reference errors (make refcheckdocs):

See https://patchwork.ozlabs.org/patch/

This check can fail if there are any dependencies. The base for a patch
series is generally the most recent rc1.

If you already ran 'make dt_binding_check' and didn't see the above
error(s), then make sure 'yamllint' is installed and dt-schema is up to
date:

pip3 install dtschema --upgrade

Please check and re-submit.


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q
  2022-09-06 13:33         ` Linus Walleij
@ 2022-09-06 13:53           ` Andy Shevchenko
  2022-09-06 14:19           ` Rob Herring
  1 sibling, 0 replies; 14+ messages in thread
From: Andy Shevchenko @ 2022-09-06 13:53 UTC (permalink / raw)
  To: Linus Walleij
  Cc: Martyn Welch, Bartosz Golaszewski, Rob Herring,
	Krzysztof Kozlowski, Martyn Welch, Krzysztof Kozlowski,
	linux-gpio, devicetree, linux-kernel

On Tue, Sep 06, 2022 at 03:33:34PM +0200, Linus Walleij wrote:
> On Tue, Sep 6, 2022 at 3:20 PM Andy Shevchenko
> <andriy.shevchenko@intel.com> wrote:
> > On Tue, Sep 06, 2022 at 03:08:00PM +0200, Linus Walleij wrote:
> > > On Tue, Sep 6, 2022 at 2:19 PM Andy Shevchenko
> > > <andriy.shevchenko@intel.com> wrote:
> > > > On Tue, Sep 06, 2022 at 09:28:16AM +0100, Martyn Welch wrote:

...

> > > > > +    oneOf:
> > > > > +      - items:
> > > > > +        - const: diodes,pi4ioe5v6534q
> > > > > +        - const: nxp,pcal6534
> > > >
> > > > ^^^
> > > >
> > > > > +      - items:
> > > > > +        - enum:
> > > >
> > > > > +          - nxp,pcal6534
> > > >
> > > > ^^^
> > > >
> > > > Not sure why is this dup?
> > >
> > > No that is how DT compatibles work. One version of the component,
> > > bought from NXP will look like this:
> > >
> > > compatible = "nxp,pcal6534";
> > >
> > > Another version bought from diodes will look like this:
> > >
> > > compatible = "diodes,pi4ioe5v6534q", "nxp,pcal6534";
> > >
> > > Then the drivers are probed matching from left to right,
> > > with the "most compatible" matching first.
> > >
> > > This also answers your question on the implementation.
> >
> > Then I don't understand why the const list above is only for new chips
> > and not for the old one where the same can be applied.
> 
> That's YAML. It's because the const list is the most compact way
> to express two precise items following after each other, and the enum
> list is an implicit list of single-item const:s, as you cannot enum
> tuples.

This makes a lot of sense, thank you for explaining this. Indeed, now I
understand the absence of Diodes in the code.

> > Mysterious ways of DT...
> 
> It's not DT, it's YAML that is mysterious. DT itself is a pretty
> straight-forward
> grammar, while YAML is a meta-grammar describing the DT grammar
> (ML stands for Meta Language).
> 
> All meta languages are mysterious.

Yeah :-)

-- 
With Best Regards,
Andy Shevchenko



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q
  2022-09-06 13:33         ` Linus Walleij
  2022-09-06 13:53           ` Andy Shevchenko
@ 2022-09-06 14:19           ` Rob Herring
  2022-09-06 14:31             ` Andy Shevchenko
  1 sibling, 1 reply; 14+ messages in thread
From: Rob Herring @ 2022-09-06 14:19 UTC (permalink / raw)
  To: Linus Walleij
  Cc: Andy Shevchenko, Martyn Welch, Bartosz Golaszewski,
	Krzysztof Kozlowski, Martyn Welch, Krzysztof Kozlowski,
	open list:GPIO SUBSYSTEM, devicetree,
	linux-kernel@vger.kernel.org

On Tue, Sep 6, 2022 at 8:33 AM Linus Walleij <linus.walleij@linaro.org> wrote:
>
> On Tue, Sep 6, 2022 at 3:20 PM Andy Shevchenko
> <andriy.shevchenko@intel.com> wrote:
> > On Tue, Sep 06, 2022 at 03:08:00PM +0200, Linus Walleij wrote:
> > > On Tue, Sep 6, 2022 at 2:19 PM Andy Shevchenko
> > > <andriy.shevchenko@intel.com> wrote:
> > > > On Tue, Sep 06, 2022 at 09:28:16AM +0100, Martyn Welch wrote:
> > > > > From: Martyn Welch <martyn.welch@collabora.com>
> > > > >
> > > > > The NXP PCAL6534 is a 34-bit I2C I/O expander similar to the PCAL6524. The
> > > > > Diodes PI4IOE5V6534Q is a functionally identical chip provided by Diodes
> > > > > Inc.
> > > >
> > > > ...
> > > >
> > > > > +    oneOf:
> > > > > +      - items:
> > > > > +        - const: diodes,pi4ioe5v6534q
> > > > > +        - const: nxp,pcal6534
> > > >
> > > > ^^^
> > > >
> > > > > +      - items:
> > > > > +        - enum:
> > > >
> > > > > +          - nxp,pcal6534
> > > >
> > > > ^^^
> > > >
> > > > Not sure why is this dup?
> > >
> > > No that is how DT compatibles work. One version of the component,
> > > bought from NXP will look like this:
> > >
> > > compatible = "nxp,pcal6534";
> > >
> > > Another version bought from diodes will look like this:
> > >
> > > compatible = "diodes,pi4ioe5v6534q", "nxp,pcal6534";
> > >
> > > Then the drivers are probed matching from left to right,
> > > with the "most compatible" matching first.
> > >
> > > This also answers your question on the implementation.
> >
> > Then I don't understand why the const list above is only for new chips
> > and not for the old one where the same can be applied.
>
> That's YAML. It's because the const list is the most compact way
> to express two precise items following after each other, and the enum
> list is an implicit list of single-item const:s, as you cannot enum
> tuples.
>
> > Mysterious ways of DT...
>
> It's not DT, it's YAML that is mysterious. DT itself is a pretty
> straight-forward
> grammar, while YAML is a meta-grammar describing the DT grammar

Not YAML, but json-schema is the grammar. YAML is just the file format
and it's a JSON compatible subset of YAML (no anchors, refs, tags).

> (ML stands for Meta Language).

Huh? yaml.org says: YAML Ain't Markup Language™

Rob

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q
  2022-09-06 14:19           ` Rob Herring
@ 2022-09-06 14:31             ` Andy Shevchenko
  0 siblings, 0 replies; 14+ messages in thread
From: Andy Shevchenko @ 2022-09-06 14:31 UTC (permalink / raw)
  To: Rob Herring
  Cc: Linus Walleij, Martyn Welch, Bartosz Golaszewski,
	Krzysztof Kozlowski, Martyn Welch, Krzysztof Kozlowski,
	open list:GPIO SUBSYSTEM, devicetree,
	linux-kernel@vger.kernel.org

On Tue, Sep 06, 2022 at 09:19:52AM -0500, Rob Herring wrote:
> On Tue, Sep 6, 2022 at 8:33 AM Linus Walleij <linus.walleij@linaro.org> wrote:
> > On Tue, Sep 6, 2022 at 3:20 PM Andy Shevchenko
> > <andriy.shevchenko@intel.com> wrote:
> > > On Tue, Sep 06, 2022 at 03:08:00PM +0200, Linus Walleij wrote:

...

> > > Mysterious ways of DT...
> >
> > It's not DT, it's YAML that is mysterious. DT itself is a pretty
> > straight-forward
> > grammar, while YAML is a meta-grammar describing the DT grammar
> 
> Not YAML, but json-schema is the grammar. YAML is just the file format
> and it's a JSON compatible subset of YAML (no anchors, refs, tags).
> 
> > (ML stands for Meta Language).
> 
> Huh? yaml.org says: YAML Ain't Markup Language™

But Markup != Meta :-)

-- 
With Best Regards,
Andy Shevchenko



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v2 1/5] dt-bindings: vendor-prefixes: add Diodes
  2022-09-06  8:28 [PATCH v2 1/5] dt-bindings: vendor-prefixes: add Diodes Martyn Welch
  2022-09-06  8:28 ` [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q Martyn Welch
@ 2022-09-09 13:27 ` Bartosz Golaszewski
  2022-09-09 13:28   ` Bartosz Golaszewski
  1 sibling, 1 reply; 14+ messages in thread
From: Bartosz Golaszewski @ 2022-09-09 13:27 UTC (permalink / raw)
  To: Martyn Welch
  Cc: Rob Herring, Krzysztof Kozlowski, Martyn Welch,
	Krzysztof Kozlowski, Rob Herring, devicetree, linux-kernel

On Tue, Sep 6, 2022 at 10:28 AM Martyn Welch
<martyn.welch@collabora.co.uk> wrote:
>
> From: Martyn Welch <martyn.welch@collabora.com>
>
> Diodes Incorporated is a manufacturer of application specific standard
> products within the discrete, logic, analog, and mixed-signal semiconductor
> markets.
>
> https://www.diodes.com/
>
> Signed-off-by: Martyn Welch <martyn.welch@collabora.com>
> Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
>
> Changes in v2:
>  - None
>
>  Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/vendor-prefixes.yaml b/Documentation/devicetree/bindings/vendor-prefixes.yaml
> index 2f0151e9f6be..7ee9b7692ed1 100644
> --- a/Documentation/devicetree/bindings/vendor-prefixes.yaml
> +++ b/Documentation/devicetree/bindings/vendor-prefixes.yaml
> @@ -328,6 +328,8 @@ patternProperties:
>      description: Digi International Inc.
>    "^digilent,.*":
>      description: Diglent, Inc.
> +  "^diodes,.*":
> +    description: Diodes, Inc.
>    "^dioo,.*":
>      description: Dioo Microcircuit Co., Ltd
>    "^dlc,.*":
> --
> 2.35.1
>

Picked up the entire series, thanks!

Bart

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v2 1/5] dt-bindings: vendor-prefixes: add Diodes
  2022-09-09 13:27 ` [PATCH v2 1/5] dt-bindings: vendor-prefixes: add Diodes Bartosz Golaszewski
@ 2022-09-09 13:28   ` Bartosz Golaszewski
  0 siblings, 0 replies; 14+ messages in thread
From: Bartosz Golaszewski @ 2022-09-09 13:28 UTC (permalink / raw)
  To: Martyn Welch
  Cc: Rob Herring, Krzysztof Kozlowski, Martyn Welch,
	Krzysztof Kozlowski, Rob Herring, devicetree, linux-kernel

On Fri, Sep 9, 2022 at 3:27 PM Bartosz Golaszewski <brgl@bgdev.pl> wrote:
>
> On Tue, Sep 6, 2022 at 10:28 AM Martyn Welch
> <martyn.welch@collabora.co.uk> wrote:
> >
> > From: Martyn Welch <martyn.welch@collabora.com>
> >
> > Diodes Incorporated is a manufacturer of application specific standard
> > products within the discrete, logic, analog, and mixed-signal semiconductor
> > markets.
> >
> > https://www.diodes.com/
> >
> > Signed-off-by: Martyn Welch <martyn.welch@collabora.com>
> > Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> > ---
> >
> > Changes in v2:
> >  - None
> >
> >  Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 ++
> >  1 file changed, 2 insertions(+)
> >
> > diff --git a/Documentation/devicetree/bindings/vendor-prefixes.yaml b/Documentation/devicetree/bindings/vendor-prefixes.yaml
> > index 2f0151e9f6be..7ee9b7692ed1 100644
> > --- a/Documentation/devicetree/bindings/vendor-prefixes.yaml
> > +++ b/Documentation/devicetree/bindings/vendor-prefixes.yaml
> > @@ -328,6 +328,8 @@ patternProperties:
> >      description: Digi International Inc.
> >    "^digilent,.*":
> >      description: Diglent, Inc.
> > +  "^diodes,.*":
> > +    description: Diodes, Inc.
> >    "^dioo,.*":
> >      description: Dioo Microcircuit Co., Ltd
> >    "^dlc,.*":
> > --
> > 2.35.1
> >
>
> Picked up the entire series, thanks!
>
> Bart

Scratch that, missed Rob's comment under the other patch.

Bart

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2022-09-09 13:28 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-09-06  8:28 [PATCH v2 1/5] dt-bindings: vendor-prefixes: add Diodes Martyn Welch
2022-09-06  8:28 ` [PATCH v2 2/5] dt-bindings: gpio: pca95xx: add entry for pcal6534 and PI4IOE5V6534Q Martyn Welch
2022-09-06  8:37   ` Krzysztof Kozlowski
2022-09-06 12:19   ` Andy Shevchenko
2022-09-06 13:08     ` Linus Walleij
2022-09-06 13:19       ` Andy Shevchenko
2022-09-06 13:33         ` Linus Walleij
2022-09-06 13:53           ` Andy Shevchenko
2022-09-06 14:19           ` Rob Herring
2022-09-06 14:31             ` Andy Shevchenko
2022-09-06 13:05   ` Linus Walleij
2022-09-06 13:40   ` Rob Herring
2022-09-09 13:27 ` [PATCH v2 1/5] dt-bindings: vendor-prefixes: add Diodes Bartosz Golaszewski
2022-09-09 13:28   ` Bartosz Golaszewski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).