Re: [PATCH v2] dt-bindings: hwmon: Convert NTC thermistor to YAML

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jul 12, 2021 at 4:57 PM Rob Herring <robh@xxxxxxxxxx> wrote:
> On Sat, Jul 03, 2021 at 07:34:56PM +0200, Linus Walleij wrote:

> > +  compatible:
> > +    oneOf:
> > +      - const: epcos,b57330v2103
> > +      - const: epcos,b57891s0103
> > +      - const: murata,ncp15wb473
> > +      - const: murata,ncp18wb473
> > +      - const: murata,ncp21wb473
> > +      - const: murata,ncp03wb473
> > +      - const: murata,ncp15wl333
> > +      - const: murata,ncp03wf104
> > +      - const: murata,ncp15xh103
>
> All these can be 1 enum.

Yes that works fine.

> > +      # Deprecated "ntp," compatible strings
> > +      - const: ntc,ncp15wb473
> > +        deprecated: true
> > +      - const: ntc,ncp18wb473
> > +        deprecated: true
> > +      - const: ntc,ncp21wb473
> > +        deprecated: true
> > +      - const: ntc,ncp03wb473
> > +        deprecated: true
> > +      - const: ntc,ncp15wl333
> > +        deprecated: true
>
> And these too.

How? I'm lost here.

This:

  compatible:
    enum:
      - epcos,b57330v2103
      - epcos,b57891s0103
      - murata,ncp15wb473
      - murata,ncp18wb473
      - murata,ncp21wb473
      - murata,ncp03wb473
      - murata,ncp15wl333
      - murata,ncp03wf104
      - murata,ncp15xh103
      # Deprecated "ntp," compatible strings
      - ntc,ncp15wb473
        deprecated: true
      - ntc,ncp18wb473
        deprecated: true
      - ntc,ncp21wb473
        deprecated: true
      - ntc,ncp03wb473
        deprecated: true
      - ntc,ncp15wl333
        deprecated: true

Yields this:

uamel.yaml.scanner.ScannerError: mapping values are not allowed here
  in "<unicode string>", line 81, column 19:
            deprecated: true
                      ^ (line: 81)
make[3]: *** [../Documentation/devicetree/bindings/Makefile:20:
Documentation/devicetree/bindings/hwmon/ntc-thermistor.example.dts]
Error 1
make[3]: *** Deleting file
'Documentation/devicetree/bindings/hwmon/ntc-thermistor.example.dts'
../Documentation/devicetree/bindings/hwmon/ntc-thermistor.yaml:81:19:
[error] syntax error: mapping values are not allowed here (syntax)

This does not happen with oneOf const:s.

Yours,
Linus Walleij



[Index of Archives]     [LM Sensors]     [Linux Sound]     [ALSA Users]     [ALSA Devel]     [Linux Audio Users]     [Linux Media]     [Kernel]     [Gimp]     [Yosemite News]     [Linux Media]

  Powered by Linux