linux-iio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/13] dt-bindings: yaml conversions of some simple ADC bindings.
@ 2020-08-09 11:17 Jonathan Cameron
  2020-08-09 11:17 ` [PATCH 01/13] dt-bindings: iio: adc: microchip,mcp3201 yaml conversion Jonathan Cameron
                   ` (12 more replies)
  0 siblings, 13 replies; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-09 11:17 UTC (permalink / raw)
  To: linux-iio; +Cc: Rob Herring, devicetree, Jonathan Cameron

From: Jonathan Cameron <Jonathan.Cameron@huawei.com>

This set coverts over some of the low hanging fruit from amongst the IIO
ADC bindings.  Mostly they are very straight forward bindings.

One quirk is that I found I had one old binding doc in my local
checked out copy that never made it into mainline. I've created
a special patch for that so we don't lose the history.  It reflects
the tags from the original patch that I seem to have messed up applying.

I've added the #io-channel-cells property to  most of them, so that
additionalProperties: false works if they are used as providers
of channels to consumers.  For ADCs it is fairly likely they
will be providing measurement services to another device in DT.

I have put the Maintainer as the original author of the old bindings
/ driver. Hopefully everyone is fine with that. If not, let me know
and I'll put my own details in there as I'll end up reviewing pretty
much anything that touches these anyway.

All comments welcome.

Jonathan Cameron (12):
  dt-bindings: iio: adc: microchip,mcp3201 yaml conversion.
  dt-bindings: trivial-devices: Add mcp342x ADCs and drop separate
    binding doc.
  dt-bindings: iio: adc: ti,adc108s102 yaml conversion
  dt-bindings: iio: adc: lltc,ltc2497 yaml conversion.
  dt-bindings: iio: adc: ti,adc161s626 yaml conversion.
  dt-bindings: iio: adc: ti,adc0832 yaml conversion.
  dt-bindings: iio: adc: ti,adc084s021 yaml conversion
  dt-bindings: iio: adc: ti,adc12138 yaml conversion.
  dt-bindings: iio: adc: ti,adc128s052 yaml conversion.
  dt-bindings: iio: adc: ti,ads7950 binding conversion
  dt-bindings: iio: adc: ti,ads8344 yaml conversion
  dt-bindings: iio: adc: ti,tlc4541 binding conversion

Phil Reid (1):
  dt-bindings: iio: adc: tlc4541 - recover accidentally dropped binding
    doc

 .../bindings/iio/adc/lltc,ltc2497.yaml        | 44 +++++++++
 .../devicetree/bindings/iio/adc/ltc2497.txt   | 13 ---
 .../devicetree/bindings/iio/adc/mcp320x.txt   | 57 ------------
 .../devicetree/bindings/iio/adc/mcp3422.txt   | 19 ----
 .../bindings/iio/adc/microchip,mcp3201.yaml   | 93 +++++++++++++++++++
 .../bindings/iio/adc/ti,adc0832.yaml          | 56 +++++++++++
 .../bindings/iio/adc/ti,adc084s021.yaml       | 58 ++++++++++++
 .../bindings/iio/adc/ti,adc108s102.yaml       | 47 ++++++++++
 .../bindings/iio/adc/ti,adc12138.yaml         | 85 +++++++++++++++++
 .../bindings/iio/adc/ti,adc128s052.yaml       | 59 ++++++++++++
 .../bindings/iio/adc/ti,adc161s626.yaml       | 51 ++++++++++
 .../bindings/iio/adc/ti,ads7950.yaml          | 64 +++++++++++++
 .../bindings/iio/adc/ti,ads8344.yaml          | 51 ++++++++++
 .../bindings/iio/adc/ti,tlc4541.yaml          | 52 +++++++++++
 .../bindings/iio/adc/ti-adc0832.txt           | 19 ----
 .../bindings/iio/adc/ti-adc084s021.txt        | 19 ----
 .../bindings/iio/adc/ti-adc108s102.txt        | 18 ----
 .../bindings/iio/adc/ti-adc12138.txt          | 37 --------
 .../bindings/iio/adc/ti-adc128s052.txt        | 25 -----
 .../bindings/iio/adc/ti-adc161s626.txt        | 18 ----
 .../bindings/iio/adc/ti-ads7950.txt           | 23 -----
 .../bindings/iio/adc/ti-ads8344.txt           | 19 ----
 .../devicetree/bindings/trivial-devices.yaml  | 16 ++++
 23 files changed, 676 insertions(+), 267 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/iio/adc/lltc,ltc2497.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/adc/ltc2497.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/adc/mcp320x.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/adc/mcp3422.txt
 create mode 100644 Documentation/devicetree/bindings/iio/adc/microchip,mcp3201.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/adc/ti,adc0832.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/adc/ti,adc084s021.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/adc/ti,adc108s102.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/adc/ti,adc12138.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/adc/ti,adc128s052.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/adc/ti,adc161s626.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/adc/ti,ads7950.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/adc/ti,ads8344.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/adc/ti,tlc4541.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/adc/ti-adc0832.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/adc/ti-adc084s021.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/adc/ti-adc108s102.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/adc/ti-adc12138.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/adc/ti-adc128s052.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/adc/ti-adc161s626.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/adc/ti-ads7950.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/adc/ti-ads8344.txt

-- 
2.28.0


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

* [PATCH 01/13] dt-bindings: iio: adc: microchip,mcp3201 yaml conversion.
  2020-08-09 11:17 [PATCH 00/13] dt-bindings: yaml conversions of some simple ADC bindings Jonathan Cameron
@ 2020-08-09 11:17 ` Jonathan Cameron
  2020-08-18  2:24   ` Rob Herring
  2020-08-09 11:17 ` [PATCH 02/13] dt-bindings: trivial-devices: Add mcp342x ADCs and drop separate binding doc Jonathan Cameron
                   ` (11 subsequent siblings)
  12 siblings, 1 reply; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-09 11:17 UTC (permalink / raw)
  To: linux-iio; +Cc: Rob Herring, devicetree, Jonathan Cameron, Oskar Andero

From: Jonathan Cameron <Jonathan.Cameron@huawei.com>

Drops the deprecated compatibles without the vendor name.
Whilst the driver continues to support these for old dt blobs,
any dt bindings that are actuallly verified against this document should
be fixed to add the vendor name.

Enforces rule that spi-cpol == spi-cpha.  Is there a cleaner way to
do this?

Added the #io-channel-cells property to allow for consumers.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Cc: Oskar Andero <oskar.andero@gmail.com>
---
 .../devicetree/bindings/iio/adc/mcp320x.txt   | 57 ------------
 .../bindings/iio/adc/microchip,mcp3201.yaml   | 93 +++++++++++++++++++
 2 files changed, 93 insertions(+), 57 deletions(-)

diff --git a/Documentation/devicetree/bindings/iio/adc/mcp320x.txt b/Documentation/devicetree/bindings/iio/adc/mcp320x.txt
deleted file mode 100644
index 56373d643f76..000000000000
--- a/Documentation/devicetree/bindings/iio/adc/mcp320x.txt
+++ /dev/null
@@ -1,57 +0,0 @@
-* Microchip Analog to Digital Converter (ADC)
-
-The node for this driver must be a child node of a SPI controller, hence
-all mandatory properties described in
-
-        Documentation/devicetree/bindings/spi/spi-bus.txt
-
-must be specified.
-
-Required properties:
-	- compatible:  	Must be one of the following, depending on the
-			model:
-				"mcp3001" (DEPRECATED)
-				"mcp3002" (DEPRECATED)
-				"mcp3004" (DEPRECATED)
-				"mcp3008" (DEPRECATED)
-				"mcp3201" (DEPRECATED)
-				"mcp3202" (DEPRECATED)
-				"mcp3204" (DEPRECATED)
-				"mcp3208" (DEPRECATED)
-				"mcp3301" (DEPRECATED)
-
-				"microchip,mcp3001"
-				"microchip,mcp3002"
-				"microchip,mcp3004"
-				"microchip,mcp3008"
-				"microchip,mcp3201"
-				"microchip,mcp3202"
-				"microchip,mcp3204"
-				"microchip,mcp3208"
-				"microchip,mcp3301"
-				"microchip,mcp3550-50"
-				"microchip,mcp3550-60"
-				"microchip,mcp3551"
-				"microchip,mcp3553"
-
-			NOTE: The use of the compatibles with no vendor prefix
-			is deprecated and only listed because old DT use them.
-
-	- spi-cpha, spi-cpol (boolean):
-			Either SPI mode (0,0) or (1,1) must be used, so specify
-			none or both of spi-cpha, spi-cpol.  The MCP3550/1/3
-			is more efficient in mode (1,1) as only 3 instead of
-			4 bytes need to be read from the ADC, but not all SPI
-			masters support it.
-
-	- vref-supply:	Phandle to the external reference voltage supply.
-
-Examples:
-spi_controller {
-	mcp3x0x@0 {
-		compatible = "microchip,mcp3002";
-		reg = <0>;
-		spi-max-frequency = <1000000>;
-		vref-supply = <&vref_reg>;
-	};
-};
diff --git a/Documentation/devicetree/bindings/iio/adc/microchip,mcp3201.yaml b/Documentation/devicetree/bindings/iio/adc/microchip,mcp3201.yaml
new file mode 100644
index 000000000000..38dfb856da62
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/adc/microchip,mcp3201.yaml
@@ -0,0 +1,93 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/adc/microchip,mcp3201.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Microchip mcp3201 and similar ADCs
+
+maintainers:
+  - Oskar Andero <oskar.andero@gmail.com>
+
+description: |
+   Family of simple ADCs with an I2C inteface.
+
+properties:
+  compatible:
+    enum:
+      - microchip,mcp3001
+      - microchip,mcp3002
+      - microchip,mcp3004
+      - microchip,mcp3008
+      - microchip,mcp3201
+      - microchip,mcp3202
+      - microchip,mcp3204
+      - microchip,mcp3208
+      - microchip,mcp3301
+      - microchip,mcp3550-50
+      - microchip,mcp3550-60
+      - microchip,mcp3551
+      - microchip,mcp3553
+
+  reg:
+    maxItems: 1
+
+  spi-max-frequency: true
+  spi-cpha: true
+  spi-cpol: true
+
+  vref-supply:
+    description: External reference.
+
+  "#io-channel-cells":
+    const: 1
+
+allOf:
+  - if:
+      required:
+        - spi-cpha
+    then:
+      required:
+        - spi-cpol
+    else:
+      properties:
+        spi-cpol: false
+  - if:
+      required:
+        - spi-cpol
+    then:
+      required:
+        - spi-cpha
+    else:
+      properties:
+        spi-cpha: false
+
+required:
+  - compatible
+  - reg
+  - vref-supply
+
+additionalProperties: false
+
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        adc@0 {
+            compatible = "microchip,mcp3002";
+            reg = <0>;
+            vref-supply = <&vref_reg>;
+            spi-cpha;
+            spi-cpol;
+            #io-channel-cells = <1>;
+        };
+        adc@1 {
+            compatible = "microchip,mcp3002";
+            reg = <1>;
+            vref-supply = <&vref_reg>;
+            spi-max-frequency = <1500000>;
+        };
+    };
+...
-- 
2.28.0


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

* [PATCH 02/13] dt-bindings: trivial-devices: Add mcp342x ADCs and drop separate binding doc.
  2020-08-09 11:17 [PATCH 00/13] dt-bindings: yaml conversions of some simple ADC bindings Jonathan Cameron
  2020-08-09 11:17 ` [PATCH 01/13] dt-bindings: iio: adc: microchip,mcp3201 yaml conversion Jonathan Cameron
@ 2020-08-09 11:17 ` Jonathan Cameron
  2020-08-18  2:27   ` Rob Herring
  2020-08-09 11:17 ` [PATCH 03/13] dt-bindings: iio: adc: ti,adc108s102 yaml conversion Jonathan Cameron
                   ` (10 subsequent siblings)
  12 siblings, 1 reply; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-09 11:17 UTC (permalink / raw)
  To: linux-iio; +Cc: Rob Herring, devicetree, Jonathan Cameron, Angelo Compagnucci

From: Jonathan Cameron <Jonathan.Cameron@huawei.com>

These i2c devices have simple bindings, well described by trivial-device.yaml
so rather than convert the binding doc to yaml, let us just add them to
trivial devices and drop the old binding document.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Cc: Angelo Compagnucci <angelo.compagnucci@gmail.com>
---
 .../devicetree/bindings/iio/adc/mcp3422.txt   | 19 -------------------
 .../devicetree/bindings/trivial-devices.yaml  | 16 ++++++++++++++++
 2 files changed, 16 insertions(+), 19 deletions(-)

diff --git a/Documentation/devicetree/bindings/iio/adc/mcp3422.txt b/Documentation/devicetree/bindings/iio/adc/mcp3422.txt
deleted file mode 100644
index 82bcce07255d..000000000000
--- a/Documentation/devicetree/bindings/iio/adc/mcp3422.txt
+++ /dev/null
@@ -1,19 +0,0 @@
-* Microchip mcp3421/2/3/4/6/7/8 chip family (ADC)
-
-Required properties:
- - compatible: Should be
-	"microchip,mcp3421" or
-	"microchip,mcp3422" or
-	"microchip,mcp3423" or
-	"microchip,mcp3424" or
-	"microchip,mcp3425" or
-	"microchip,mcp3426" or
-	"microchip,mcp3427" or
-	"microchip,mcp3428"
- - reg: I2C address for the device
-
-Example:
-adc@0 {
-	compatible = "microchip,mcp3424";
-	reg = <0x68>;
-};
diff --git a/Documentation/devicetree/bindings/trivial-devices.yaml b/Documentation/devicetree/bindings/trivial-devices.yaml
index 4165352a590a..837592ec62aa 100644
--- a/Documentation/devicetree/bindings/trivial-devices.yaml
+++ b/Documentation/devicetree/bindings/trivial-devices.yaml
@@ -130,6 +130,22 @@ properties:
           - mcube,mc3230
             # MEMSIC 2-axis 8-bit digital accelerometer
           - memsic,mxc6225
+            # Microchip differential I2C ADC, 1 Channel, 18 bit
+          - microchip,mcp3421
+            # Microchip differential I2C ADC, 2 Channel, 18 bit
+          - microchip,mcp3422
+            # Microchip differential I2C ADC, 2 Channel, 18 bit
+          - microchip,mcp3423
+            # Microchip differential I2C ADC, 4 Channel, 18 bit
+          - microchip,mcp3424
+            # Microchip differential I2C ADC, 1 Channel, 16 bit
+          - microchip,mcp3425
+            # Microchip differential I2C ADC, 2 Channel, 16 bit
+          - microchip,mcp3426
+            # Microchip differential I2C ADC, 2 Channel, 16 bit
+          - microchip,mcp3427
+            # Microchip differential I2C ADC, 4 Channel, 16 bit
+          - microchip,mcp3428
             # Microchip 7-bit Single I2C Digital POT (5k)
           - microchip,mcp4017-502
             # Microchip 7-bit Single I2C Digital POT (10k)
-- 
2.28.0


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

* [PATCH 03/13] dt-bindings: iio: adc: ti,adc108s102 yaml conversion
  2020-08-09 11:17 [PATCH 00/13] dt-bindings: yaml conversions of some simple ADC bindings Jonathan Cameron
  2020-08-09 11:17 ` [PATCH 01/13] dt-bindings: iio: adc: microchip,mcp3201 yaml conversion Jonathan Cameron
  2020-08-09 11:17 ` [PATCH 02/13] dt-bindings: trivial-devices: Add mcp342x ADCs and drop separate binding doc Jonathan Cameron
@ 2020-08-09 11:17 ` Jonathan Cameron
  2020-08-18  2:27   ` Rob Herring
  2020-08-09 11:17 ` [PATCH 04/13] dt-bindings: iio: adc: lltc,ltc2497 " Jonathan Cameron
                   ` (9 subsequent siblings)
  12 siblings, 1 reply; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-09 11:17 UTC (permalink / raw)
  To: linux-iio; +Cc: Rob Herring, devicetree, Jonathan Cameron, Jan Kiszka

From: Jonathan Cameron <Jonathan.Cameron@huawei.com>

Very simple conversion of spi device with reference supply.

Added the #io-channel-cells property to allow for consumers.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Cc: Jan Kiszka <jan.kiszka@siemens.com>
---
 .../bindings/iio/adc/ti,adc108s102.yaml       | 47 +++++++++++++++++++
 .../bindings/iio/adc/ti-adc108s102.txt        | 18 -------
 2 files changed, 47 insertions(+), 18 deletions(-)

diff --git a/Documentation/devicetree/bindings/iio/adc/ti,adc108s102.yaml b/Documentation/devicetree/bindings/iio/adc/ti,adc108s102.yaml
new file mode 100644
index 000000000000..54955f03df93
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/adc/ti,adc108s102.yaml
@@ -0,0 +1,47 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/adc/ti,adc108s102.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments ADC108S102 and ADC128S102
+
+maintainers:
+  - Bogdan Pricop <bogdan.pricop@emutex.com>
+
+description: |
+  Family of 8 channel, 10/12 bit, SPI, single ended ADCs.
+
+properties:
+  compatible:
+    const:
+      ti,adc108s102
+
+  reg: true
+  vref-supply: true
+  spi-max-frequency: true
+  "#io-channel-cells":
+    const: 1
+
+required:
+  - compatible
+  - reg
+  - vref-supply
+
+additionalProperties: false
+
+examples:
+  - |
+    spi {
+        #address-cells= <1>;
+        #size-cells = <0>;
+
+        adc@0 {
+            compatible = "ti,adc108s102";
+            reg = <0>;
+            vref-supply = <&vdd_supply>;
+            spi-max-frequency = <1000000>;
+            #io-channel-cells = <1>;
+        };
+    };
+...
diff --git a/Documentation/devicetree/bindings/iio/adc/ti-adc108s102.txt b/Documentation/devicetree/bindings/iio/adc/ti-adc108s102.txt
deleted file mode 100644
index bbbbb4a9f58f..000000000000
--- a/Documentation/devicetree/bindings/iio/adc/ti-adc108s102.txt
+++ /dev/null
@@ -1,18 +0,0 @@
-* Texas Instruments' ADC108S102 and ADC128S102 ADC chip
-
-Required properties:
- - compatible: Should be "ti,adc108s102"
- - reg: spi chip select number for the device
- - vref-supply: The regulator supply for ADC reference voltage
-
-Recommended properties:
- - spi-max-frequency: Definition as per
-		Documentation/devicetree/bindings/spi/spi-bus.txt
-
-Example:
-adc@0 {
-	compatible = "ti,adc108s102";
-	reg = <0>;
-	vref-supply = <&vdd_supply>;
-	spi-max-frequency = <1000000>;
-};
-- 
2.28.0


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

* [PATCH 04/13] dt-bindings: iio: adc: lltc,ltc2497 yaml conversion.
  2020-08-09 11:17 [PATCH 00/13] dt-bindings: yaml conversions of some simple ADC bindings Jonathan Cameron
                   ` (2 preceding siblings ...)
  2020-08-09 11:17 ` [PATCH 03/13] dt-bindings: iio: adc: ti,adc108s102 yaml conversion Jonathan Cameron
@ 2020-08-09 11:17 ` Jonathan Cameron
  2020-08-18  2:28   ` Rob Herring
  2020-08-09 11:17 ` [PATCH 05/13] dt-bindings: iio: adc: ti,adc161s626 " Jonathan Cameron
                   ` (8 subsequent siblings)
  12 siblings, 1 reply; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-09 11:17 UTC (permalink / raw)
  To: linux-iio; +Cc: Rob Herring, devicetree, Jonathan Cameron, Michael Hennerich

From: Jonathan Cameron <Jonathan.Cameron@huawei.com>

Very simple binding for this i2c device with a reference supply.

Added the #io-channel-cells property to allow for consumers.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Cc: Michael Hennerich <michael.hennerich@analog.com>
---
 .../bindings/iio/adc/lltc,ltc2497.yaml        | 44 +++++++++++++++++++
 .../devicetree/bindings/iio/adc/ltc2497.txt   | 13 ------
 2 files changed, 44 insertions(+), 13 deletions(-)

diff --git a/Documentation/devicetree/bindings/iio/adc/lltc,ltc2497.yaml b/Documentation/devicetree/bindings/iio/adc/lltc,ltc2497.yaml
new file mode 100644
index 000000000000..6a176f551d75
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/adc/lltc,ltc2497.yaml
@@ -0,0 +1,44 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/adc/lltc,ltc2497.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Linear Technology / Analog Devices LTC2497 ADC
+
+maintainers:
+  - Michael Hennerich <michael.hennerich@analog.com>
+
+description: |
+  16bit ADC supporting up to 16 single ended or 8 differential inputs.
+  I2C interface.
+
+properties:
+  compatible:
+    const:
+      lltc,ltc2497
+
+  reg: true
+  vref-supply: true
+  "#io-channel-cells":
+    const: 1
+
+required:
+  - compatible
+  - reg
+  - vref-supply
+
+examples:
+  - |
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        adc@76 {
+            compatible = "lltc,ltc2497";
+            reg = <0x76>;
+            vref-supply = <&ltc2497_reg>;
+            #io-channel-cells = <1>;
+        };
+    };
+...
diff --git a/Documentation/devicetree/bindings/iio/adc/ltc2497.txt b/Documentation/devicetree/bindings/iio/adc/ltc2497.txt
deleted file mode 100644
index a237ed99c0d8..000000000000
--- a/Documentation/devicetree/bindings/iio/adc/ltc2497.txt
+++ /dev/null
@@ -1,13 +0,0 @@
-* Linear Technology / Analog Devices LTC2497 ADC
-
-Required properties:
- - compatible: Must be "lltc,ltc2497"
- - reg: Must contain the ADC I2C address
- - vref-supply: The regulator supply for ADC reference voltage
-
-Example:
-	ltc2497: adc@76 {
-		compatible = "lltc,ltc2497";
-		reg = <0x76>;
-		vref-supply = <&ltc2497_reg>;
-	};
-- 
2.28.0


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

* [PATCH 05/13] dt-bindings: iio: adc: ti,adc161s626 yaml conversion.
  2020-08-09 11:17 [PATCH 00/13] dt-bindings: yaml conversions of some simple ADC bindings Jonathan Cameron
                   ` (3 preceding siblings ...)
  2020-08-09 11:17 ` [PATCH 04/13] dt-bindings: iio: adc: lltc,ltc2497 " Jonathan Cameron
@ 2020-08-09 11:17 ` Jonathan Cameron
  2020-08-11  3:35   ` Matt Ranostay
  2020-08-18  2:28   ` Rob Herring
  2020-08-09 11:17 ` [PATCH 06/13] dt-bindings: iio: adc: ti,adc0832 " Jonathan Cameron
                   ` (7 subsequent siblings)
  12 siblings, 2 replies; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-09 11:17 UTC (permalink / raw)
  To: linux-iio; +Cc: Rob Herring, devicetree, Jonathan Cameron, Matt Ranostay

From: Jonathan Cameron <Jonathan.Cameron@huawei.com>

Simple conversion for this ADC driver.  Note that I haven't put
limits on the spi-max-sampling-frequency because the adc161s626
doesn't state one clearly defined value.

Added the #io-channel-cells property to allow for consumers.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Cc: Matt Ranostay <matt.ranostay@konsulko.com>
---
 .../bindings/iio/adc/ti,adc161s626.yaml       | 51 +++++++++++++++++++
 .../bindings/iio/adc/ti-adc161s626.txt        | 18 -------
 2 files changed, 51 insertions(+), 18 deletions(-)

diff --git a/Documentation/devicetree/bindings/iio/adc/ti,adc161s626.yaml b/Documentation/devicetree/bindings/iio/adc/ti,adc161s626.yaml
new file mode 100644
index 000000000000..3f4f334d6f73
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/adc/ti,adc161s626.yaml
@@ -0,0 +1,51 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/adc/ti,adc161s626.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments ADC141S626 and ADC161S626 ADCs
+
+maintainers:
+  - Matt Ranostay <matt.ranostay@konsulko.com>
+
+description: |
+  Single channel 14/16bit differential ADCs
+
+properties:
+  compatible:
+    enum:
+      - ti,adc141s626
+      - ti,adc161s626
+
+  reg:
+    maxItems: 1
+
+  spi-max-frequency: true
+
+  vdda-supply: true
+
+  "#io-channel-cells":
+    const: 1
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        adc@0 {
+            compatible = "ti,adc161s626";
+            vdda-supply = <&vdda_fixed>;
+            reg = <0>;
+            spi-max-frequency = <4300000>;
+            #io-channel-cells = <1>;
+        };
+    };
+...
diff --git a/Documentation/devicetree/bindings/iio/adc/ti-adc161s626.txt b/Documentation/devicetree/bindings/iio/adc/ti-adc161s626.txt
deleted file mode 100644
index 3d25011f0c99..000000000000
--- a/Documentation/devicetree/bindings/iio/adc/ti-adc161s626.txt
+++ /dev/null
@@ -1,18 +0,0 @@
-* Texas Instruments ADC141S626 and ADC161S626 chips
-
-Required properties:
- - compatible: Should be "ti,adc141s626" or "ti,adc161s626"
- - reg: spi chip select number for the device
- - vdda-supply: supply voltage to VDDA pin
-
-Recommended properties:
- - spi-max-frequency: Definition as per
-		Documentation/devicetree/bindings/spi/spi-bus.txt
-
-Example:
-adc@0 {
-	compatible = "ti,adc161s626";
-	vdda-supply = <&vdda_fixed>;
-	reg = <0>;
-	spi-max-frequency = <4300000>;
-};
-- 
2.28.0


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

* [PATCH 06/13] dt-bindings: iio: adc: ti,adc0832 yaml conversion.
  2020-08-09 11:17 [PATCH 00/13] dt-bindings: yaml conversions of some simple ADC bindings Jonathan Cameron
                   ` (4 preceding siblings ...)
  2020-08-09 11:17 ` [PATCH 05/13] dt-bindings: iio: adc: ti,adc161s626 " Jonathan Cameron
@ 2020-08-09 11:17 ` Jonathan Cameron
  2020-08-18  2:29   ` Rob Herring
  2020-08-09 11:17 ` [PATCH 07/13] dt-bindings: iio: adc: ti,adc084s021 " Jonathan Cameron
                   ` (6 subsequent siblings)
  12 siblings, 1 reply; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-09 11:17 UTC (permalink / raw)
  To: linux-iio; +Cc: Rob Herring, devicetree, Jonathan Cameron, Akinobu Mita

From: Jonathan Cameron <Jonathan.Cameron@huawei.com>

Simple binding conversion of this SPI ADC binding, with reference
voltage.

Added the optional property #io-channel-cells to allow for
consumers of channels if that makes sense for a given board.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Cc: Akinobu Mita <akinobu.mita@gmail.com>
---
 .../bindings/iio/adc/ti,adc0832.yaml          | 56 +++++++++++++++++++
 .../bindings/iio/adc/ti-adc0832.txt           | 19 -------
 2 files changed, 56 insertions(+), 19 deletions(-)

diff --git a/Documentation/devicetree/bindings/iio/adc/ti,adc0832.yaml b/Documentation/devicetree/bindings/iio/adc/ti,adc0832.yaml
new file mode 100644
index 000000000000..f5a923cc847f
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/adc/ti,adc0832.yaml
@@ -0,0 +1,56 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/adc/ti,adc0832.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments ADC0832 and similar ADCs
+
+maintainers:
+  - Akinobu Mita <akinobu.mita@gmail.com>
+
+description: |
+  8 bit ADCs with 1, 2, 4 or 8 inputs for single ended or differential
+  conversion.
+
+properties:
+  compatible:
+    enum:
+      - ti,adc0831
+      - ti,adc0832
+      - ti,adc0834
+      - ti,adc0838
+
+  reg:
+    maxItems: 1
+
+  spi-max-frequency: true
+
+  vref-supply:
+    description: External reference, needed to establish input scaling
+
+  "#io-channel-cells":
+    const: 1
+
+required:
+  - compatible
+  - reg
+  - vref-supply
+
+additionalProperties: false
+
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        adc@0 {
+            compatible = "ti,adc0832";
+            reg = <0>;
+            vref-supply = <&vdd_supply>;
+            spi-max-frequency = <200000>;
+            #io-channel-cells = <1>;
+        };
+    };
+...
diff --git a/Documentation/devicetree/bindings/iio/adc/ti-adc0832.txt b/Documentation/devicetree/bindings/iio/adc/ti-adc0832.txt
deleted file mode 100644
index d91130587d01..000000000000
--- a/Documentation/devicetree/bindings/iio/adc/ti-adc0832.txt
+++ /dev/null
@@ -1,19 +0,0 @@
-* Texas Instruments' ADC0831/ADC0832/ADC0832/ADC0838
-
-Required properties:
- - compatible: Should be one of
-	* "ti,adc0831"
-	* "ti,adc0832"
-	* "ti,adc0834"
-	* "ti,adc0838"
- - reg: spi chip select number for the device
- - vref-supply: The regulator supply for ADC reference voltage
- - spi-max-frequency: Max SPI frequency to use (< 400000)
-
-Example:
-adc@0 {
-	compatible = "ti,adc0832";
-	reg = <0>;
-	vref-supply = <&vdd_supply>;
-	spi-max-frequency = <200000>;
-};
-- 
2.28.0


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

* [PATCH 07/13] dt-bindings: iio: adc: ti,adc084s021 yaml conversion
  2020-08-09 11:17 [PATCH 00/13] dt-bindings: yaml conversions of some simple ADC bindings Jonathan Cameron
                   ` (5 preceding siblings ...)
  2020-08-09 11:17 ` [PATCH 06/13] dt-bindings: iio: adc: ti,adc0832 " Jonathan Cameron
@ 2020-08-09 11:17 ` Jonathan Cameron
  2020-08-18  2:30   ` Rob Herring
  2020-08-09 11:17 ` [PATCH 08/13] dt-bindings: iio: adc: ti,adc12138 " Jonathan Cameron
                   ` (5 subsequent siblings)
  12 siblings, 1 reply; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-09 11:17 UTC (permalink / raw)
  To: linux-iio; +Cc: Rob Herring, devicetree, Jonathan Cameron, Mårten Lindahl

From: Jonathan Cameron <Jonathan.Cameron@huawei.com>

Simple conversion.

Added the #io-channel-cells optional property to allow for consumer
bindings if appropriate on a given board.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Cc: Mårten Lindahl <martenli@axis.com>
---
 .../bindings/iio/adc/ti,adc084s021.yaml       | 58 +++++++++++++++++++
 .../bindings/iio/adc/ti-adc084s021.txt        | 19 ------
 2 files changed, 58 insertions(+), 19 deletions(-)

diff --git a/Documentation/devicetree/bindings/iio/adc/ti,adc084s021.yaml b/Documentation/devicetree/bindings/iio/adc/ti,adc084s021.yaml
new file mode 100644
index 000000000000..1a113b30a414
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/adc/ti,adc084s021.yaml
@@ -0,0 +1,58 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/adc/ti,adc084s021.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments ADC084S021 ADC
+
+maintainers:
+  - Mårten Lindahl <martenli@axis.com>
+
+description: |
+  8 bit ADC with 4 channels
+
+properties:
+  compatible:
+    const: ti,adc084s021
+
+  reg:
+    maxItems: 1
+
+  spi-max-frequency: true
+
+  vref-supply:
+    description: External reference, needed to establish input scaling
+
+  spi-cpol: true
+  spi-cpha: true
+
+  "#io-channel-cells":
+    const: 1
+
+required:
+  - compatible
+  - reg
+  - vref-supply
+  - spi-cpol
+  - spi-cpha
+
+additionalProperties: false
+
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        adc@0 {
+            compatible = "ti,adc084s021";
+            reg = <0>;
+            vref-supply = <&adc_vref>;
+            spi-cpol;
+            spi-cpha;
+            spi-max-frequency = <16000000>;
+            #io-channel-cells = <1>;
+        };
+    };
+...
diff --git a/Documentation/devicetree/bindings/iio/adc/ti-adc084s021.txt b/Documentation/devicetree/bindings/iio/adc/ti-adc084s021.txt
deleted file mode 100644
index 4259e50620bc..000000000000
--- a/Documentation/devicetree/bindings/iio/adc/ti-adc084s021.txt
+++ /dev/null
@@ -1,19 +0,0 @@
-* Texas Instruments' ADC084S021
-
-Required properties:
- - compatible        : Must be "ti,adc084s021"
- - reg               : SPI chip select number for the device
- - vref-supply       : The regulator supply for ADC reference voltage
- - spi-cpol          : Per spi-bus bindings
- - spi-cpha          : Per spi-bus bindings
- - spi-max-frequency : Per spi-bus bindings
-
-Example:
-adc@0 {
-	compatible = "ti,adc084s021";
-	reg = <0>;
-	vref-supply = <&adc_vref>;
-	spi-cpol;
-	spi-cpha;
-	spi-max-frequency = <16000000>;
-};
-- 
2.28.0


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

* [PATCH 08/13] dt-bindings: iio: adc: ti,adc12138 yaml conversion.
  2020-08-09 11:17 [PATCH 00/13] dt-bindings: yaml conversions of some simple ADC bindings Jonathan Cameron
                   ` (6 preceding siblings ...)
  2020-08-09 11:17 ` [PATCH 07/13] dt-bindings: iio: adc: ti,adc084s021 " Jonathan Cameron
@ 2020-08-09 11:17 ` Jonathan Cameron
  2020-08-12 16:29   ` Rob Herring
  2020-08-17 14:17   ` Rob Herring
  2020-08-09 11:17 ` [PATCH 09/13] dt-bindings: iio: adc: ti,adc128s052 " Jonathan Cameron
                   ` (4 subsequent siblings)
  12 siblings, 2 replies; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-09 11:17 UTC (permalink / raw)
  To: linux-iio; +Cc: Rob Herring, devicetree, Jonathan Cameron, Akinobu Mita

From: Jonathan Cameron <Jonathan.Cameron@huawei.com>

Simple binding conversion.  Only addition was #io-channel-cells to
allow for potential consumers of the channels on this device.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Cc: Akinobu Mita <akinobu.mita@gmail.com>
---
 .../bindings/iio/adc/ti,adc12138.yaml         | 85 +++++++++++++++++++
 .../bindings/iio/adc/ti-adc12138.txt          | 37 --------
 2 files changed, 85 insertions(+), 37 deletions(-)

diff --git a/Documentation/devicetree/bindings/iio/adc/ti,adc12138.yaml b/Documentation/devicetree/bindings/iio/adc/ti,adc12138.yaml
new file mode 100644
index 000000000000..3e8c43aa8ef3
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/adc/ti,adc12138.yaml
@@ -0,0 +1,85 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/adc/ti,adc12138.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments ADC12138 and similar self-calibrating ADCs
+
+maintainers:
+  - Akinobu Mita <akinobu.mita@gmail.com>
+
+description: |
+  13 bit ADCs with 1, 2 or 8 inputs and self calibrating circuitry to
+  correct for linearity, zero and full scale errors.
+
+properties:
+  compatible:
+    enum:
+      - ti,adc12130
+      - ti,adc12132
+      - ti,adc12138
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+    description: End of Conversion (EOC) interrupt
+
+  clocks:
+    maxItems: 1
+    description: Conversion clock input.
+
+  spi-max-frequency: true
+
+  vref-p-supply:
+    description: The regulator supply for positive analog voltage reference
+
+  vref-n-suppy:
+    description: |
+      The regulator supply for negative analog voltage reference
+      (Note that this must not go below GND or exceed vref-p)
+      If not specified, this is assumed to be analog ground.
+
+  ti,acquisition-time:
+    $ref: /schemas/types.yaml#/definitions/uint32
+    enum: [ 6, 10, 18, 34]
+    description: |
+      The number of conversion clock periods for the S/H's acquisition time.
+      For high source impedances, this value can be increased to 18 or 34.
+      For less ADC accuracy and/or slower CCLK frequencies this value may be
+      decreased to 6.  See section 6.0 INPUT SOURCE RESISTANCE in the
+      datasheet for details.
+
+  "#io-channel-cells":
+    const: 1
+
+required:
+  - compatible
+  - reg
+  - interrupts
+  - clocks
+  - vref-p-supply
+
+additionalProperties: false
+
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        adc@0 {
+            compatible = "ti,adc12138";
+            reg = <0>;
+            interrupts = <28 IRQ_TYPE_EDGE_RISING>;
+            interrupt-parent = <&gpio1>;
+            clocks = <&cclk>;
+            vref-p-supply = <&ldo4_reg>;
+            spi-max-frequency = <5000000>;
+            ti,acquisition-time = <6>;
+            #io-channel-cells = <1>;
+        };
+    };
+...
diff --git a/Documentation/devicetree/bindings/iio/adc/ti-adc12138.txt b/Documentation/devicetree/bindings/iio/adc/ti-adc12138.txt
deleted file mode 100644
index 049a1d36f013..000000000000
--- a/Documentation/devicetree/bindings/iio/adc/ti-adc12138.txt
+++ /dev/null
@@ -1,37 +0,0 @@
-* Texas Instruments' ADC12130/ADC12132/ADC12138
-
-Required properties:
- - compatible: Should be one of
-	* "ti,adc12130"
-	* "ti,adc12132"
-	* "ti,adc12138"
- - reg: SPI chip select number for the device
- - interrupts: Should contain interrupt for EOC (end of conversion)
- - clocks: phandle to conversion clock input
- - spi-max-frequency: Definision as per
-	Documentation/devicetree/bindings/spi/spi-bus.txt
- - vref-p-supply: The regulator supply for positive analog voltage reference
-
-Optional properties:
- - vref-n-supply: The regulator supply for negative analog voltage reference
-	(Note that this must not go below GND or exceed vref-p)
-	If not specified, this is assumed to be analog ground.
- - ti,acquisition-time: The number of conversion clock periods for the S/H's
-	acquisition time.  Should be one of 6, 10, 18, 34.  If not specified,
-	default value of 10 is used.
-	For high source impedances, this value can be increased to 18 or 34.
-	For less ADC accuracy and/or slower CCLK frequencies this value may be
-	decreased to 6.  See section 6.0 INPUT SOURCE RESISTANCE in the
-	datasheet for details.
-
-Example:
-adc@0 {
-	compatible = "ti,adc12138";
-	reg = <0>;
-	interrupts = <28 IRQ_TYPE_EDGE_RISING>;
-	interrupt-parent = <&gpio1>;
-	clocks = <&cclk>;
-	vref-p-supply = <&ldo4_reg>;
-	spi-max-frequency = <5000000>;
-	ti,acquisition-time = <6>;
-};
-- 
2.28.0


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

* [PATCH 09/13] dt-bindings: iio: adc: ti,adc128s052 yaml conversion.
  2020-08-09 11:17 [PATCH 00/13] dt-bindings: yaml conversions of some simple ADC bindings Jonathan Cameron
                   ` (7 preceding siblings ...)
  2020-08-09 11:17 ` [PATCH 08/13] dt-bindings: iio: adc: ti,adc12138 " Jonathan Cameron
@ 2020-08-09 11:17 ` Jonathan Cameron
  2020-08-18  2:30   ` Rob Herring
  2020-08-09 11:17 ` [PATCH 10/13] dt-bindings: iio: adc: ti,ads7950 binding conversion Jonathan Cameron
                   ` (3 subsequent siblings)
  12 siblings, 1 reply; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-09 11:17 UTC (permalink / raw)
  To: linux-iio; +Cc: Rob Herring, devicetree, Jonathan Cameron, Angelo Compagnucci

From: Jonathan Cameron <Jonathan.Cameron@huawei.com>

Simple binding.  Only addition to txt version is
as a provider of channels to other devices using the consumer
binding.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Cc: Angelo Compagnucci <angelo.compagnucci@gmail.com>
---
 .../bindings/iio/adc/ti,adc128s052.yaml       | 59 +++++++++++++++++++
 .../bindings/iio/adc/ti-adc128s052.txt        | 25 --------
 2 files changed, 59 insertions(+), 25 deletions(-)

diff --git a/Documentation/devicetree/bindings/iio/adc/ti,adc128s052.yaml b/Documentation/devicetree/bindings/iio/adc/ti,adc128s052.yaml
new file mode 100644
index 000000000000..d54a0183f024
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/adc/ti,adc128s052.yaml
@@ -0,0 +1,59 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/adc/ti,adc128s052.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments ADC128S052 and similar ADCs
+
+maintainers:
+  - Angelo Compagnucci <angelo.compagnucci@gmail.com>
+
+description: |
+  Family of 12 bit SPI ADCs with 2 to 8 channels with a range of different
+  target sample rates.
+
+properties:
+  compatible:
+    enum:
+      - ti,adc122s021
+      - ti,adc122s051
+      - ti,adc122s101
+      - ti,adc124s021
+      - ti,adc124s051
+      - ti,adc124s101
+      - ti,adc128s052
+
+  reg:
+    maxItems: 1
+
+  spi-max-frequency: true
+
+  vref-supply: true
+
+  "#io-channel-cells":
+    const: 1
+
+required:
+  - compatible
+  - reg
+  - vref-supply
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/interrupt-controller/irq.h>
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        adc@0 {
+            compatible = "ti,adc128s052";
+            reg = <0>;
+            vref-supply = <&vdd_supply>;
+            spi-max-frequency = <1000000>;
+            #io-channel-cells = <1>;
+        };
+    };
+...
diff --git a/Documentation/devicetree/bindings/iio/adc/ti-adc128s052.txt b/Documentation/devicetree/bindings/iio/adc/ti-adc128s052.txt
deleted file mode 100644
index c07ce1a3f5c4..000000000000
--- a/Documentation/devicetree/bindings/iio/adc/ti-adc128s052.txt
+++ /dev/null
@@ -1,25 +0,0 @@
-* Texas Instruments' ADC128S052, ADC122S021 and ADC124S021 ADC chip
-
-Required properties:
- - compatible: Should be one of:
-   - "ti,adc128s052"
-   - "ti,adc122s021"
-   - "ti,adc122s051"
-   - "ti,adc122s101"
-   - "ti,adc124s021"
-   - "ti,adc124s051"
-   - "ti,adc124s101"
- - reg: spi chip select number for the device
- - vref-supply: The regulator supply for ADC reference voltage
-
-Recommended properties:
- - spi-max-frequency: Definition as per
-		Documentation/devicetree/bindings/spi/spi-bus.txt
-
-Example:
-adc@0 {
-	compatible = "ti,adc128s052";
-	reg = <0>;
-	vref-supply = <&vdd_supply>;
-	spi-max-frequency = <1000000>;
-};
-- 
2.28.0


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

* [PATCH 10/13] dt-bindings: iio: adc: ti,ads7950 binding conversion
  2020-08-09 11:17 [PATCH 00/13] dt-bindings: yaml conversions of some simple ADC bindings Jonathan Cameron
                   ` (8 preceding siblings ...)
  2020-08-09 11:17 ` [PATCH 09/13] dt-bindings: iio: adc: ti,adc128s052 " Jonathan Cameron
@ 2020-08-09 11:17 ` Jonathan Cameron
  2020-08-12 16:30   ` David Lechner
  2020-08-09 11:17 ` [PATCH 11/13] dt-bindings: iio: adc: ti,ads8344 yaml conversion Jonathan Cameron
                   ` (2 subsequent siblings)
  12 siblings, 1 reply; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-09 11:17 UTC (permalink / raw)
  To: linux-iio; +Cc: Rob Herring, devicetree, Jonathan Cameron, David Lechner

From: Jonathan Cameron <Jonathan.Cameron@huawei.com>

Simple conversion.  This binding already had the
that is necessary, I'm happy to leave it as previously documented.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Cc: David Lechner <david@lechnology.com>
---
 .../bindings/iio/adc/ti,ads7950.yaml          | 64 +++++++++++++++++++
 .../bindings/iio/adc/ti-ads7950.txt           | 23 -------
 2 files changed, 64 insertions(+), 23 deletions(-)

diff --git a/Documentation/devicetree/bindings/iio/adc/ti,ads7950.yaml b/Documentation/devicetree/bindings/iio/adc/ti,ads7950.yaml
new file mode 100644
index 000000000000..a759d9064718
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/adc/ti,ads7950.yaml
@@ -0,0 +1,64 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/adc/ti,ads7950.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments ADS7950 and similar ADCs
+
+maintainers:
+  - David Lechner <david@lechnology.com>
+
+description: |
+  Family of 4-16 channel, 8-12 bit ADCs with SPI interface.
+
+properties:
+  compatible:
+    enum:
+      - ti,ads7950
+      - ti,ads7951
+      - ti,ads7952
+      - ti,ads7953
+      - ti,ads7954
+      - ti,ads7955
+      - ti,ads7956
+      - ti,ads7957
+      - ti,ads7958
+      - ti,ads7959
+      - ti,ads7960
+      - ti,ads7961
+
+  reg:
+    maxItems: 1
+
+  spi-max-frequency: true
+
+  vref-supply:
+    description: Supply the 2.5V or 5V reference voltage
+
+  "#io-channel-cells":
+    const: 1
+
+required:
+  - compatible
+  - reg
+  - vref-supply
+  - "#io-channel-cells"
+
+additionalProperties: false
+
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        adc@0 {
+            compatible = "ti,ads7957";
+            reg = <0>;
+            vref-supply = <&refin_supply>;
+            spi-max-frequency = <10000000>;
+            #io-channel-cells = <1>;
+        };
+    };
+...
diff --git a/Documentation/devicetree/bindings/iio/adc/ti-ads7950.txt b/Documentation/devicetree/bindings/iio/adc/ti-ads7950.txt
deleted file mode 100644
index e77a6f7e1001..000000000000
--- a/Documentation/devicetree/bindings/iio/adc/ti-ads7950.txt
+++ /dev/null
@@ -1,23 +0,0 @@
-* Texas Instruments ADS7950 family of A/DC chips
-
-Required properties:
- - compatible: Must be one of "ti,ads7950", "ti,ads7951", "ti,ads7952",
-   "ti,ads7953", "ti,ads7954", "ti,ads7955", "ti,ads7956", "ti,ads7957",
-   "ti,ads7958", "ti,ads7959", "ti,ads7960", or "ti,ads7961"
- - reg: SPI chip select number for the device
- - #io-channel-cells: Must be 1 as per ../iio-bindings.txt
- - vref-supply: phandle to a regulator node that supplies the 2.5V or 5V
-   reference voltage
-
-Recommended properties:
- - spi-max-frequency: Definition as per
-		Documentation/devicetree/bindings/spi/spi-bus.txt
-
-Example:
-adc@0 {
-	compatible = "ti,ads7957";
-	reg = <0>;
-	#io-channel-cells = <1>;
-	vref-supply = <&refin_supply>;
-	spi-max-frequency = <10000000>;
-};
-- 
2.28.0


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

* [PATCH 11/13] dt-bindings: iio: adc: ti,ads8344 yaml conversion
  2020-08-09 11:17 [PATCH 00/13] dt-bindings: yaml conversions of some simple ADC bindings Jonathan Cameron
                   ` (9 preceding siblings ...)
  2020-08-09 11:17 ` [PATCH 10/13] dt-bindings: iio: adc: ti,ads7950 binding conversion Jonathan Cameron
@ 2020-08-09 11:17 ` Jonathan Cameron
  2020-08-18  2:31   ` Rob Herring
  2020-08-09 11:17 ` [PATCH 12/13] dt-bindings: iio: adc: tlc4541 - recover accidentally dropped binding doc Jonathan Cameron
  2020-08-09 11:17 ` [PATCH 13/13] dt-bindings: iio: adc: ti,tlc4541 binding conversion Jonathan Cameron
  12 siblings, 1 reply; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-09 11:17 UTC (permalink / raw)
  To: linux-iio; +Cc: Rob Herring, devicetree, Jonathan Cameron

From: Jonathan Cameron <Jonathan.Cameron@huawei.com>

Simple binding so easy to convert.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
---
 .../bindings/iio/adc/ti,ads8344.yaml          | 51 +++++++++++++++++++
 .../bindings/iio/adc/ti-ads8344.txt           | 19 -------
 2 files changed, 51 insertions(+), 19 deletions(-)

diff --git a/Documentation/devicetree/bindings/iio/adc/ti,ads8344.yaml b/Documentation/devicetree/bindings/iio/adc/ti,ads8344.yaml
new file mode 100644
index 000000000000..b8c398187d5c
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/adc/ti,ads8344.yaml
@@ -0,0 +1,51 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/adc/ti,ads8344.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments ADS8344 ADC
+
+maintainers:
+  - Gregory Clement <gregory.clement@bootlin.com>
+
+description: |
+  16bit 8-channel ADC with single ended inputs.
+
+properties:
+  compatible:
+    const: ti,ads8344
+
+  reg:
+    maxItems: 1
+
+  spi-max-frequency: true
+
+  vref-supply:
+    description: Supply the 2.5V or 5V reference voltage
+
+  "#io-channel-cells":
+    const: 1
+
+required:
+  - compatible
+  - reg
+  - vref-supply
+
+additionalProperties: false
+
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        adc@0 {
+            compatible = "ti,ads8344";
+            reg = <0>;
+            vref-supply = <&refin_supply>;
+            spi-max-frequency = <10000000>;
+            #io-channel-cells = <1>;
+        };
+    };
+...
diff --git a/Documentation/devicetree/bindings/iio/adc/ti-ads8344.txt b/Documentation/devicetree/bindings/iio/adc/ti-ads8344.txt
deleted file mode 100644
index e47c3759a82b..000000000000
--- a/Documentation/devicetree/bindings/iio/adc/ti-ads8344.txt
+++ /dev/null
@@ -1,19 +0,0 @@
-* Texas Instruments ADS8344 A/DC chip
-
-Required properties:
- - compatible: Must be "ti,ads8344"
- - reg: SPI chip select number for the device
- - vref-supply: phandle to a regulator node that supplies the
-   reference voltage
-
-Recommended properties:
- - spi-max-frequency: Definition as per
-		Documentation/devicetree/bindings/spi/spi-bus.txt
-
-Example:
-adc@0 {
-	compatible = "ti,ads8344";
-	reg = <0>;
-	vref-supply = <&refin_supply>;
-	spi-max-frequency = <10000000>;
-};
-- 
2.28.0


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

* [PATCH 12/13] dt-bindings: iio: adc: tlc4541 - recover accidentally dropped binding doc
  2020-08-09 11:17 [PATCH 00/13] dt-bindings: yaml conversions of some simple ADC bindings Jonathan Cameron
                   ` (10 preceding siblings ...)
  2020-08-09 11:17 ` [PATCH 11/13] dt-bindings: iio: adc: ti,ads8344 yaml conversion Jonathan Cameron
@ 2020-08-09 11:17 ` Jonathan Cameron
  2020-08-29 17:57   ` Jonathan Cameron
  2020-08-09 11:17 ` [PATCH 13/13] dt-bindings: iio: adc: ti,tlc4541 binding conversion Jonathan Cameron
  12 siblings, 1 reply; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-09 11:17 UTC (permalink / raw)
  To: linux-iio
  Cc: Rob Herring, devicetree, Phil Reid, Rob Herring, Jonathan Cameron

From: Phil Reid <preid@electromag.com.au>

JC: Seems that I messed up applying the original driver patches, and
this file never actually made it into the tree.

I have picked up original Ack and Sign-off so as to record the
history.

Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Phil Reid <preid@electromag.com.au>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
---
 .../devicetree/bindings/iio/adc/ti-tlc4541.txt  | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/Documentation/devicetree/bindings/iio/adc/ti-tlc4541.txt b/Documentation/devicetree/bindings/iio/adc/ti-tlc4541.txt
new file mode 100644
index 000000000000..6b2692723a04
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/adc/ti-tlc4541.txt
@@ -0,0 +1,17 @@
+* Texas Instruments' TLC4541
+
+Required properties:
+ - compatible: Should be one of
+	* "ti,tlc4541"
+	* "ti,tlc3541"
+	- reg: SPI chip select number for the device
+ - vref-supply: The regulator supply for ADC reference voltage
+ - spi-max-frequency: Max SPI frequency to use (<= 200000)
+
+Example:
+adc@0 {
+	compatible = "ti,tlc4541";
+	reg = <0>;
+	vref-supply = <&vdd_supply>;
+	spi-max-frequency = <200000>;
+};
-- 
2.28.0


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

* [PATCH 13/13] dt-bindings: iio: adc: ti,tlc4541 binding conversion
  2020-08-09 11:17 [PATCH 00/13] dt-bindings: yaml conversions of some simple ADC bindings Jonathan Cameron
                   ` (11 preceding siblings ...)
  2020-08-09 11:17 ` [PATCH 12/13] dt-bindings: iio: adc: tlc4541 - recover accidentally dropped binding doc Jonathan Cameron
@ 2020-08-09 11:17 ` Jonathan Cameron
  2020-08-10  0:42   ` Phil Reid
  2020-08-18  2:32   ` Rob Herring
  12 siblings, 2 replies; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-09 11:17 UTC (permalink / raw)
  To: linux-iio; +Cc: Rob Herring, devicetree, Jonathan Cameron, Phil Reid

From: Jonathan Cameron <Jonathan.Cameron@huawei.com>

Simple binding so easy to convert.
Dropped the stated value of maximum spi bus frequency as it does
not seem to correspond to the datasheet.  The value of 200kHz
is the max sampling frequency of the ADC, not the clock frequency of
the SPI bus.

Added #io-channel-cells to allow use as a provider of channels to
other devices via the consumer binding.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Cc: Phil Reid <preid@electromag.com.au>
---
 .../bindings/iio/adc/ti,tlc4541.yaml          | 52 +++++++++++++++++++
 .../bindings/iio/adc/ti-tlc4541.txt           | 17 ------
 2 files changed, 52 insertions(+), 17 deletions(-)

diff --git a/Documentation/devicetree/bindings/iio/adc/ti,tlc4541.yaml b/Documentation/devicetree/bindings/iio/adc/ti,tlc4541.yaml
new file mode 100644
index 000000000000..6c2539b3d707
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/adc/ti,tlc4541.yaml
@@ -0,0 +1,52 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/adc/ti,tlc4541.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments TLC4541 and similar ADCs
+
+maintainers:
+  - Phil Reid <preid@electromag.com.au>
+
+description: |
+  14/16bit single channel ADC with SPI interface.
+
+properties:
+  compatible:
+    enum:
+      - ti,tlc3541
+      - ti,tlc4541
+
+  reg:
+    maxItems: 1
+
+  spi-max-frequency: true
+
+  vref-supply: true
+
+  "#io-channel-cells":
+    const: 1
+
+required:
+  - compatible
+  - reg
+  - vref-supply
+
+additionalProperties: false
+
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        adc@0 {
+            compatible = "ti,tlc4541";
+            reg = <0>;
+            vref-supply = <&vdd_supply>;
+            spi-max-frequency = <200000>;
+            #io-channel-cells = <1>;
+        };
+    };
+...
diff --git a/Documentation/devicetree/bindings/iio/adc/ti-tlc4541.txt b/Documentation/devicetree/bindings/iio/adc/ti-tlc4541.txt
deleted file mode 100644
index 6b2692723a04..000000000000
--- a/Documentation/devicetree/bindings/iio/adc/ti-tlc4541.txt
+++ /dev/null
@@ -1,17 +0,0 @@
-* Texas Instruments' TLC4541
-
-Required properties:
- - compatible: Should be one of
-	* "ti,tlc4541"
-	* "ti,tlc3541"
-	- reg: SPI chip select number for the device
- - vref-supply: The regulator supply for ADC reference voltage
- - spi-max-frequency: Max SPI frequency to use (<= 200000)
-
-Example:
-adc@0 {
-	compatible = "ti,tlc4541";
-	reg = <0>;
-	vref-supply = <&vdd_supply>;
-	spi-max-frequency = <200000>;
-};
-- 
2.28.0


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

* Re: [PATCH 13/13] dt-bindings: iio: adc: ti,tlc4541 binding conversion
  2020-08-09 11:17 ` [PATCH 13/13] dt-bindings: iio: adc: ti,tlc4541 binding conversion Jonathan Cameron
@ 2020-08-10  0:42   ` Phil Reid
  2020-08-18  2:32   ` Rob Herring
  1 sibling, 0 replies; 42+ messages in thread
From: Phil Reid @ 2020-08-10  0:42 UTC (permalink / raw)
  To: Jonathan Cameron, linux-iio; +Cc: Rob Herring, devicetree, Jonathan Cameron

On 9/08/2020 19:17, Jonathan Cameron wrote:
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> 
> Simple binding so easy to convert.
> Dropped the stated value of maximum spi bus frequency as it does
> not seem to correspond to the datasheet.  The value of 200kHz
> is the max sampling frequency of the ADC, not the clock frequency of
> the SPI bus.
> 
> Added #io-channel-cells to allow use as a provider of channels to
> other devices via the consumer binding.
> 
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Cc: Phil Reid <preid@electromag.com.au>

Yes, the spi frequency can be higher.
Thanks.

Reviewed-By: Phil Reid <preid@electromag.com.au>

> ---
>   .../bindings/iio/adc/ti,tlc4541.yaml          | 52 +++++++++++++++++++
>   .../bindings/iio/adc/ti-tlc4541.txt           | 17 ------
>   2 files changed, 52 insertions(+), 17 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/iio/adc/ti,tlc4541.yaml b/Documentation/devicetree/bindings/iio/adc/ti,tlc4541.yaml
> new file mode 100644
> index 000000000000..6c2539b3d707
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/iio/adc/ti,tlc4541.yaml
> @@ -0,0 +1,52 @@
> +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/iio/adc/ti,tlc4541.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Texas Instruments TLC4541 and similar ADCs
> +
> +maintainers:
> +  - Phil Reid <preid@electromag.com.au>
> +
> +description: |
> +  14/16bit single channel ADC with SPI interface.
> +
> +properties:
> +  compatible:
> +    enum:
> +      - ti,tlc3541
> +      - ti,tlc4541
> +
> +  reg:
> +    maxItems: 1
> +
> +  spi-max-frequency: true
> +
> +  vref-supply: true
> +
> +  "#io-channel-cells":
> +    const: 1
> +
> +required:
> +  - compatible
> +  - reg
> +  - vref-supply
> +
> +additionalProperties: false
> +
> +examples:
> +  - |
> +    spi {
> +        #address-cells = <1>;
> +        #size-cells = <0>;
> +
> +        adc@0 {
> +            compatible = "ti,tlc4541";
> +            reg = <0>;
> +            vref-supply = <&vdd_supply>;
> +            spi-max-frequency = <200000>;
> +            #io-channel-cells = <1>;
> +        };
> +    };
> +...
> diff --git a/Documentation/devicetree/bindings/iio/adc/ti-tlc4541.txt b/Documentation/devicetree/bindings/iio/adc/ti-tlc4541.txt
> deleted file mode 100644
> index 6b2692723a04..000000000000
> --- a/Documentation/devicetree/bindings/iio/adc/ti-tlc4541.txt
> +++ /dev/null
> @@ -1,17 +0,0 @@
> -* Texas Instruments' TLC4541
> -
> -Required properties:
> - - compatible: Should be one of
> -	* "ti,tlc4541"
> -	* "ti,tlc3541"
> -	- reg: SPI chip select number for the device
> - - vref-supply: The regulator supply for ADC reference voltage
> - - spi-max-frequency: Max SPI frequency to use (<= 200000)
> -
> -Example:
> -adc@0 {
> -	compatible = "ti,tlc4541";
> -	reg = <0>;
> -	vref-supply = <&vdd_supply>;
> -	spi-max-frequency = <200000>;
> -};
> 


-- 
Regards
Phil Reid



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

* Re: [PATCH 05/13] dt-bindings: iio: adc: ti,adc161s626 yaml conversion.
  2020-08-09 11:17 ` [PATCH 05/13] dt-bindings: iio: adc: ti,adc161s626 " Jonathan Cameron
@ 2020-08-11  3:35   ` Matt Ranostay
  2020-08-18  2:28   ` Rob Herring
  1 sibling, 0 replies; 42+ messages in thread
From: Matt Ranostay @ 2020-08-11  3:35 UTC (permalink / raw)
  To: Jonathan Cameron
  Cc: open list:IIO SUBSYSTEM AND DRIVERS, Rob Herring, devicetree,
	Jonathan Cameron

On Sun, Aug 9, 2020 at 4:20 AM Jonathan Cameron <jic23@kernel.org> wrote:
>
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
>
> Simple conversion for this ADC driver.  Note that I haven't put
> limits on the spi-max-sampling-frequency because the adc161s626
> doesn't state one clearly defined value.
>
> Added the #io-channel-cells property to allow for consumers.
>
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Cc: Matt Ranostay <matt.ranostay@konsulko.com>

Acked-by: Matt Ranostay <matt.ranostay@konsulko.com>


> ---
>  .../bindings/iio/adc/ti,adc161s626.yaml       | 51 +++++++++++++++++++
>  .../bindings/iio/adc/ti-adc161s626.txt        | 18 -------
>  2 files changed, 51 insertions(+), 18 deletions(-)
>
> diff --git a/Documentation/devicetree/bindings/iio/adc/ti,adc161s626.yaml b/Documentation/devicetree/bindings/iio/adc/ti,adc161s626.yaml
> new file mode 100644
> index 000000000000..3f4f334d6f73
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/iio/adc/ti,adc161s626.yaml
> @@ -0,0 +1,51 @@
> +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/iio/adc/ti,adc161s626.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Texas Instruments ADC141S626 and ADC161S626 ADCs
> +
> +maintainers:
> +  - Matt Ranostay <matt.ranostay@konsulko.com>
> +
> +description: |
> +  Single channel 14/16bit differential ADCs
> +
> +properties:
> +  compatible:
> +    enum:
> +      - ti,adc141s626
> +      - ti,adc161s626
> +
> +  reg:
> +    maxItems: 1
> +
> +  spi-max-frequency: true
> +
> +  vdda-supply: true
> +
> +  "#io-channel-cells":
> +    const: 1
> +
> +required:
> +  - compatible
> +  - reg
> +
> +additionalProperties: false
> +
> +examples:
> +  - |
> +    spi {
> +        #address-cells = <1>;
> +        #size-cells = <0>;
> +
> +        adc@0 {
> +            compatible = "ti,adc161s626";
> +            vdda-supply = <&vdda_fixed>;
> +            reg = <0>;
> +            spi-max-frequency = <4300000>;
> +            #io-channel-cells = <1>;
> +        };
> +    };
> +...
> diff --git a/Documentation/devicetree/bindings/iio/adc/ti-adc161s626.txt b/Documentation/devicetree/bindings/iio/adc/ti-adc161s626.txt
> deleted file mode 100644
> index 3d25011f0c99..000000000000
> --- a/Documentation/devicetree/bindings/iio/adc/ti-adc161s626.txt
> +++ /dev/null
> @@ -1,18 +0,0 @@
> -* Texas Instruments ADC141S626 and ADC161S626 chips
> -
> -Required properties:
> - - compatible: Should be "ti,adc141s626" or "ti,adc161s626"
> - - reg: spi chip select number for the device
> - - vdda-supply: supply voltage to VDDA pin
> -
> -Recommended properties:
> - - spi-max-frequency: Definition as per
> -               Documentation/devicetree/bindings/spi/spi-bus.txt
> -
> -Example:
> -adc@0 {
> -       compatible = "ti,adc161s626";
> -       vdda-supply = <&vdda_fixed>;
> -       reg = <0>;
> -       spi-max-frequency = <4300000>;
> -};
> --
> 2.28.0
>

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

* Re: [PATCH 08/13] dt-bindings: iio: adc: ti,adc12138 yaml conversion.
  2020-08-09 11:17 ` [PATCH 08/13] dt-bindings: iio: adc: ti,adc12138 " Jonathan Cameron
@ 2020-08-12 16:29   ` Rob Herring
  2020-08-16  9:06     ` Jonathan Cameron
  2020-08-17 14:17   ` Rob Herring
  1 sibling, 1 reply; 42+ messages in thread
From: Rob Herring @ 2020-08-12 16:29 UTC (permalink / raw)
  To: Jonathan Cameron
  Cc: Jonathan Cameron, devicetree, Akinobu Mita, Rob Herring, linux-iio

On Sun, 09 Aug 2020 12:17:48 +0100, Jonathan Cameron wrote:
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> 
> Simple binding conversion.  Only addition was #io-channel-cells to
> allow for potential consumers of the channels on this device.
> 
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Cc: Akinobu Mita <akinobu.mita@gmail.com>
> ---
>  .../bindings/iio/adc/ti,adc12138.yaml         | 85 +++++++++++++++++++
>  .../bindings/iio/adc/ti-adc12138.txt          | 37 --------
>  2 files changed, 85 insertions(+), 37 deletions(-)
> 


My bot found errors running 'make dt_binding_check' on your patch:

Error: Documentation/devicetree/bindings/iio/adc/ti,adc12138.example.dts:26.34-35 syntax error
FATAL ERROR: Unable to parse input tree
make[1]: *** [scripts/Makefile.lib:330: Documentation/devicetree/bindings/iio/adc/ti,adc12138.example.dt.yaml] Error 1
make[1]: *** Waiting for unfinished jobs....
make: *** [Makefile:1334: dt_binding_check] Error 2


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

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

pip3 install git+https://github.com/devicetree-org/dt-schema.git@master --upgrade

Please check and re-submit.


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

* Re: [PATCH 10/13] dt-bindings: iio: adc: ti,ads7950 binding conversion
  2020-08-09 11:17 ` [PATCH 10/13] dt-bindings: iio: adc: ti,ads7950 binding conversion Jonathan Cameron
@ 2020-08-12 16:30   ` David Lechner
  2020-08-30 15:55     ` Jonathan Cameron
  0 siblings, 1 reply; 42+ messages in thread
From: David Lechner @ 2020-08-12 16:30 UTC (permalink / raw)
  To: Jonathan Cameron, linux-iio; +Cc: Rob Herring, devicetree, Jonathan Cameron

On 8/9/20 6:17 AM, Jonathan Cameron wrote:
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> 
> Simple conversion.  This binding already had the
> that is necessary, I'm happy to leave it as previously documented.

This commit message doesn't make sense to me. It should probably
just say "this converts the device tree bindings to yml" or so.

> 
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Cc: David Lechner <david@lechnology.com>
> ---
>   .../bindings/iio/adc/ti,ads7950.yaml          | 64 +++++++++++++++++++
>   .../bindings/iio/adc/ti-ads7950.txt           | 23 -------
>   2 files changed, 64 insertions(+), 23 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/iio/adc/ti,ads7950.yaml b/Documentation/devicetree/bindings/iio/adc/ti,ads7950.yaml
> new file mode 100644
> index 000000000000..a759d9064718
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/iio/adc/ti,ads7950.yaml
> @@ -0,0 +1,64 @@
> +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/iio/adc/ti,ads7950.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Texas Instruments ADS7950 and similar ADCs
> +
> +maintainers:
> +  - David Lechner <david@lechnology.com>
> +
> +description: |
> +  Family of 4-16 channel, 8-12 bit ADCs with SPI interface.
> +
> +properties:
> +  compatible:
> +    enum:
> +      - ti,ads7950
> +      - ti,ads7951
> +      - ti,ads7952
> +      - ti,ads7953
> +      - ti,ads7954
> +      - ti,ads7955
> +      - ti,ads7956
> +      - ti,ads7957
> +      - ti,ads7958
> +      - ti,ads7959
> +      - ti,ads7960
> +      - ti,ads7961
> +
> +  reg:
> +    maxItems: 1
> +
> +  spi-max-frequency: true

According to the datasheet, max frequency is 20MHz, so this can be:

spi-max-frequency:
   maximum: 20000000

> +
> +  vref-supply:
> +    description: Supply the 2.5V or 5V reference voltage

Should this say "Supplies ..."?

> +
> +  "#io-channel-cells":
> +    const: 1
> +
> +required:
> +  - compatible
> +  - reg
> +  - vref-supply
> +  - "#io-channel-cells"
> +
> +additionalProperties: false
> +
> +examples:
> +  - |
> +    spi {
> +        #address-cells = <1>;
> +        #size-cells = <0>;
> +
> +        adc@0 {
> +            compatible = "ti,ads7957";
> +            reg = <0>;
> +            vref-supply = <&refin_supply>;
> +            spi-max-frequency = <10000000>;
> +            #io-channel-cells = <1>;
> +        };
> +    };



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

* Re: [PATCH 08/13] dt-bindings: iio: adc: ti,adc12138 yaml conversion.
  2020-08-12 16:29   ` Rob Herring
@ 2020-08-16  9:06     ` Jonathan Cameron
  0 siblings, 0 replies; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-16  9:06 UTC (permalink / raw)
  To: Rob Herring
  Cc: Jonathan Cameron, devicetree, Akinobu Mita, Rob Herring, linux-iio

On Wed, 12 Aug 2020 10:29:07 -0600
Rob Herring <robh@kernel.org> wrote:

> On Sun, 09 Aug 2020 12:17:48 +0100, Jonathan Cameron wrote:
> > From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > 
> > Simple binding conversion.  Only addition was #io-channel-cells to
> > allow for potential consumers of the channels on this device.
> > 
> > Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > Cc: Akinobu Mita <akinobu.mita@gmail.com>
> > ---
> >  .../bindings/iio/adc/ti,adc12138.yaml         | 85 +++++++++++++++++++
> >  .../bindings/iio/adc/ti-adc12138.txt          | 37 --------
> >  2 files changed, 85 insertions(+), 37 deletions(-)
> >   
> 
> 
> My bot found errors running 'make dt_binding_check' on your patch:
> 
> Error: Documentation/devicetree/bindings/iio/adc/ti,adc12138.example.dts:26.34-35 syntax error
> FATAL ERROR: Unable to parse input tree
> make[1]: *** [scripts/Makefile.lib:330: Documentation/devicetree/bindings/iio/adc/ti,adc12138.example.dt.yaml] Error 1
> make[1]: *** Waiting for unfinished jobs....
> make: *** [Makefile:1334: dt_binding_check] Error 2
> 
> 
> See https://patchwork.ozlabs.org/patch/1342594
> 
> If you already ran 'make dt_binding_check' and didn't see the above
> error(s), then make sure dt-schema is up to date:
> 
> pip3 install git+https://github.com/devicetree-org/dt-schema.git@master --upgrade
> 
> Please check and re-submit.
> 
Not sure how I missed this one in testing. It is a missing include.
I don't propose to resend the series though until more comments are in.

Thanks,

Jonathan



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

* Re: [PATCH 08/13] dt-bindings: iio: adc: ti,adc12138 yaml conversion.
  2020-08-09 11:17 ` [PATCH 08/13] dt-bindings: iio: adc: ti,adc12138 " Jonathan Cameron
  2020-08-12 16:29   ` Rob Herring
@ 2020-08-17 14:17   ` Rob Herring
  1 sibling, 0 replies; 42+ messages in thread
From: Rob Herring @ 2020-08-17 14:17 UTC (permalink / raw)
  To: Jonathan Cameron
  Cc: open list:IIO SUBSYSTEM AND DRIVERS, devicetree,
	Jonathan Cameron, Akinobu Mita

On Sun, Aug 9, 2020 at 5:20 AM Jonathan Cameron <jic23@kernel.org> wrote:
>
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
>
> Simple binding conversion.  Only addition was #io-channel-cells to
> allow for potential consumers of the channels on this device.
>
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Cc: Akinobu Mita <akinobu.mita@gmail.com>
> ---
>  .../bindings/iio/adc/ti,adc12138.yaml         | 85 +++++++++++++++++++
>  .../bindings/iio/adc/ti-adc12138.txt          | 37 --------
>  2 files changed, 85 insertions(+), 37 deletions(-)
>
> diff --git a/Documentation/devicetree/bindings/iio/adc/ti,adc12138.yaml b/Documentation/devicetree/bindings/iio/adc/ti,adc12138.yaml
> new file mode 100644
> index 000000000000..3e8c43aa8ef3
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/iio/adc/ti,adc12138.yaml
> @@ -0,0 +1,85 @@
> +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/iio/adc/ti,adc12138.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Texas Instruments ADC12138 and similar self-calibrating ADCs
> +
> +maintainers:
> +  - Akinobu Mita <akinobu.mita@gmail.com>
> +
> +description: |
> +  13 bit ADCs with 1, 2 or 8 inputs and self calibrating circuitry to
> +  correct for linearity, zero and full scale errors.
> +
> +properties:
> +  compatible:
> +    enum:
> +      - ti,adc12130
> +      - ti,adc12132
> +      - ti,adc12138
> +
> +  reg:
> +    maxItems: 1
> +
> +  interrupts:
> +    maxItems: 1
> +    description: End of Conversion (EOC) interrupt
> +
> +  clocks:
> +    maxItems: 1
> +    description: Conversion clock input.
> +
> +  spi-max-frequency: true
> +
> +  vref-p-supply:
> +    description: The regulator supply for positive analog voltage reference
> +
> +  vref-n-suppy:

typo

> +    description: |
> +      The regulator supply for negative analog voltage reference
> +      (Note that this must not go below GND or exceed vref-p)
> +      If not specified, this is assumed to be analog ground.
> +
> +  ti,acquisition-time:
> +    $ref: /schemas/types.yaml#/definitions/uint32
> +    enum: [ 6, 10, 18, 34]

Inconsistent spacing for brackets. 0 or 1 space is fine.

> +    description: |
> +      The number of conversion clock periods for the S/H's acquisition time.
> +      For high source impedances, this value can be increased to 18 or 34.
> +      For less ADC accuracy and/or slower CCLK frequencies this value may be
> +      decreased to 6.  See section 6.0 INPUT SOURCE RESISTANCE in the
> +      datasheet for details.
> +
> +  "#io-channel-cells":
> +    const: 1
> +
> +required:
> +  - compatible
> +  - reg
> +  - interrupts
> +  - clocks
> +  - vref-p-supply
> +
> +additionalProperties: false
> +
> +examples:
> +  - |
> +    spi {
> +        #address-cells = <1>;
> +        #size-cells = <0>;
> +
> +        adc@0 {
> +            compatible = "ti,adc12138";
> +            reg = <0>;
> +            interrupts = <28 IRQ_TYPE_EDGE_RISING>;
> +            interrupt-parent = <&gpio1>;
> +            clocks = <&cclk>;
> +            vref-p-supply = <&ldo4_reg>;
> +            spi-max-frequency = <5000000>;
> +            ti,acquisition-time = <6>;
> +            #io-channel-cells = <1>;
> +        };
> +    };
> +...
> diff --git a/Documentation/devicetree/bindings/iio/adc/ti-adc12138.txt b/Documentation/devicetree/bindings/iio/adc/ti-adc12138.txt
> deleted file mode 100644
> index 049a1d36f013..000000000000
> --- a/Documentation/devicetree/bindings/iio/adc/ti-adc12138.txt
> +++ /dev/null
> @@ -1,37 +0,0 @@
> -* Texas Instruments' ADC12130/ADC12132/ADC12138
> -
> -Required properties:
> - - compatible: Should be one of
> -       * "ti,adc12130"
> -       * "ti,adc12132"
> -       * "ti,adc12138"
> - - reg: SPI chip select number for the device
> - - interrupts: Should contain interrupt for EOC (end of conversion)
> - - clocks: phandle to conversion clock input
> - - spi-max-frequency: Definision as per
> -       Documentation/devicetree/bindings/spi/spi-bus.txt
> - - vref-p-supply: The regulator supply for positive analog voltage reference
> -
> -Optional properties:
> - - vref-n-supply: The regulator supply for negative analog voltage reference
> -       (Note that this must not go below GND or exceed vref-p)
> -       If not specified, this is assumed to be analog ground.
> - - ti,acquisition-time: The number of conversion clock periods for the S/H's
> -       acquisition time.  Should be one of 6, 10, 18, 34.  If not specified,
> -       default value of 10 is used.
> -       For high source impedances, this value can be increased to 18 or 34.
> -       For less ADC accuracy and/or slower CCLK frequencies this value may be
> -       decreased to 6.  See section 6.0 INPUT SOURCE RESISTANCE in the
> -       datasheet for details.
> -
> -Example:
> -adc@0 {
> -       compatible = "ti,adc12138";
> -       reg = <0>;
> -       interrupts = <28 IRQ_TYPE_EDGE_RISING>;
> -       interrupt-parent = <&gpio1>;
> -       clocks = <&cclk>;
> -       vref-p-supply = <&ldo4_reg>;
> -       spi-max-frequency = <5000000>;
> -       ti,acquisition-time = <6>;
> -};
> --
> 2.28.0
>

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

* Re: [PATCH 01/13] dt-bindings: iio: adc: microchip,mcp3201 yaml conversion.
  2020-08-09 11:17 ` [PATCH 01/13] dt-bindings: iio: adc: microchip,mcp3201 yaml conversion Jonathan Cameron
@ 2020-08-18  2:24   ` Rob Herring
  2020-08-30 13:25     ` Jonathan Cameron
  0 siblings, 1 reply; 42+ messages in thread
From: Rob Herring @ 2020-08-18  2:24 UTC (permalink / raw)
  To: Jonathan Cameron; +Cc: linux-iio, devicetree, Jonathan Cameron, Oskar Andero

On Sun, Aug 09, 2020 at 12:17:41PM +0100, Jonathan Cameron wrote:
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> 
> Drops the deprecated compatibles without the vendor name.
> Whilst the driver continues to support these for old dt blobs,
> any dt bindings that are actuallly verified against this document should
> be fixed to add the vendor name.
> 
> Enforces rule that spi-cpol == spi-cpha.  Is there a cleaner way to
> do this?

dependencies:
  spi-cpol: [ spi-cpha ]
  spi-cpha: [ spi-cpol ]

With that,

Reviewed-by: Rob Herring <robh@kernel.org>

> 
> Added the #io-channel-cells property to allow for consumers.
> 
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Cc: Oskar Andero <oskar.andero@gmail.com>
> ---
>  .../devicetree/bindings/iio/adc/mcp320x.txt   | 57 ------------
>  .../bindings/iio/adc/microchip,mcp3201.yaml   | 93 +++++++++++++++++++
>  2 files changed, 93 insertions(+), 57 deletions(-)

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

* Re: [PATCH 02/13] dt-bindings: trivial-devices: Add mcp342x ADCs and drop separate binding doc.
  2020-08-09 11:17 ` [PATCH 02/13] dt-bindings: trivial-devices: Add mcp342x ADCs and drop separate binding doc Jonathan Cameron
@ 2020-08-18  2:27   ` Rob Herring
  2020-08-29 17:48     ` Jonathan Cameron
  0 siblings, 1 reply; 42+ messages in thread
From: Rob Herring @ 2020-08-18  2:27 UTC (permalink / raw)
  To: Jonathan Cameron
  Cc: open list:IIO SUBSYSTEM AND DRIVERS, devicetree,
	Jonathan Cameron, Angelo Compagnucci

On Sun, Aug 9, 2020 at 5:20 AM Jonathan Cameron <jic23@kernel.org> wrote:
>
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
>
> These i2c devices have simple bindings, well described by trivial-device.yaml
> so rather than convert the binding doc to yaml, let us just add them to
> trivial devices and drop the old binding document.
>
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Cc: Angelo Compagnucci <angelo.compagnucci@gmail.com>
> ---
>  .../devicetree/bindings/iio/adc/mcp3422.txt   | 19 -------------------
>  .../devicetree/bindings/trivial-devices.yaml  | 16 ++++++++++++++++
>  2 files changed, 16 insertions(+), 19 deletions(-)

Reviewed-by: Rob Herring <robh@kernel.org>

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

* Re: [PATCH 03/13] dt-bindings: iio: adc: ti,adc108s102 yaml conversion
  2020-08-09 11:17 ` [PATCH 03/13] dt-bindings: iio: adc: ti,adc108s102 yaml conversion Jonathan Cameron
@ 2020-08-18  2:27   ` Rob Herring
  2020-08-29 17:50     ` Jonathan Cameron
  0 siblings, 1 reply; 42+ messages in thread
From: Rob Herring @ 2020-08-18  2:27 UTC (permalink / raw)
  To: Jonathan Cameron
  Cc: Jan Kiszka, Jonathan Cameron, Rob Herring, linux-iio, devicetree

On Sun, 09 Aug 2020 12:17:43 +0100, Jonathan Cameron wrote:
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> 
> Very simple conversion of spi device with reference supply.
> 
> Added the #io-channel-cells property to allow for consumers.
> 
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Cc: Jan Kiszka <jan.kiszka@siemens.com>
> ---
>  .../bindings/iio/adc/ti,adc108s102.yaml       | 47 +++++++++++++++++++
>  .../bindings/iio/adc/ti-adc108s102.txt        | 18 -------
>  2 files changed, 47 insertions(+), 18 deletions(-)
> 

Reviewed-by: Rob Herring <robh@kernel.org>

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

* Re: [PATCH 04/13] dt-bindings: iio: adc: lltc,ltc2497 yaml conversion.
  2020-08-09 11:17 ` [PATCH 04/13] dt-bindings: iio: adc: lltc,ltc2497 " Jonathan Cameron
@ 2020-08-18  2:28   ` Rob Herring
  2020-08-29 17:50     ` Jonathan Cameron
  0 siblings, 1 reply; 42+ messages in thread
From: Rob Herring @ 2020-08-18  2:28 UTC (permalink / raw)
  To: Jonathan Cameron
  Cc: Rob Herring, Jonathan Cameron, devicetree, linux-iio, Michael Hennerich

On Sun, 09 Aug 2020 12:17:44 +0100, Jonathan Cameron wrote:
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> 
> Very simple binding for this i2c device with a reference supply.
> 
> Added the #io-channel-cells property to allow for consumers.
> 
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Cc: Michael Hennerich <michael.hennerich@analog.com>
> ---
>  .../bindings/iio/adc/lltc,ltc2497.yaml        | 44 +++++++++++++++++++
>  .../devicetree/bindings/iio/adc/ltc2497.txt   | 13 ------
>  2 files changed, 44 insertions(+), 13 deletions(-)
> 

Reviewed-by: Rob Herring <robh@kernel.org>

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

* Re: [PATCH 05/13] dt-bindings: iio: adc: ti,adc161s626 yaml conversion.
  2020-08-09 11:17 ` [PATCH 05/13] dt-bindings: iio: adc: ti,adc161s626 " Jonathan Cameron
  2020-08-11  3:35   ` Matt Ranostay
@ 2020-08-18  2:28   ` Rob Herring
  2020-08-29 17:51     ` Jonathan Cameron
  1 sibling, 1 reply; 42+ messages in thread
From: Rob Herring @ 2020-08-18  2:28 UTC (permalink / raw)
  To: Jonathan Cameron
  Cc: Jonathan Cameron, linux-iio, Rob Herring, devicetree, Matt Ranostay

On Sun, 09 Aug 2020 12:17:45 +0100, Jonathan Cameron wrote:
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> 
> Simple conversion for this ADC driver.  Note that I haven't put
> limits on the spi-max-sampling-frequency because the adc161s626
> doesn't state one clearly defined value.
> 
> Added the #io-channel-cells property to allow for consumers.
> 
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Cc: Matt Ranostay <matt.ranostay@konsulko.com>
> ---
>  .../bindings/iio/adc/ti,adc161s626.yaml       | 51 +++++++++++++++++++
>  .../bindings/iio/adc/ti-adc161s626.txt        | 18 -------
>  2 files changed, 51 insertions(+), 18 deletions(-)
> 

Reviewed-by: Rob Herring <robh@kernel.org>

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

* Re: [PATCH 06/13] dt-bindings: iio: adc: ti,adc0832 yaml conversion.
  2020-08-09 11:17 ` [PATCH 06/13] dt-bindings: iio: adc: ti,adc0832 " Jonathan Cameron
@ 2020-08-18  2:29   ` Rob Herring
  0 siblings, 0 replies; 42+ messages in thread
From: Rob Herring @ 2020-08-18  2:29 UTC (permalink / raw)
  To: Jonathan Cameron
  Cc: linux-iio, Jonathan Cameron, Rob Herring, Akinobu Mita, devicetree

On Sun, 09 Aug 2020 12:17:46 +0100, Jonathan Cameron wrote:
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> 
> Simple binding conversion of this SPI ADC binding, with reference
> voltage.
> 
> Added the optional property #io-channel-cells to allow for
> consumers of channels if that makes sense for a given board.
> 
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Cc: Akinobu Mita <akinobu.mita@gmail.com>
> ---
>  .../bindings/iio/adc/ti,adc0832.yaml          | 56 +++++++++++++++++++
>  .../bindings/iio/adc/ti-adc0832.txt           | 19 -------
>  2 files changed, 56 insertions(+), 19 deletions(-)
> 

Reviewed-by: Rob Herring <robh@kernel.org>

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

* Re: [PATCH 07/13] dt-bindings: iio: adc: ti,adc084s021 yaml conversion
  2020-08-09 11:17 ` [PATCH 07/13] dt-bindings: iio: adc: ti,adc084s021 " Jonathan Cameron
@ 2020-08-18  2:30   ` Rob Herring
  2020-08-29 17:53     ` Jonathan Cameron
  0 siblings, 1 reply; 42+ messages in thread
From: Rob Herring @ 2020-08-18  2:30 UTC (permalink / raw)
  To: Jonathan Cameron
  Cc: Mårten Lindahl, devicetree, Rob Herring, Jonathan Cameron,
	linux-iio

On Sun, 09 Aug 2020 12:17:47 +0100, Jonathan Cameron wrote:
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> 
> Simple conversion.
> 
> Added the #io-channel-cells optional property to allow for consumer
> bindings if appropriate on a given board.
> 
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Cc: Mårten Lindahl <martenli@axis.com>
> ---
>  .../bindings/iio/adc/ti,adc084s021.yaml       | 58 +++++++++++++++++++
>  .../bindings/iio/adc/ti-adc084s021.txt        | 19 ------
>  2 files changed, 58 insertions(+), 19 deletions(-)
> 

Reviewed-by: Rob Herring <robh@kernel.org>

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

* Re: [PATCH 09/13] dt-bindings: iio: adc: ti,adc128s052 yaml conversion.
  2020-08-09 11:17 ` [PATCH 09/13] dt-bindings: iio: adc: ti,adc128s052 " Jonathan Cameron
@ 2020-08-18  2:30   ` Rob Herring
  2020-08-29 17:55     ` Jonathan Cameron
  0 siblings, 1 reply; 42+ messages in thread
From: Rob Herring @ 2020-08-18  2:30 UTC (permalink / raw)
  To: Jonathan Cameron
  Cc: devicetree, Rob Herring, Angelo Compagnucci, linux-iio, Jonathan Cameron

On Sun, 09 Aug 2020 12:17:49 +0100, Jonathan Cameron wrote:
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> 
> Simple binding.  Only addition to txt version is
> as a provider of channels to other devices using the consumer
> binding.
> 
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Cc: Angelo Compagnucci <angelo.compagnucci@gmail.com>
> ---
>  .../bindings/iio/adc/ti,adc128s052.yaml       | 59 +++++++++++++++++++
>  .../bindings/iio/adc/ti-adc128s052.txt        | 25 --------
>  2 files changed, 59 insertions(+), 25 deletions(-)
> 

Reviewed-by: Rob Herring <robh@kernel.org>

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

* Re: [PATCH 11/13] dt-bindings: iio: adc: ti,ads8344 yaml conversion
  2020-08-09 11:17 ` [PATCH 11/13] dt-bindings: iio: adc: ti,ads8344 yaml conversion Jonathan Cameron
@ 2020-08-18  2:31   ` Rob Herring
  2020-08-29 17:58     ` Jonathan Cameron
  0 siblings, 1 reply; 42+ messages in thread
From: Rob Herring @ 2020-08-18  2:31 UTC (permalink / raw)
  To: Jonathan Cameron; +Cc: Rob Herring, devicetree, Jonathan Cameron, linux-iio

On Sun, 09 Aug 2020 12:17:51 +0100, Jonathan Cameron wrote:
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> 
> Simple binding so easy to convert.
> 
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> ---
>  .../bindings/iio/adc/ti,ads8344.yaml          | 51 +++++++++++++++++++
>  .../bindings/iio/adc/ti-ads8344.txt           | 19 -------
>  2 files changed, 51 insertions(+), 19 deletions(-)
> 

Reviewed-by: Rob Herring <robh@kernel.org>

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

* Re: [PATCH 13/13] dt-bindings: iio: adc: ti,tlc4541 binding conversion
  2020-08-09 11:17 ` [PATCH 13/13] dt-bindings: iio: adc: ti,tlc4541 binding conversion Jonathan Cameron
  2020-08-10  0:42   ` Phil Reid
@ 2020-08-18  2:32   ` Rob Herring
  2020-08-29 17:59     ` Jonathan Cameron
  1 sibling, 1 reply; 42+ messages in thread
From: Rob Herring @ 2020-08-18  2:32 UTC (permalink / raw)
  To: Jonathan Cameron
  Cc: Rob Herring, Jonathan Cameron, devicetree, Phil Reid, linux-iio

On Sun, 09 Aug 2020 12:17:53 +0100, Jonathan Cameron wrote:
> From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> 
> Simple binding so easy to convert.
> Dropped the stated value of maximum spi bus frequency as it does
> not seem to correspond to the datasheet.  The value of 200kHz
> is the max sampling frequency of the ADC, not the clock frequency of
> the SPI bus.
> 
> Added #io-channel-cells to allow use as a provider of channels to
> other devices via the consumer binding.
> 
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> Cc: Phil Reid <preid@electromag.com.au>
> ---
>  .../bindings/iio/adc/ti,tlc4541.yaml          | 52 +++++++++++++++++++
>  .../bindings/iio/adc/ti-tlc4541.txt           | 17 ------
>  2 files changed, 52 insertions(+), 17 deletions(-)
> 

Reviewed-by: Rob Herring <robh@kernel.org>

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

* Re: [PATCH 02/13] dt-bindings: trivial-devices: Add mcp342x ADCs and drop separate binding doc.
  2020-08-18  2:27   ` Rob Herring
@ 2020-08-29 17:48     ` Jonathan Cameron
  0 siblings, 0 replies; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-29 17:48 UTC (permalink / raw)
  To: Rob Herring
  Cc: open list:IIO SUBSYSTEM AND DRIVERS, devicetree,
	Jonathan Cameron, Angelo Compagnucci

On Mon, 17 Aug 2020 20:27:26 -0600
Rob Herring <robh+dt@kernel.org> wrote:

> On Sun, Aug 9, 2020 at 5:20 AM Jonathan Cameron <jic23@kernel.org> wrote:
> >
> > From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> >
> > These i2c devices have simple bindings, well described by trivial-device.yaml
> > so rather than convert the binding doc to yaml, let us just add them to
> > trivial devices and drop the old binding document.
> >
> > Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > Cc: Angelo Compagnucci <angelo.compagnucci@gmail.com>
> > ---
> >  .../devicetree/bindings/iio/adc/mcp3422.txt   | 19 -------------------
> >  .../devicetree/bindings/trivial-devices.yaml  | 16 ++++++++++++++++
> >  2 files changed, 16 insertions(+), 19 deletions(-)  
> 
> Reviewed-by: Rob Herring <robh@kernel.org>
Applied

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

* Re: [PATCH 03/13] dt-bindings: iio: adc: ti,adc108s102 yaml conversion
  2020-08-18  2:27   ` Rob Herring
@ 2020-08-29 17:50     ` Jonathan Cameron
  0 siblings, 0 replies; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-29 17:50 UTC (permalink / raw)
  To: Rob Herring
  Cc: Jan Kiszka, Jonathan Cameron, Rob Herring, linux-iio, devicetree

On Mon, 17 Aug 2020 20:27:57 -0600
Rob Herring <robh@kernel.org> wrote:

> On Sun, 09 Aug 2020 12:17:43 +0100, Jonathan Cameron wrote:
> > From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > 
> > Very simple conversion of spi device with reference supply.
> > 
> > Added the #io-channel-cells property to allow for consumers.
> > 
> > Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > Cc: Jan Kiszka <jan.kiszka@siemens.com>
> > ---
> >  .../bindings/iio/adc/ti,adc108s102.yaml       | 47 +++++++++++++++++++
> >  .../bindings/iio/adc/ti-adc108s102.txt        | 18 -------
> >  2 files changed, 47 insertions(+), 18 deletions(-)
> >   
> 
> Reviewed-by: Rob Herring <robh@kernel.org>

Applied.

Thanks,

Jonathan

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

* Re: [PATCH 04/13] dt-bindings: iio: adc: lltc,ltc2497 yaml conversion.
  2020-08-18  2:28   ` Rob Herring
@ 2020-08-29 17:50     ` Jonathan Cameron
  0 siblings, 0 replies; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-29 17:50 UTC (permalink / raw)
  To: Rob Herring
  Cc: Rob Herring, Jonathan Cameron, devicetree, linux-iio, Michael Hennerich

On Mon, 17 Aug 2020 20:28:30 -0600
Rob Herring <robh@kernel.org> wrote:

> On Sun, 09 Aug 2020 12:17:44 +0100, Jonathan Cameron wrote:
> > From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > 
> > Very simple binding for this i2c device with a reference supply.
> > 
> > Added the #io-channel-cells property to allow for consumers.
> > 
> > Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > Cc: Michael Hennerich <michael.hennerich@analog.com>
> > ---
> >  .../bindings/iio/adc/lltc,ltc2497.yaml        | 44 +++++++++++++++++++
> >  .../devicetree/bindings/iio/adc/ltc2497.txt   | 13 ------
> >  2 files changed, 44 insertions(+), 13 deletions(-)
> >   
> 
> Reviewed-by: Rob Herring <robh@kernel.org>

Applied

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

* Re: [PATCH 05/13] dt-bindings: iio: adc: ti,adc161s626 yaml conversion.
  2020-08-18  2:28   ` Rob Herring
@ 2020-08-29 17:51     ` Jonathan Cameron
  0 siblings, 0 replies; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-29 17:51 UTC (permalink / raw)
  To: Rob Herring
  Cc: Jonathan Cameron, linux-iio, Rob Herring, devicetree, Matt Ranostay

On Mon, 17 Aug 2020 20:28:57 -0600
Rob Herring <robh@kernel.org> wrote:

> On Sun, 09 Aug 2020 12:17:45 +0100, Jonathan Cameron wrote:
> > From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > 
> > Simple conversion for this ADC driver.  Note that I haven't put
> > limits on the spi-max-sampling-frequency because the adc161s626
> > doesn't state one clearly defined value.
> > 
> > Added the #io-channel-cells property to allow for consumers.
> > 
> > Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > Cc: Matt Ranostay <matt.ranostay@konsulko.com>
> > ---
> >  .../bindings/iio/adc/ti,adc161s626.yaml       | 51 +++++++++++++++++++
> >  .../bindings/iio/adc/ti-adc161s626.txt        | 18 -------
> >  2 files changed, 51 insertions(+), 18 deletions(-)
> >   
> 
> Reviewed-by: Rob Herring <robh@kernel.org>
Applied


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

* Re: [PATCH 07/13] dt-bindings: iio: adc: ti,adc084s021 yaml conversion
  2020-08-18  2:30   ` Rob Herring
@ 2020-08-29 17:53     ` Jonathan Cameron
  2020-10-27 15:28       ` Jonathan Cameron
  0 siblings, 1 reply; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-29 17:53 UTC (permalink / raw)
  To: Rob Herring
  Cc: Mårten Lindahl, devicetree, Rob Herring, Jonathan Cameron,
	linux-iio

On Mon, 17 Aug 2020 20:30:00 -0600
Rob Herring <robh@kernel.org> wrote:

> On Sun, 09 Aug 2020 12:17:47 +0100, Jonathan Cameron wrote:
> > From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > 
> > Simple conversion.
> > 
> > Added the #io-channel-cells optional property to allow for consumer
> > bindings if appropriate on a given board.
> > 
> > Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > Cc: Mårten Lindahl <martenli@axis.com>
> > ---
> >  .../bindings/iio/adc/ti,adc084s021.yaml       | 58 +++++++++++++++++++
> >  .../bindings/iio/adc/ti-adc084s021.txt        | 19 ------
> >  2 files changed, 58 insertions(+), 19 deletions(-)
> >   
> 
> Reviewed-by: Rob Herring <robh@kernel.org>
Applied




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

* Re: [PATCH 09/13] dt-bindings: iio: adc: ti,adc128s052 yaml conversion.
  2020-08-18  2:30   ` Rob Herring
@ 2020-08-29 17:55     ` Jonathan Cameron
  0 siblings, 0 replies; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-29 17:55 UTC (permalink / raw)
  To: Rob Herring
  Cc: devicetree, Rob Herring, Angelo Compagnucci, linux-iio, Jonathan Cameron

On Mon, 17 Aug 2020 20:30:34 -0600
Rob Herring <robh@kernel.org> wrote:

> On Sun, 09 Aug 2020 12:17:49 +0100, Jonathan Cameron wrote:
> > From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > 
> > Simple binding.  Only addition to txt version is
> > as a provider of channels to other devices using the consumer
> > binding.
> > 
> > Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > Cc: Angelo Compagnucci <angelo.compagnucci@gmail.com>
> > ---
> >  .../bindings/iio/adc/ti,adc128s052.yaml       | 59 +++++++++++++++++++
> >  .../bindings/iio/adc/ti-adc128s052.txt        | 25 --------
> >  2 files changed, 59 insertions(+), 25 deletions(-)
> >   
> 
> Reviewed-by: Rob Herring <robh@kernel.org>
Applied


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

* Re: [PATCH 12/13] dt-bindings: iio: adc: tlc4541 - recover accidentally dropped binding doc
  2020-08-09 11:17 ` [PATCH 12/13] dt-bindings: iio: adc: tlc4541 - recover accidentally dropped binding doc Jonathan Cameron
@ 2020-08-29 17:57   ` Jonathan Cameron
  0 siblings, 0 replies; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-29 17:57 UTC (permalink / raw)
  To: linux-iio
  Cc: Rob Herring, devicetree, Phil Reid, Rob Herring, Jonathan Cameron

On Sun,  9 Aug 2020 12:17:52 +0100
Jonathan Cameron <jic23@kernel.org> wrote:

> From: Phil Reid <preid@electromag.com.au>
> 
> JC: Seems that I messed up applying the original driver patches, and
> this file never actually made it into the tree.
> 
> I have picked up original Ack and Sign-off so as to record the
> history.
> 
> Acked-by: Rob Herring <robh@kernel.org>
> Signed-off-by: Phil Reid <preid@electromag.com.au>
> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Applied.

> ---
>  .../devicetree/bindings/iio/adc/ti-tlc4541.txt  | 17 +++++++++++++++++
>  1 file changed, 17 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/iio/adc/ti-tlc4541.txt b/Documentation/devicetree/bindings/iio/adc/ti-tlc4541.txt
> new file mode 100644
> index 000000000000..6b2692723a04
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/iio/adc/ti-tlc4541.txt
> @@ -0,0 +1,17 @@
> +* Texas Instruments' TLC4541
> +
> +Required properties:
> + - compatible: Should be one of
> +	* "ti,tlc4541"
> +	* "ti,tlc3541"
> +	- reg: SPI chip select number for the device
> + - vref-supply: The regulator supply for ADC reference voltage
> + - spi-max-frequency: Max SPI frequency to use (<= 200000)
> +
> +Example:
> +adc@0 {
> +	compatible = "ti,tlc4541";
> +	reg = <0>;
> +	vref-supply = <&vdd_supply>;
> +	spi-max-frequency = <200000>;
> +};


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

* Re: [PATCH 11/13] dt-bindings: iio: adc: ti,ads8344 yaml conversion
  2020-08-18  2:31   ` Rob Herring
@ 2020-08-29 17:58     ` Jonathan Cameron
  0 siblings, 0 replies; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-29 17:58 UTC (permalink / raw)
  To: Rob Herring; +Cc: Rob Herring, devicetree, Jonathan Cameron, linux-iio

On Mon, 17 Aug 2020 20:31:56 -0600
Rob Herring <robh@kernel.org> wrote:

> On Sun, 09 Aug 2020 12:17:51 +0100, Jonathan Cameron wrote:
> > From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > 
> > Simple binding so easy to convert.
> > 
> > Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > ---
> >  .../bindings/iio/adc/ti,ads8344.yaml          | 51 +++++++++++++++++++
> >  .../bindings/iio/adc/ti-ads8344.txt           | 19 -------
> >  2 files changed, 51 insertions(+), 19 deletions(-)
> >   
> 
> Reviewed-by: Rob Herring <robh@kernel.org>
Applied

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

* Re: [PATCH 13/13] dt-bindings: iio: adc: ti,tlc4541 binding conversion
  2020-08-18  2:32   ` Rob Herring
@ 2020-08-29 17:59     ` Jonathan Cameron
  0 siblings, 0 replies; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-29 17:59 UTC (permalink / raw)
  To: Rob Herring
  Cc: Rob Herring, Jonathan Cameron, devicetree, Phil Reid, linux-iio

On Mon, 17 Aug 2020 20:32:43 -0600
Rob Herring <robh@kernel.org> wrote:

> On Sun, 09 Aug 2020 12:17:53 +0100, Jonathan Cameron wrote:
> > From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > 
> > Simple binding so easy to convert.
> > Dropped the stated value of maximum spi bus frequency as it does
> > not seem to correspond to the datasheet.  The value of 200kHz
> > is the max sampling frequency of the ADC, not the clock frequency of
> > the SPI bus.
> > 
> > Added #io-channel-cells to allow use as a provider of channels to
> > other devices via the consumer binding.
> > 
> > Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > Cc: Phil Reid <preid@electromag.com.au>
> > ---
> >  .../bindings/iio/adc/ti,tlc4541.yaml          | 52 +++++++++++++++++++
> >  .../bindings/iio/adc/ti-tlc4541.txt           | 17 ------
> >  2 files changed, 52 insertions(+), 17 deletions(-)
> >   
> 
> Reviewed-by: Rob Herring <robh@kernel.org>

Applied. Thanks.  I'll fix up the remaining patches that need it and send a v2.

Thanks,

Jonathan

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

* Re: [PATCH 01/13] dt-bindings: iio: adc: microchip,mcp3201 yaml conversion.
  2020-08-18  2:24   ` Rob Herring
@ 2020-08-30 13:25     ` Jonathan Cameron
  0 siblings, 0 replies; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-30 13:25 UTC (permalink / raw)
  To: Rob Herring; +Cc: linux-iio, devicetree, Jonathan Cameron, Oskar Andero

On Mon, 17 Aug 2020 20:24:51 -0600
Rob Herring <robh@kernel.org> wrote:

> On Sun, Aug 09, 2020 at 12:17:41PM +0100, Jonathan Cameron wrote:
> > From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > 
> > Drops the deprecated compatibles without the vendor name.
> > Whilst the driver continues to support these for old dt blobs,
> > any dt bindings that are actuallly verified against this document should
> > be fixed to add the vendor name.
> > 
> > Enforces rule that spi-cpol == spi-cpha.  Is there a cleaner way to
> > do this?  
> 
> dependencies:
>   spi-cpol: [ spi-cpha ]
>   spi-cpha: [ spi-cpol ]

Great!

> 
> With that,
> 
> Reviewed-by: Rob Herring <robh@kernel.org>

Applied,

Thanks,

Jonathan

> 
> > 
> > Added the #io-channel-cells property to allow for consumers.
> > 
> > Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > Cc: Oskar Andero <oskar.andero@gmail.com>
> > ---
> >  .../devicetree/bindings/iio/adc/mcp320x.txt   | 57 ------------
> >  .../bindings/iio/adc/microchip,mcp3201.yaml   | 93 +++++++++++++++++++
> >  2 files changed, 93 insertions(+), 57 deletions(-)  


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

* Re: [PATCH 10/13] dt-bindings: iio: adc: ti,ads7950 binding conversion
  2020-08-12 16:30   ` David Lechner
@ 2020-08-30 15:55     ` Jonathan Cameron
  0 siblings, 0 replies; 42+ messages in thread
From: Jonathan Cameron @ 2020-08-30 15:55 UTC (permalink / raw)
  To: David Lechner; +Cc: linux-iio, Rob Herring, devicetree, Jonathan Cameron

On Wed, 12 Aug 2020 11:30:28 -0500
David Lechner <david@lechnology.com> wrote:

> On 8/9/20 6:17 AM, Jonathan Cameron wrote:
> > From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > 
> > Simple conversion.  This binding already had the
> > that is necessary, I'm happy to leave it as previously documented.  
> 
> This commit message doesn't make sense to me. It should probably
> just say "this converts the device tree bindings to yml" or so.

I'm not sure what happened there. I think perhaps a line got accidentally
removed.  It was meant to talk about the fact #io-channel-cells is
marked as required which may not make sense for all boards with this
part.  Will rewrite for v2.

Jonathan

> 
> > 
> > Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > Cc: David Lechner <david@lechnology.com>
> > ---
> >   .../bindings/iio/adc/ti,ads7950.yaml          | 64 +++++++++++++++++++
> >   .../bindings/iio/adc/ti-ads7950.txt           | 23 -------
> >   2 files changed, 64 insertions(+), 23 deletions(-)
> > 
> > diff --git a/Documentation/devicetree/bindings/iio/adc/ti,ads7950.yaml b/Documentation/devicetree/bindings/iio/adc/ti,ads7950.yaml
> > new file mode 100644
> > index 000000000000..a759d9064718
> > --- /dev/null
> > +++ b/Documentation/devicetree/bindings/iio/adc/ti,ads7950.yaml
> > @@ -0,0 +1,64 @@
> > +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
> > +%YAML 1.2
> > +---
> > +$id: http://devicetree.org/schemas/iio/adc/ti,ads7950.yaml#
> > +$schema: http://devicetree.org/meta-schemas/core.yaml#
> > +
> > +title: Texas Instruments ADS7950 and similar ADCs
> > +
> > +maintainers:
> > +  - David Lechner <david@lechnology.com>
> > +
> > +description: |
> > +  Family of 4-16 channel, 8-12 bit ADCs with SPI interface.
> > +
> > +properties:
> > +  compatible:
> > +    enum:
> > +      - ti,ads7950
> > +      - ti,ads7951
> > +      - ti,ads7952
> > +      - ti,ads7953
> > +      - ti,ads7954
> > +      - ti,ads7955
> > +      - ti,ads7956
> > +      - ti,ads7957
> > +      - ti,ads7958
> > +      - ti,ads7959
> > +      - ti,ads7960
> > +      - ti,ads7961
> > +
> > +  reg:
> > +    maxItems: 1
> > +
> > +  spi-max-frequency: true  
> 
> According to the datasheet, max frequency is 20MHz, so this can be:
> 
> spi-max-frequency:
>    maximum: 20000000
> 
> > +
> > +  vref-supply:
> > +    description: Supply the 2.5V or 5V reference voltage  
> 
> Should this say "Supplies ..."?
> 
> > +
> > +  "#io-channel-cells":
> > +    const: 1
> > +
> > +required:
> > +  - compatible
> > +  - reg
> > +  - vref-supply
> > +  - "#io-channel-cells"
> > +
> > +additionalProperties: false
> > +
> > +examples:
> > +  - |
> > +    spi {
> > +        #address-cells = <1>;
> > +        #size-cells = <0>;
> > +
> > +        adc@0 {
> > +            compatible = "ti,ads7957";
> > +            reg = <0>;
> > +            vref-supply = <&refin_supply>;
> > +            spi-max-frequency = <10000000>;
> > +            #io-channel-cells = <1>;
> > +        };
> > +    };  
> 
> 


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

* Re: [PATCH 07/13] dt-bindings: iio: adc: ti,adc084s021 yaml conversion
  2020-08-29 17:53     ` Jonathan Cameron
@ 2020-10-27 15:28       ` Jonathan Cameron
  0 siblings, 0 replies; 42+ messages in thread
From: Jonathan Cameron @ 2020-10-27 15:28 UTC (permalink / raw)
  To: Rob Herring
  Cc: Mårten Lindahl, devicetree, Rob Herring, Jonathan Cameron,
	linux-iio

On Sat, 29 Aug 2020 18:53:31 +0100
Jonathan Cameron <jic23@kernel.org> wrote:

> On Mon, 17 Aug 2020 20:30:00 -0600
> Rob Herring <robh@kernel.org> wrote:
> 
> > On Sun, 09 Aug 2020 12:17:47 +0100, Jonathan Cameron wrote:  
> > > From: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > > 
> > > Simple conversion.
> > > 
> > > Added the #io-channel-cells optional property to allow for consumer
> > > bindings if appropriate on a given board.
> > > 
> > > Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
> > > Cc: Mårten Lindahl <martenli@axis.com>
> > > ---
> > >  .../bindings/iio/adc/ti,adc084s021.yaml       | 58 +++++++++++++++++++
> > >  .../bindings/iio/adc/ti-adc084s021.txt        | 19 ------
> > >  2 files changed, 58 insertions(+), 19 deletions(-)
> > >     
> > 
> > Reviewed-by: Rob Herring <robh@kernel.org>  
> Applied
Or apparently I didn't.  Not sure what happened here, but now
actually applied to the togreg branch of iio.git.

Thanks,

Jonathan

> 
> 
> 


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

end of thread, other threads:[~2020-10-27 15:47 UTC | newest]

Thread overview: 42+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-09 11:17 [PATCH 00/13] dt-bindings: yaml conversions of some simple ADC bindings Jonathan Cameron
2020-08-09 11:17 ` [PATCH 01/13] dt-bindings: iio: adc: microchip,mcp3201 yaml conversion Jonathan Cameron
2020-08-18  2:24   ` Rob Herring
2020-08-30 13:25     ` Jonathan Cameron
2020-08-09 11:17 ` [PATCH 02/13] dt-bindings: trivial-devices: Add mcp342x ADCs and drop separate binding doc Jonathan Cameron
2020-08-18  2:27   ` Rob Herring
2020-08-29 17:48     ` Jonathan Cameron
2020-08-09 11:17 ` [PATCH 03/13] dt-bindings: iio: adc: ti,adc108s102 yaml conversion Jonathan Cameron
2020-08-18  2:27   ` Rob Herring
2020-08-29 17:50     ` Jonathan Cameron
2020-08-09 11:17 ` [PATCH 04/13] dt-bindings: iio: adc: lltc,ltc2497 " Jonathan Cameron
2020-08-18  2:28   ` Rob Herring
2020-08-29 17:50     ` Jonathan Cameron
2020-08-09 11:17 ` [PATCH 05/13] dt-bindings: iio: adc: ti,adc161s626 " Jonathan Cameron
2020-08-11  3:35   ` Matt Ranostay
2020-08-18  2:28   ` Rob Herring
2020-08-29 17:51     ` Jonathan Cameron
2020-08-09 11:17 ` [PATCH 06/13] dt-bindings: iio: adc: ti,adc0832 " Jonathan Cameron
2020-08-18  2:29   ` Rob Herring
2020-08-09 11:17 ` [PATCH 07/13] dt-bindings: iio: adc: ti,adc084s021 " Jonathan Cameron
2020-08-18  2:30   ` Rob Herring
2020-08-29 17:53     ` Jonathan Cameron
2020-10-27 15:28       ` Jonathan Cameron
2020-08-09 11:17 ` [PATCH 08/13] dt-bindings: iio: adc: ti,adc12138 " Jonathan Cameron
2020-08-12 16:29   ` Rob Herring
2020-08-16  9:06     ` Jonathan Cameron
2020-08-17 14:17   ` Rob Herring
2020-08-09 11:17 ` [PATCH 09/13] dt-bindings: iio: adc: ti,adc128s052 " Jonathan Cameron
2020-08-18  2:30   ` Rob Herring
2020-08-29 17:55     ` Jonathan Cameron
2020-08-09 11:17 ` [PATCH 10/13] dt-bindings: iio: adc: ti,ads7950 binding conversion Jonathan Cameron
2020-08-12 16:30   ` David Lechner
2020-08-30 15:55     ` Jonathan Cameron
2020-08-09 11:17 ` [PATCH 11/13] dt-bindings: iio: adc: ti,ads8344 yaml conversion Jonathan Cameron
2020-08-18  2:31   ` Rob Herring
2020-08-29 17:58     ` Jonathan Cameron
2020-08-09 11:17 ` [PATCH 12/13] dt-bindings: iio: adc: tlc4541 - recover accidentally dropped binding doc Jonathan Cameron
2020-08-29 17:57   ` Jonathan Cameron
2020-08-09 11:17 ` [PATCH 13/13] dt-bindings: iio: adc: ti,tlc4541 binding conversion Jonathan Cameron
2020-08-10  0:42   ` Phil Reid
2020-08-18  2:32   ` Rob Herring
2020-08-29 17:59     ` Jonathan Cameron

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).