[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200430152414.GA19887@bogus>
Date: Thu, 30 Apr 2020 10:24:14 -0500
From: Rob Herring <robh@...nel.org>
To: Chris Ruehl <chris.ruehl@...ys.com.hk>
Cc: devicetree@...r.kernel.org,
Michael Hennerich <michael.hennerich@...log.com>,
Jonathan Cameron <jic23@...nel.org>,
Hartmut Knaack <knaack.h@....de>,
Lars-Peter Clausen <lars@...afoo.de>,
Peter Meerwald-Stadler <pmeerw@...erw.net>,
Uwe Kleine-König
<u.kleine-koenig@...gutronix.de>,
Alexios Zavras <alexios.zavras@...el.com>,
Steve Winslow <swinslow@...il.com>,
Thomas Gleixner <tglx@...utronix.de>,
linux-iio@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v5 3/3] iio/dac: convert ltc2632.txt to lltc,ltc2632.yaml
On Mon, Apr 20, 2020 at 12:26:08PM +0800, Chris Ruehl wrote:
> Conversion of the ltc2632 to yaml format and name the file 'lltc,ltc2632.yaml'.
>
> Signed-off-by: Chris Ruehl <chris.ruehl@...ys.com.hk>
> ---
> v5:
> correct require section
> set maintainer of analog.com
> v4..v2: no change
>
> .../bindings/iio/dac/lltc,ltc2632.yaml | 76 +++++++++++++++++++
> .../devicetree/bindings/iio/dac/ltc2632.txt | 49 ------------
> 2 files changed, 76 insertions(+), 49 deletions(-)
> create mode 100644 Documentation/devicetree/bindings/iio/dac/lltc,ltc2632.yaml
> delete mode 100644 Documentation/devicetree/bindings/iio/dac/ltc2632.txt
>
> diff --git a/Documentation/devicetree/bindings/iio/dac/lltc,ltc2632.yaml b/Documentation/devicetree/bindings/iio/dac/lltc,ltc2632.yaml
> new file mode 100644
> index 000000000000..b0043144fbc4
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/iio/dac/lltc,ltc2632.yaml
> @@ -0,0 +1,76 @@
> +# SPDX-License-Identifier: GPL-2.0 OR BSD-2-Clause
> +%YAML 1.2
> +---
> +$id: "http://devicetree.org/schemas/iio/dac/lltc,ltc2632.yaml#"
> +$schema: "http://devicetree.org/meta-schemas/core.yaml#"
> +
> +title: Linear Technology LTC263x 12-/10-/8-Bit Rail-to-Rail DAC
> +
> +maintainers:
> + - Michael Hennerich <michael.hennerich@...log.com>
> +
> +description: |
> + Bindings for the Linear Technology LTC2632/2634/2636 DAC
> + Datasheet can be found here: https://www.analog.com/media/en/technical-documentation/data-sheets/LTC263[246].pdf
> +
> +properties:
> + compatible:
> + enum:
> + - lltc,ltc2632-l12
> + - lltc,ltc2632-l10
> + - lltc,ltc2632-l8
> + - lltc,ltc2632-h12
> + - lltc,ltc2632-h10
> + - lltc,ltc2632-h8
> + - lltc,ltc2634-l12
> + - lltc,ltc2634-l10
> + - lltc,ltc2634-l8
> + - lltc,ltc2634-h12
> + - lltc,ltc2634-h10
> + - lltc,ltc2634-h8
> + - lltc,ltc2636-l12
> + - lltc,ltc2636-l10
> + - lltc,ltc2636-l8
> + - lltc,ltc2636-h12
> + - lltc,ltc2636-h10
> + - lltc,ltc2636-h8
> +
> + reg:
> + maxItems: 1
> +
> + spi-max-frequency:
> + maximum: 2000000
> +
> + vref-supply:
> + description:
> + Phandle to the external reference voltage supply. This should
There's a tab here which the yaml parser isn't going to like. Not sure
why my checker didn't run on this, but make sure 'make dt_binding_check'
passes.
> + only be set if there is an external reference voltage connected to the VREF
> + pin. If the property is not set the internal reference is used.
> +
> +required:
> + - compatible
> + - reg
> +
> +additionalProperties: false
> +
> +examples:
> + - |
> + vref: regulator-vref {
> + compatible = "regulator-fixed";
> + regulator-name = "vref-ltc2632";
> + regulator-min-microvolt = <1250000>;
> + regulator-max-microvolt = <1250000>;
> + regulator-always-on;
> + };
> +
> + spi_master {
spi {
> + #address-cells = <1>;
> + #size-cells = <0>;
> +
> + dac: ltc2632@0 {
dac@0
And drop the unused label.
> + compatible = "lltc,ltc2632";
> + reg = <0>; /* CS0 */
> + spi-max-frequency = <1000000>;
> + vref-supply = <&vref>;
> + };
> + };
> diff --git a/Documentation/devicetree/bindings/iio/dac/ltc2632.txt b/Documentation/devicetree/bindings/iio/dac/ltc2632.txt
> deleted file mode 100644
> index 1ab9570cf219..000000000000
> --- a/Documentation/devicetree/bindings/iio/dac/ltc2632.txt
> +++ /dev/null
> @@ -1,49 +0,0 @@
> -Linear Technology LTC2632/2634/2636 DAC
> -
> -Required properties:
> - - compatible: Has to contain one of the following:
> - lltc,ltc2632-l12
> - lltc,ltc2632-l10
> - lltc,ltc2632-l8
> - lltc,ltc2632-h12
> - lltc,ltc2632-h10
> - lltc,ltc2632-h8
> - lltc,ltc2634-l12
> - lltc,ltc2634-l10
> - lltc,ltc2634-l8
> - lltc,ltc2634-h12
> - lltc,ltc2634-h10
> - lltc,ltc2634-h8
> - lltc,ltc2636-l12
> - lltc,ltc2636-l10
> - lltc,ltc2636-l8
> - lltc,ltc2636-h12
> - lltc,ltc2636-h10
> - lltc,ltc2636-h8
> -
> -Property rules described in Documentation/devicetree/bindings/spi/spi-bus.txt
> -apply. In particular, "reg" and "spi-max-frequency" properties must be given.
> -
> -Optional properties:
> - - vref-supply: Phandle to the external reference voltage supply. This should
> - only be set if there is an external reference voltage connected to the VREF
> - pin. If the property is not set the internal reference is used.
> -
> -Example:
> -
> - vref: regulator-vref {
> - compatible = "regulator-fixed";
> - regulator-name = "vref-ltc2632";
> - regulator-min-microvolt = <1250000>;
> - regulator-max-microvolt = <1250000>;
> - regulator-always-on;
> - };
> -
> - spi_master {
> - dac: ltc2632@0 {
> - compatible = "lltc,ltc2632-l12";
> - reg = <0>; /* CS0 */
> - spi-max-frequency = <1000000>;
> - vref-supply = <&vref>; /* optional */
> - };
> - };
> --
> 2.20.1
>
Powered by blists - more mailing lists