Re: [PATCH 1/6] dt-bindings: regulator: palmas: Convert to json-schema

Rob Herring
2021-12-18T18:08:31Z

On Fri, 17 Dec 2021 18:05:02 +0100, Thierry Reding wrote:
> From: Thierry Reding <treding@nvidia.com>
>
> Convert the Texas Instruments Palmas bindings from the free-form text
> format to json-schema.
>
> Signed-off-by: Thierry Reding <treding@nvidia.com>
> ---
> .../clock/clk-palmas-clk32kg-clocks.txt | 35 ----
> .../bindings/clock/ti,palmas-clk32k.yaml | 68 ++++++++
> .../bindings/extcon/extcon-palmas.txt | 22 ---
> .../bindings/extcon/ti,palmas-usb-vid.yaml | 65 ++++++++
> .../devicetree/bindings/gpio/gpio-palmas.txt | 27 ---
> .../bindings/gpio/ti,palmas-gpio.yaml | 53 ++++++
> .../bindings/iio/adc/ti,palmas-gpadc.yaml | 26 ++-
> .../bindings/input/ti,palmas-pwrbutton.txt | 35 ----
> .../bindings/input/ti,palmas-pwrbutton.yaml | 76 +++++++++
> .../devicetree/bindings/mfd/palmas.txt | 52 ------
> .../devicetree/bindings/mfd/ti,palmas.yaml | 117 +++++++++++++
> .../bindings/pinctrl/pinctrl-palmas.txt | 105 ------------
> .../bindings/pinctrl/ti,palmas-pinctrl.yaml | 154 ++++++++++++++++++
> .../bindings/regulator/palmas-pmic.txt | 89 ----------
> .../bindings/regulator/ti,palmas-pmic.yaml | 144 ++++++++++++++++
> .../devicetree/bindings/rtc/rtc-palmas.txt | 32 ----
> .../bindings/rtc/ti,palmas-rtc.yaml | 62 +++++++
> 17 files changed, 756 insertions(+), 406 deletions(-)
> delete mode 100644 Documentation/devicetree/bindings/clock/clk-palmas-clk32kg-clocks.txt
> create mode 100644 Documentation/devicetree/bindings/clock/ti,palmas-clk32k.yaml
> delete mode 100644 Documentation/devicetree/bindings/extcon/extcon-palmas.txt
> create mode 100644 Documentation/devicetree/bindings/extcon/ti,palmas-usb-vid.yaml
> delete mode 100644 Documentation/devicetree/bindings/gpio/gpio-palmas.txt
> create mode 100644 Documentation/devicetree/bindings/gpio/ti,palmas-gpio.yaml
> delete mode 100644 Documentation/devicetree/bindings/input/ti,palmas-pwrbutton.txt
> create mode 100644 Documentation/devicetree/bindings/input/ti,palmas-pwrbutton.yaml
> delete mode 100644 Documentation/devicetree/bindings/mfd/palmas.txt
> create mode 100644 Documentation/devicetree/bindings/mfd/ti,palmas.yaml
> delete mode 100644 Documentation/devicetree/bindings/pinctrl/pinctrl-palmas.txt
> create mode 100644 Documentation/devicetree/bindings/pinctrl/ti,palmas-pinctrl.yaml
> delete mode 100644 Documentation/devicetree/bindings/regulator/palmas-pmic.txt
> create mode 100644 Documentation/devicetree/bindings/regulator/ti,palmas-pmic.yaml
> delete mode 100644 Documentation/devicetree/bindings/rtc/rtc-palmas.txt
> create mode 100644 Documentation/devicetree/bindings/rtc/ti,palmas-rtc.yaml
>

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:

dtschema/dtc warnings/errors:
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/regulator/ti,palmas-pmic.example.dt.yaml: pmic: 'interrupts-name', 'ti,system-power-controller' do not match any of the regexes: '^ldo([1-9]|ln|usb)-in-supply$', '^smps(([1-9]|10)-in-)|(smps10-out2-)supply$', 'pinctrl-[0-9]+'
From schema: /builds/robherring/linux-dt-review/Documentation/devicetree/bindings/regulator/ti,palmas-pmic.yaml
Documentation/devicetree/bindings/iio/adc/ti,palmas-gpadc.example.dts:27.13-26: Warning (reg_format): /example-0/i2c/pmic@48:reg: property has invalid length (4 bytes) (#address-cells == 1, #size-cells == 1)
Documentation/devicetree/bindings/iio/adc/ti,palmas-gpadc.example.dt.yaml: Warning (pci_device_reg): Failed prerequisite 'reg_format'
Documentation/devicetree/bindings/iio/adc/ti,palmas-gpadc.example.dt.yaml: Warning (pci_device_bus_num): Failed prerequisite 'reg_format'
Documentation/devicetree/bindings/iio/adc/ti,palmas-gpadc.example.dt.yaml: Warning (simple_bus_reg): Failed prerequisite 'reg_format'
Documentation/devicetree/bindings/iio/adc/ti,palmas-gpadc.example.dts:21.13-39.11: Warning (i2c_bus_bridge): /example-0/i2c: incorrect #size-cells for I2C bus
Documentation/devicetree/bindings/iio/adc/ti,palmas-gpadc.example.dt.yaml: Warning (i2c_bus_reg): Failed prerequisite 'reg_format'
Documentation/devicetree/bindings/iio/adc/ti,palmas-gpadc.example.dt.yaml: Warning (i2c_bus_reg): Failed prerequisite 'i2c_bus_bridge'
Documentation/devicetree/bindings/iio/adc/ti,palmas-gpadc.example.dt.yaml: Warning (spi_bus_reg): Failed prerequisite 'reg_format'
Documentation/devicetree/bindings/iio/adc/ti,palmas-gpadc.example.dts:25.19-38.13: Warning (avoid_default_addr_size): /example-0/i2c/pmic@48: Relying on default #size-cells value
Documentation/devicetree/bindings/iio/adc/ti,palmas-gpadc.example.dt.yaml: Warning (unique_unit_address): Failed prerequisite 'avoid_default_addr_size'
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/iio/adc/ti,palmas-gpadc.example.dt.yaml: pmic@48: compatible:0: 'ti,palmas' is not one of ['ti,twl6035', 'ti,twl6036', 'ti,twl6037', 'ti,tps65913', 'ti,tps65914', 'ti,tps80036', 'ti,tps659038', 'ti,tps65917']
From schema: /builds/robherring/linux-dt-review/Documentation/devicetree/bindings/mfd/ti,palmas.yaml
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/iio/adc/ti,palmas-gpadc.example.dt.yaml: pmic@48: compatible: ['ti,palmas'] is too short
From schema: /builds/robherring/linux-dt-review/Documentation/devicetree/bindings/mfd/ti,palmas.yaml
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/iio/adc/ti,palmas-gpadc.example.dt.yaml: pmic@48: 'interrupt-controller' is a required property
From schema: /builds/robherring/linux-dt-review/Documentation/devicetree/bindings/mfd/ti,palmas.yaml
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/iio/adc/ti,palmas-gpadc.example.dt.yaml: pmic@48: '#interrupt-cells' is a required property
From schema: /builds/robherring/linux-dt-review/Documentation/devicetree/bindings/mfd/ti,palmas.yaml

doc reference errors (make refcheckdocs):
Warning: Documentation/devicetree/bindings/input/ti,palmas-pwrbutton.yaml references a file that doesn't exist: Documentation/devicetree/bindings/mfd/palmas.txt
Documentation/devicetree/bindings/input/ti,palmas-pwrbutton.yaml: Documentation/devicetree/bindings/mfd/palmas.txt

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

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.