diff mbox series

[18/29] dt-bindings:iio:dac:maxim,ds4424 yaml conversion

Message ID 20201011170749.243680-19-jic23@kernel.org (mailing list archive)
State New
Headers show
Series dt-bindings:iio: Another set of yaml conversions. | expand

Commit Message

Jonathan Cameron Oct. 11, 2020, 5:07 p.m. UTC
From: Jonathan Cameron <Jonathan.Cameron@huawei.com>

Simple conversion of this straight forward binding.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Cc: Ismail H. Kose <Ismail.Kose@maximintegrated.com>
Cc: Ismail H. Kose <ihkose@gmail.com>
---
 .../devicetree/bindings/iio/dac/ds4424.txt    | 20 ---------
 .../bindings/iio/dac/maxim,ds4424.yaml        | 45 +++++++++++++++++++
 2 files changed, 45 insertions(+), 20 deletions(-)

Comments

Jonathan Cameron Oct. 18, 2020, 5:47 p.m. UTC | #1
On Sun, 11 Oct 2020 18:07:38 +0100
Jonathan Cameron <jic23@kernel.org> wrote:

> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> 
> Simple conversion of this straight forward binding.
> 
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Cc: Ismail H. Kose <Ismail.Kose@maximintegrated.com>
> Cc: Ismail H. Kose <ihkose@gmail.com>
Ismail's Maxim address bounces, so I've switched to the gmail one
for v2.  @Ismail: If you'd rather not be listed as maintaining this
binding then let me know.

Thanks,

Jonathan

> ---
>  .../devicetree/bindings/iio/dac/ds4424.txt    | 20 ---------
>  .../bindings/iio/dac/maxim,ds4424.yaml        | 45 +++++++++++++++++++
>  2 files changed, 45 insertions(+), 20 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/iio/dac/ds4424.txt b/Documentation/devicetree/bindings/iio/dac/ds4424.txt
> deleted file mode 100644
> index eaebbf8dab40..000000000000
> --- a/Documentation/devicetree/bindings/iio/dac/ds4424.txt
> +++ /dev/null
> @@ -1,20 +0,0 @@
> -Maxim Integrated DS4422/DS4424 7-bit Sink/Source Current DAC Device Driver
> -
> -Datasheet publicly available at:
> -https://datasheets.maximintegrated.com/en/ds/DS4422-DS4424.pdf
> -
> -Required properties:
> -	- compatible: Should be one of
> -		maxim,ds4422
> -		maxim,ds4424
> -	- reg: Should contain the DAC I2C address
> -
> -Optional properties:
> -	- vcc-supply: Power supply is optional. If not defined, driver will ignore it.
> -
> -Example:
> -	ds4224@10 {
> -		compatible = "maxim,ds4424";
> -		reg = <0x10>; /* When A0, A1 pins are ground */
> -		vcc-supply = <&vcc_3v3>;
> -	};
> diff --git a/Documentation/devicetree/bindings/iio/dac/maxim,ds4424.yaml b/Documentation/devicetree/bindings/iio/dac/maxim,ds4424.yaml
> new file mode 100644
> index 000000000000..91661079d7ea
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/iio/dac/maxim,ds4424.yaml
> @@ -0,0 +1,45 @@
> +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/iio/dac/maxim,ds4424.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Maxim Integrated DS4422/DS4424 7-bit Sink/Source Current DAC
> +
> +maintainers:
> +  - Ismail H. Kose <Ismail.Kose@maximintegrated.com>
> +
> +description: |
> +  Datasheet publicly available at:
> +  https://datasheets.maximintegrated.com/en/ds/DS4422-DS4424.pdf
> +
> +properties:
> +  compatible:
> +    enum:
> +      - maxim,ds4422
> +      - maxim,ds4424
> +
> +  reg:
> +    maxItems: 1
> +
> +  vcc-supply: true
> +
> +required:
> +  - compatible
> +  - reg
> +
> +additionalProperties: false
> +
> +examples:
> +  - |
> +    i2c {
> +        #address-cells = <1>;
> +        #size-cells = <0>;
> +
> +        dac@10 {
> +            compatible = "maxim,ds4424";
> +            reg = <0x10>; /* When A0, A1 pins are ground */
> +            vcc-supply = <&vcc_3v3>;
> +        };
> +    };
> +...
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/iio/dac/ds4424.txt b/Documentation/devicetree/bindings/iio/dac/ds4424.txt
deleted file mode 100644
index eaebbf8dab40..000000000000
--- a/Documentation/devicetree/bindings/iio/dac/ds4424.txt
+++ /dev/null
@@ -1,20 +0,0 @@ 
-Maxim Integrated DS4422/DS4424 7-bit Sink/Source Current DAC Device Driver
-
-Datasheet publicly available at:
-https://datasheets.maximintegrated.com/en/ds/DS4422-DS4424.pdf
-
-Required properties:
-	- compatible: Should be one of
-		maxim,ds4422
-		maxim,ds4424
-	- reg: Should contain the DAC I2C address
-
-Optional properties:
-	- vcc-supply: Power supply is optional. If not defined, driver will ignore it.
-
-Example:
-	ds4224@10 {
-		compatible = "maxim,ds4424";
-		reg = <0x10>; /* When A0, A1 pins are ground */
-		vcc-supply = <&vcc_3v3>;
-	};
diff --git a/Documentation/devicetree/bindings/iio/dac/maxim,ds4424.yaml b/Documentation/devicetree/bindings/iio/dac/maxim,ds4424.yaml
new file mode 100644
index 000000000000..91661079d7ea
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/dac/maxim,ds4424.yaml
@@ -0,0 +1,45 @@ 
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/dac/maxim,ds4424.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Maxim Integrated DS4422/DS4424 7-bit Sink/Source Current DAC
+
+maintainers:
+  - Ismail H. Kose <Ismail.Kose@maximintegrated.com>
+
+description: |
+  Datasheet publicly available at:
+  https://datasheets.maximintegrated.com/en/ds/DS4422-DS4424.pdf
+
+properties:
+  compatible:
+    enum:
+      - maxim,ds4422
+      - maxim,ds4424
+
+  reg:
+    maxItems: 1
+
+  vcc-supply: true
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        dac@10 {
+            compatible = "maxim,ds4424";
+            reg = <0x10>; /* When A0, A1 pins are ground */
+            vcc-supply = <&vcc_3v3>;
+        };
+    };
+...