Skip to contentSkip to conversation

dt-bindings:iio: Another set of yaml conversions.

PATCH Superseded Jonathan Cameron 13 participants 62 messages Oct 11, 2020 – Oct 31, 2020

Subsystems (7)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Jonathan Cameron

author maintainer
#0 lore raw

cover dt-bindings:iio: Another set of yaml conversions.

From: Jonathan Cameron <[email protected]>

This set mostly consists of low hanging fruit along the way to converting all the existing IIO bindings.

A few questions scattered throughout though. Whilst my skills in these are hopefully improving it seems there are still plenty more corner cases that I'm not sure how to handle! I'm sure I'll have forgotten something that I should already know as well.

I'm expecting some of these to bounce due to changes of addresses etc. If I can't track down up to date emails, I'll switch them maintainer to myself on the basis I'll be reviewing any incoming changes for these anyway.

Thanks,

Jonathan

Jonathan Cameron (29):
dt-bindings:iio:humidity:hdc100x Drop separate doc + add to
trivial-devices
dt-bindings:iio:humidity:htu21 Drop separate doc + add to
trivial-devices
dt-bindings:iio:humidity:st,hts221 yaml conversion. dt-bindings:iio:humidity:dht11 yaml conversion dt-bindings:iio:pressure:ms5637 Drop separate doc + add to
trivial-devices
dt-bindings:iio:pressure:murata,zpa2326 yaml conversion dt-bindings:iio:pressure:meas,ms5611 yaml conversion. dt-bindings:iio:pressure:hoperf,hp03 yaml conversion dt-bindings:iio:proximity:semtech,sx9500 yaml conversion. dt-bindings:iio:proximity:st,vl53l0x yaml conversion dt-bindings:iio:proximity:ams,as3935 yaml conversion dt-bindings:iio:dac:ti,dac5571 yaml conversion. dt-bindings:iio:dac:ti,dac7311 yaml conversion dt-bindings:iio:dac:ti,dac7512 yaml conversion dt-bindings:iio:dac:ti,dac7612 yaml conversion dt-bindings:iio:dac:ti,dac082s085 yaml conversion dt-bindings:iio:dac:adi,ad7303 yaml conversion dt-bindings:iio:dac:maxim,ds4424 yaml conversion dt-bindings:iio:dac:fsl,vf610-dac yaml conversion dt-bindings:iio:dac:microchip,mcp4725 yaml conversion dt-bindings:iio:dac:maxim,max5821 yaml conversion dt-bindings:iio:dac:nxp,lpc1850-dac yaml conversion. dt-bindings:iio:dac:adi,ad5758 yaml conversion dt-bindings:iio:temperature:melexis,mlx90614 yaml conversion dt-bindings:iio:temperature:melexis,mlx90632 conversion to yaml dt-bindings:iio:temperature:meas,tsys01 move to trivial-devices.yaml dt-bindings:iio:temperature:maxim,max31856 yaml conversion. dt-bindings:iio:temperature:maxim_thermocouple.txt to

    maxim,max31855k.yaml

dt-bindings:iio:temperature:ti,tmp07 yaml conversion

 .../devicetree/bindings/iio/dac/ad5758.txt    |  83 -----------
 .../devicetree/bindings/iio/dac/ad7303.txt    |  23 ----
 .../bindings/iio/dac/adi,ad5758.yaml          | 129 ++++++++++++++++++
 .../bindings/iio/dac/adi,ad7303.yaml          |  51 +++++++
 .../devicetree/bindings/iio/dac/ds4424.txt    |  20 ---
 .../bindings/iio/dac/fsl,vf610-dac.yaml       |  55 ++++++++
 .../bindings/iio/dac/lpc1850-dac.txt          |  19 ---
 .../devicetree/bindings/iio/dac/max5821.txt   |  14 --
 .../bindings/iio/dac/maxim,ds4424.yaml        |  45 ++++++
 .../bindings/iio/dac/maxim,max5821.yaml       |  44 ++++++
 .../devicetree/bindings/iio/dac/mcp4725.txt   |  35 -----
 .../bindings/iio/dac/microchip,mcp4725.yaml   |  71 ++++++++++
 .../bindings/iio/dac/nxp,lpc1850-dac.yaml     |  58 ++++++++
 .../bindings/iio/dac/ti,dac082s085.yaml       |  58 ++++++++
 .../bindings/iio/dac/ti,dac5571.txt           |  24 ----
 .../bindings/iio/dac/ti,dac5571.yaml          |  52 +++++++
 .../bindings/iio/dac/ti,dac7311.txt           |  23 ----
 .../bindings/iio/dac/ti,dac7311.yaml          |  49 +++++++
 .../bindings/iio/dac/ti,dac7512.txt           |  20 ---
 .../bindings/iio/dac/ti,dac7512.yaml          |  42 ++++++
 .../bindings/iio/dac/ti,dac7612.txt           |  28 ----
 .../bindings/iio/dac/ti,dac7612.yaml          |  53 +++++++
 .../bindings/iio/dac/ti-dac082s085.txt        |  34 -----
 .../devicetree/bindings/iio/dac/vf610-dac.txt |  20 ---
 .../bindings/iio/humidity/dht11.txt           |  14 --
 .../bindings/iio/humidity/dht11.yaml          |  41 ++++++
 .../bindings/iio/humidity/hdc100x.txt         |  17 ---
 .../bindings/iio/humidity/hts221.txt          |  30 ----
 .../bindings/iio/humidity/htu21.txt           |  13 --
 .../bindings/iio/humidity/st,hts221.yaml      |  52 +++++++
 .../bindings/iio/pressure/hoperf,hp03.yaml    |  47 +++++++
 .../devicetree/bindings/iio/pressure/hp03.txt |  17 ---
 .../bindings/iio/pressure/meas,ms5611.yaml    |  57 ++++++++
 .../bindings/iio/pressure/ms5611.txt          |  19 ---
 .../bindings/iio/pressure/ms5637.txt          |  17 ---
 .../bindings/iio/pressure/murata,zpa2326.yaml |  62 +++++++++
 .../bindings/iio/pressure/zpa2326.txt         |  29 ----
 .../bindings/iio/proximity/ams,as3935.yaml    |  71 ++++++++++
 .../bindings/iio/proximity/as3935.txt         |  34 -----
 .../iio/proximity/semtech,sx9500.yaml         |  50 +++++++
 .../bindings/iio/proximity/st,vl53l0x.yaml    |  42 ++++++
 .../bindings/iio/proximity/sx9500.txt         |  23 ----
 .../bindings/iio/proximity/vl53l0x.txt        |  18 ---
 .../bindings/iio/temperature/max31856.txt     |  24 ----
 .../iio/temperature/maxim,max31855k.yaml      |  76 +++++++++++
 .../iio/temperature/maxim,max31856.yaml       |  54 ++++++++
 .../iio/temperature/maxim_thermocouple.txt    |  24 ----
 .../iio/temperature/melexis,mlx90614.yaml     |  51 +++++++
 .../iio/temperature/melexis,mlx90632.yaml     |  55 ++++++++
 .../bindings/iio/temperature/mlx90614.txt     |  24 ----
 .../bindings/iio/temperature/mlx90632.txt     |  28 ----
 .../bindings/iio/temperature/ti,tmp007.yaml   |  57 ++++++++
 .../bindings/iio/temperature/tmp007.txt       |  33 -----
 .../bindings/iio/temperature/tsys01.txt       |  19 ---
 .../devicetree/bindings/trivial-devices.yaml  |  24 ++++
 55 files changed, 1446 insertions(+), 726 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/iio/dac/ad5758.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/dac/ad7303.txt
 create mode 100644 Documentation/devicetree/bindings/iio/dac/adi,ad5758.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/dac/adi,ad7303.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/dac/ds4424.txt
 create mode 100644 Documentation/devicetree/bindings/iio/dac/fsl,vf610-dac.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/dac/lpc1850-dac.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/dac/max5821.txt
 create mode 100644 Documentation/devicetree/bindings/iio/dac/maxim,ds4424.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/dac/maxim,max5821.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/dac/mcp4725.txt
 create mode 100644 Documentation/devicetree/bindings/iio/dac/microchip,mcp4725.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/dac/nxp,lpc1850-dac.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/dac/ti,dac5571.txt
 create mode 100644 Documentation/devicetree/bindings/iio/dac/ti,dac5571.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/dac/ti,dac7311.txt
 create mode 100644 Documentation/devicetree/bindings/iio/dac/ti,dac7311.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/dac/ti,dac7512.txt
 create mode 100644 Documentation/devicetree/bindings/iio/dac/ti,dac7512.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/dac/ti,dac7612.txt
 create mode 100644 Documentation/devicetree/bindings/iio/dac/ti,dac7612.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/dac/ti-dac082s085.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/dac/vf610-dac.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/humidity/dht11.txt
 create mode 100644 Documentation/devicetree/bindings/iio/humidity/dht11.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/humidity/hdc100x.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/humidity/hts221.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/humidity/htu21.txt
 create mode 100644 Documentation/devicetree/bindings/iio/humidity/st,hts221.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/pressure/hoperf,hp03.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/pressure/hp03.txt
 create mode 100644 Documentation/devicetree/bindings/iio/pressure/meas,ms5611.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/pressure/ms5611.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/pressure/ms5637.txt
 create mode 100644 Documentation/devicetree/bindings/iio/pressure/murata,zpa2326.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/pressure/zpa2326.txt
 create mode 100644 Documentation/devicetree/bindings/iio/proximity/ams,as3935.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/proximity/as3935.txt
 create mode 100644 Documentation/devicetree/bindings/iio/proximity/semtech,sx9500.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/proximity/st,vl53l0x.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/proximity/sx9500.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/proximity/vl53l0x.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/temperature/max31856.txt
 create mode 100644 Documentation/devicetree/bindings/iio/temperature/maxim,max31855k.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/temperature/maxim,max31856.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/temperature/maxim_thermocouple.txt
 create mode 100644 Documentation/devicetree/bindings/iio/temperature/melexis,mlx90614.yaml
 create mode 100644 Documentation/devicetree/bindings/iio/temperature/melexis,mlx90632.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/temperature/mlx90614.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/temperature/mlx90632.txt
 create mode 100644 Documentation/devicetree/bindings/iio/temperature/ti,tmp007.yaml
 delete mode 100644 Documentation/devicetree/bindings/iio/temperature/tmp007.txt
 delete mode 100644 Documentation/devicetree/bindings/iio/temperature/tsys01.txt
Signature · 1 line
2.28.0
author maintainer
#1 lore raw

PATCH 1/29 dt-bindings:iio:humidity:hdc100x Drop separate doc + add to trivial-devices

From: Jonathan Cameron <[email protected]>

Very simple binding for this i2c device with no properties beyond reg and compatible. Hence doesn't need it's own document.

---
 .../bindings/iio/humidity/hdc100x.txt           | 17 -----------------
 .../devicetree/bindings/trivial-devices.yaml    | 10 ++++++++++
 2 files changed, 10 insertions(+), 17 deletions(-)
Documentation/devicetree/bindings/iio/humidity/hdc100x.txt deleted +0 -17
deleted file mode 100644
index c52333bdfd19..000000000000
@@ -1,17 +0,0 @@
-* HDC100x temperature + humidity sensors
-
-Required properties:
-  - compatible: Should contain one of the following:
-	ti,hdc1000
-	ti,hdc1008
-	ti,hdc1010
-	ti,hdc1050
-	ti,hdc1080
-  - reg: i2c address of the sensor
-
-Example:
-
-hdc100x@40 {
-	compatible = "ti,hdc1000";
-	reg = <0x40>;
-};
Documentation/devicetree/bindings/trivial-devices.yaml +10 -0
index 25cfcc904240..9f8531d4d33e 100644
@@ -352,6 +352,16 @@ properties:
           - ti,ads7830
             # Temperature Monitoring and Fan Control
           - ti,amc6821
+            # Temperature and humidity sensor with i2c interface
+          - ti,hdc1000
+            # Temperature and humidity sensor with i2c interface
+          - ti,hdc1008
+            # Temperature and humidity sensor with i2c interface
+          - ti,hdc1010
+            # Temperature and humidity sensor with i2c interface
+          - ti,hdc1050
+            # Temperature and humidity sensor with i2c interface
+          - ti,hdc1080
             # Temperature sensor with 2-wire interface
           - ti,lm73
             # Temperature sensor with integrated fan control
Signature · 1 line
2.28.0
Acked-by on v1 1/29
#2 lore raw

Re: [PATCH 01/29] dt-bindings:iio:humidity:hdc100x Drop separate doc + add to trivial-devices

Quoted 8 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Very simple binding for this i2c device with no properties beyond reg and compatible. Hence doesn't need it's own document.

Quoted 52 lines
---
 .../bindings/iio/humidity/hdc100x.txt           | 17 -----------------
 .../devicetree/bindings/trivial-devices.yaml    | 10 ++++++++++
 2 files changed, 10 insertions(+), 17 deletions(-)
Documentation/devicetree/bindings/iio/humidity/hdc100x.txt deleted +0 -17
deleted file mode 100644
index c52333bdfd19..000000000000
@@ -1,17 +0,0 @@
-* HDC100x temperature + humidity sensors
-
-Required properties:
-  - compatible: Should contain one of the following:
-       ti,hdc1000
-       ti,hdc1008
-       ti,hdc1010
-       ti,hdc1050
-       ti,hdc1080
-  - reg: i2c address of the sensor
-
-Example:
-
-hdc100x@40 {
-       compatible = "ti,hdc1000";
-       reg = <0x40>;
-};
Documentation/devicetree/bindings/trivial-devices.yaml +10 -1
index 25cfcc904240..9f8531d4d33e 100644
@@ -352,6 +352,16 @@ properties:
           - ti,ads7830
             # Temperature Monitoring and Fan Control
           - ti,amc6821
+            # Temperature and humidity sensor with i2c interface
+          - ti,hdc1000
+            # Temperature and humidity sensor with i2c interface
+          - ti,hdc1008
+            # Temperature and humidity sensor with i2c interface
+          - ti,hdc1010
+            # Temperature and humidity sensor with i2c interface
+          - ti,hdc1050
+            # Temperature and humidity sensor with i2c interface
+          - ti,hdc1080
             # Temperature sensor with 2-wire interface
           - ti,lm73
             # Temperature sensor with integrated fan control
--

2.28.0

author maintainer
#3 lore raw

PATCH 2/29 dt-bindings:iio:humidity:htu21 Drop separate doc + add to trivial-devices

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Very simple binding for this i2c device with no properties beyond reg and compatible. Hence doesn't need it's own document.

Cc William Markezana <[email protected]>
Cc Ludovic Tancerel <[email protected]>
---
 .../devicetree/bindings/iio/humidity/htu21.txt      | 13 -------------
 .../devicetree/bindings/trivial-devices.yaml        |  4 ++++
 2 files changed, 4 insertions(+), 13 deletions(-)
Documentation/devicetree/bindings/iio/humidity/htu21.txt deleted +0 -13
deleted file mode 100644
index 97d79636f7ae..000000000000
@@ -1,13 +0,0 @@
-*HTU21 - Measurement-Specialties htu21 temperature & humidity sensor and humidity part of MS8607 sensor
-
-Required properties:
-
-	- compatible: should be "meas,htu21" or "meas,ms8607-humidity"
-	- reg: I2C address of the sensor
-
-Example:
-
-htu21@40 {
-	compatible = "meas,htu21";
-	reg = <0x40>;
-};
Documentation/devicetree/bindings/trivial-devices.yaml +4 -0
index 9f8531d4d33e..49c67a6a1332 100644
@@ -128,6 +128,10 @@ properties:
           - mcube,mc3230
             # MEMSIC 2-axis 8-bit digital accelerometer
           - memsic,mxc6225
+            # Measurement Specialities I2C temperature and humidity sensor
+          - meas,htu21
+            # Measurement Specialities temp and humidity part of ms8607 device
+          - meas,ms8607-humidity
             # Microchip differential I2C ADC, 1 Channel, 18 bit
           - microchip,mcp3421
             # Microchip differential I2C ADC, 2 Channel, 18 bit
Signature · 1 line
2.28.0
author maintainer
#4 lore raw

PATCH 3/29 dt-bindings:iio:humidity:st,hts221 yaml conversion.

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Straight forward conversion of this temperature and pressure sensor binding.

---
 .../bindings/iio/humidity/hts221.txt          | 30 -----------
 .../bindings/iio/humidity/st,hts221.yaml      | 52 +++++++++++++++++++
 2 files changed, 52 insertions(+), 30 deletions(-)
Documentation/devicetree/bindings/iio/humidity/hts221.txt deleted +0 -30
deleted file mode 100644
index 84d029372260..000000000000
@@ -1,30 +0,0 @@
-* HTS221 STM humidity + temperature sensor
-
-Required properties:
-- compatible: should be "st,hts221"
-- reg: i2c address of the sensor / spi cs line
-
-Optional properties:
-- drive-open-drain: the interrupt/data ready line will be configured
-  as open drain, which is useful if several sensors share the same
-  interrupt line. This is a boolean property.
-  If the requested interrupt is configured as IRQ_TYPE_LEVEL_HIGH or
-  IRQ_TYPE_EDGE_RISING a pull-down resistor is needed to drive the line
-  when it is not active, whereas a pull-up one is needed when interrupt
-  line is configured as IRQ_TYPE_LEVEL_LOW or IRQ_TYPE_EDGE_FALLING.
-  Refer to pinctrl/pinctrl-bindings.txt for the property description.
-- interrupts: interrupt mapping for IRQ. It should be configured with
-  flags IRQ_TYPE_LEVEL_HIGH, IRQ_TYPE_EDGE_RISING, IRQ_TYPE_LEVEL_LOW or
-  IRQ_TYPE_EDGE_FALLING.
-
-  Refer to interrupt-controller/interrupts.txt for generic interrupt
-  client node bindings.
-
-Example:
-
-hts221@5f {
-	compatible = "st,hts221";
-	reg = <0x5f>;
-	interrupt-parent = <&gpio0>;
-	interrupts = <0 IRQ_TYPE_EDGE_RISING>;
-};
Documentation/devicetree/bindings/iio/humidity/st,hts221.yaml new file +52 -0

52 lines not on this page · raw message

Signature · 1 line
2.28.0
author maintainer
#5 lore raw

PATCH 4/29 dt-bindings:iio:humidity:dht11 yaml conversion

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

The conversion is straight forward, but leaves an open question. The compatible for this device has never had a vendor. I suspect this because it is non-obvious who actually makes the module. It is resold by numerous vendors and it may be that there is no single vendor of the parts they are using. If anyone has any more info on the vendor, please let me know and we can add a more informative compatible.

---
 .../bindings/iio/humidity/dht11.txt           | 14 -------
 .../bindings/iio/humidity/dht11.yaml          | 41 +++++++++++++++++++
 2 files changed, 41 insertions(+), 14 deletions(-)
Documentation/devicetree/bindings/iio/humidity/dht11.txt deleted +0 -14
deleted file mode 100644
index ecc24c199fd6..000000000000
@@ -1,14 +0,0 @@
-* DHT11 humidity/temperature sensor (and compatibles like DHT22)
-
-Required properties:
-  - compatible: Should be "dht11"
-  - gpios: Should specify the GPIO connected to the sensor's data
-    line, see "gpios property" in
-    Documentation/devicetree/bindings/gpio/gpio.txt.
-
-Example:
-
-humidity_sensor {
-	compatible = "dht11";
-	gpios = <&gpio0 6 0>;
-}
Documentation/devicetree/bindings/iio/humidity/dht11.yaml new file +41 -0

41 lines not on this page · raw message

Signature · 1 line
2.28.0
Acked-by on v1 4/29
#6 lore raw

Re: [PATCH 04/29] dt-bindings:iio:humidity:dht11 yaml conversion

Quoted 9 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

The conversion is straight forward, but leaves an open question. The compatible for this device has never had a vendor. I suspect this because it is non-obvious who actually makes the module. It is resold by numerous vendors and it may be that there is no single vendor of the parts they are using. If anyone has any more info on the vendor, please let me know and we can add a more informative compatible.

I think these parts come from Aosong: http://www.aosong.com/en/

The DHT11 uses a custom protocol, so I don't think other vendors would be using this. Even Aosong started using i2c by now.

On the other hand DHT11 seems to be more of a trade name then a part identifier. The latter probably would be something like aosong,am2302 (trade name DHT22).

However the matching between identifiers and trade names is confusing for the older products. I'm not sure if it is worth digging into this. Probably only the people at aosong could clear this up.

Anyway, you have my:

Thanks,
Harald

Quoted 81 lines
---
 .../bindings/iio/humidity/dht11.txt           | 14 -------
 .../bindings/iio/humidity/dht11.yaml          | 41 
+++++++++++++++++++
 2 files changed, 41 insertions(+), 14 deletions(-)
Documentation/devicetree/bindings/iio/humidity/dht11.txt deleted +0 -14
deleted file mode 100644
index ecc24c199fd6..000000000000
@@ -1,14 +0,0 @@
-* DHT11 humidity/temperature sensor (and compatibles like DHT22)
-
-Required properties:
-  - compatible: Should be "dht11"
-  - gpios: Should specify the GPIO connected to the sensor's data
-    line, see "gpios property" in
-    Documentation/devicetree/bindings/gpio/gpio.txt.
-
-Example:
-
-humidity_sensor {
-	compatible = "dht11";
-	gpios = <&gpio0 6 0>;
-}

diff --git a/Documentation/devicetree/bindings/iio/humidity/dht11.yaml b/Documentation/devicetree/bindings/iio/humidity/dht11.yaml new file mode 100644
index 000000000000..38ec4c302760

Documentation/devicetree/bindings/iio/humidity/dht11.yaml new file +13 -0
@@ -0,0 +1,41 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/humidity/dht11.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: DHT11 humidity + temperature sensor
+
+maintainers:
+  - Harald Geyer <[email protected]>
+
+description: |
+   A simple and low cost module providing a non standard single GPIO 

based
+ interface. Whilst commonly available it is not easy to establish
if there

Documentation/devicetree/bindings/iio/humidity/dht11.yaml new file +13 -0
+   is a single manufacturer for this part.
+
+properties:
+  compatible:
+    const: dht11
+
+  reg:
+    maxItems: 1
+
+  gpios:
+    maxItems: 1
+    description:
+      Single, interrupt capable, GPIO used to communicate with the 

device.

Documentation/devicetree/bindings/iio/humidity/dht11.yaml new file +14 -0
+
+required:
+  - compatible
+  - gpios
+
+additionalProperties: false
+
+examples:
+  - |
+    humidity_sensor {
+        compatible = "dht11";
+        gpios = <&gpio0 6 0>;
+    };
+...
Signature · 4 lines
Es gibt viele Maßnahmen gegen die Klimakrise, die leicht und ohne
Verlierer umsetzbar sind. Das Problem ist immer noch das Desinteresse
der etablierten Parteien.
https://haraldgeyer.at/Klimaschutz.html
#7 lore raw

Re: [PATCH 04/29] dt-bindings:iio:humidity:dht11 yaml conversion

Quoted 17 lines · On Sun, 11 Oct 2020 18:52:48 +0100 Harald Geyer <[email protected]> wrote:
Quoted 10 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

The conversion is straight forward, but leaves an open question. The compatible for this device has never had a vendor. I suspect this because it is non-obvious who actually makes the module. It is resold by numerous vendors and it may be that there is no single vendor
of the parts they are using. If anyone has any more info on the vendor, please let me know and we can add a more informative compatible.

I think these parts come from Aosong: http://www.aosong.com/en/

The DHT11 uses a custom protocol, so I don't think other vendors would be using this. Even Aosong started using i2c by now.

Quoted 8 lines

On the other hand DHT11 seems to be more of a trade name then a part identifier. The latter probably would be something like aosong,am2302 (trade name DHT22).

However the matching between identifiers and trade names is confusing for the older products. I'm not sure if it is worth digging into this. Probably only the people at aosong could clear this up.

Probably worth adding a note to the binding doc so I'll do that whilst applying or for a v2 if needed. Thanks for the info!

Quoted 89 lines

Anyway, you have my:

Thanks,
Harald

Quoted 81 lines
---
 .../bindings/iio/humidity/dht11.txt           | 14 -------
 .../bindings/iio/humidity/dht11.yaml          | 41 
+++++++++++++++++++
 2 files changed, 41 insertions(+), 14 deletions(-)
Documentation/devicetree/bindings/iio/humidity/dht11.txt deleted +0 -14
deleted file mode 100644
index ecc24c199fd6..000000000000
@@ -1,14 +0,0 @@
-* DHT11 humidity/temperature sensor (and compatibles like DHT22)
-
-Required properties:
-  - compatible: Should be "dht11"
-  - gpios: Should specify the GPIO connected to the sensor's data
-    line, see "gpios property" in
-    Documentation/devicetree/bindings/gpio/gpio.txt.
-
-Example:
-
-humidity_sensor {
-	compatible = "dht11";
-	gpios = <&gpio0 6 0>;
-}

diff --git a/Documentation/devicetree/bindings/iio/humidity/dht11.yaml b/Documentation/devicetree/bindings/iio/humidity/dht11.yaml new file mode 100644
index 000000000000..38ec4c302760

Documentation/devicetree/bindings/iio/humidity/dht11.yaml new file +13 -0
@@ -0,0 +1,41 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/humidity/dht11.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: DHT11 humidity + temperature sensor
+
+maintainers:
+  - Harald Geyer <[email protected]>
+
+description: |
+   A simple and low cost module providing a non standard single GPIO 

based
+ interface. Whilst commonly available it is not easy to establish
if there

Documentation/devicetree/bindings/iio/humidity/dht11.yaml new file +13 -0
+   is a single manufacturer for this part.
+
+properties:
+  compatible:
+    const: dht11
+
+  reg:
+    maxItems: 1
+
+  gpios:
+    maxItems: 1
+    description:
+      Single, interrupt capable, GPIO used to communicate with the 

device.

Documentation/devicetree/bindings/iio/humidity/dht11.yaml new file +14 -0
+
+required:
+  - compatible
+  - gpios
+
+additionalProperties: false
+
+examples:
+  - |
+    humidity_sensor {
+        compatible = "dht11";
+        gpios = <&gpio0 6 0>;
+    };
+...  
author maintainer
#8 lore raw

PATCH 5/29 dt-bindings:iio:pressure:ms5637 Drop separate doc + add to trivial-devices

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Very simple binding for this i2c device with no properties beyond reg and compatible. Hence doesn't need it's own document.

Cc William Markezana <[email protected]>
Cc Ludovic Tancerel <[email protected]>
---
 .../devicetree/bindings/iio/pressure/ms5637.txt | 17 -----------------
 .../devicetree/bindings/trivial-devices.yaml    |  8 ++++++++
 2 files changed, 8 insertions(+), 17 deletions(-)
Documentation/devicetree/bindings/iio/pressure/ms5637.txt deleted +0 -17
deleted file mode 100644
index 1f43ffa068ac..000000000000
@@ -1,17 +0,0 @@
-* MS5637 - Measurement-Specialties MS5637, MS5805, MS5837 and MS8607 pressure & temperature sensor
-
-Required properties:
-
-	-compatible: should be one of the following
-		meas,ms5637
-		meas,ms5805
-		meas,ms5837
-		meas,ms8607-temppressure
-	-reg: I2C address of the sensor
-
-Example:
-
-ms5637@76 {
-	compatible = "meas,ms5637";
-	reg = <0x76>;
-};
Documentation/devicetree/bindings/trivial-devices.yaml +8 -0
index 49c67a6a1332..a8db256c2a93 100644
@@ -130,8 +130,16 @@ properties:
           - memsic,mxc6225
             # Measurement Specialities I2C temperature and humidity sensor
           - meas,htu21
+            # Measurement Specialities I2C pressure and temperature sensor
+          - meas,ms5637
+            # Measurement Specialities I2C pressure and temperature sensor
+          - meas,ms5805
+            # Measurement Specialities I2C pressure and temperature sensor
+          - meas,ms5837
             # Measurement Specialities temp and humidity part of ms8607 device
           - meas,ms8607-humidity
+            # Measurement Specialities temp and pressure part of ms8607 device
+          - meas,ms8607-temppressure
             # Microchip differential I2C ADC, 1 Channel, 18 bit
           - microchip,mcp3421
             # Microchip differential I2C ADC, 2 Channel, 18 bit
Signature · 1 line
2.28.0
author maintainer
#9 lore raw

PATCH 6/29 dt-bindings:iio:pressure:murata,zpa2326 yaml conversion

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Simple conversion with a few minor tweaks:
* I added 1MHz max for spi-max-frequency
* I have give myself as the maintainer. This driver was written by Gregor Boirie but I don't have an up to date email address for Gregor.

---
 .../bindings/iio/pressure/murata,zpa2326.yaml | 62 +++++++++++++++++++
 .../bindings/iio/pressure/zpa2326.txt         | 29 ---------
 2 files changed, 62 insertions(+), 29 deletions(-)
Documentation/devicetree/bindings/iio/pressure/murata,zpa2326.yaml new file +62 -0
new file mode 100644
index 000000000000..d6103be03460
@@ -0,0 +1,62 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/pressure/murata,zpa2326.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Murata ZPA2326 pressure sensor
+
+maintainers:
+  - Jonathan Cameron <[email protected]>
+
+description: |
+  Pressure sensor from Murata with SPI and I2C bus interfaces.
+
+
+properties:
+  compatible:
+    const: murata,zpa2326
+
+  reg:
+    maxItems: 1
+
+  vdd-supply: true
+  vref-supply: true
+
+  interrupts:
+    maxItems: 1
+
+  spi-max-frequency:
+    maximum: 1000000
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        pressure@5c {
+            compatible = "murata,zpa2326";
+            reg = <0x5c>;
+            interrupt-parent = <&gpio>;
+            interrupts = <12>;
+            vdd-supply = <&ldo_1v8_gnss>;
+        };
+    };
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+        pressure@0 {
+            compatible = "murata,zpa2326";
+            reg = <0>;
+            spi-max-frequency = <500000>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/pressure/zpa2326.txt deleted +0 -29
deleted file mode 100644
index a36ab3e0c3f7..000000000000
@@ -1,29 +0,0 @@
-Murata ZPA2326 pressure sensor
-
-Pressure sensor from Murata with SPI and I2C bus interfaces.
-
-Required properties:
-- compatible: "murata,zpa2326"
-- reg: the I2C address or SPI chip select the device will respond to
-
-Recommended properties for SPI bus usage:
-- spi-max-frequency: maximum SPI bus frequency as documented in
-  Documentation/devicetree/bindings/spi/spi-bus.txt
-
-Optional properties:
-- vref-supply: an optional regulator that needs to be on to provide VREF
-  power to the sensor
-- vdd-supply: an optional regulator that needs to be on to provide VDD
-  power to the sensor
-- interrupts: interrupt mapping for IRQ as documented in
-  Documentation/devicetree/bindings/interrupt-controller/interrupts.txt
-
-Example:
-
-zpa2326@5c {
-	compatible = "murata,zpa2326";
-	reg = <0x5c>;
-	interrupt-parent = <&gpio>;
-	interrupts = <12>;
-	vdd-supply = <&ldo_1v8_gnss>;
-};
Signature · 1 line
2.28.0
author maintainer
#10 lore raw

PATCH 7/29 dt-bindings:iio:pressure:meas,ms5611 yaml conversion.

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

One addition here was to put in a 20MHz maximum for the SPI bus as specified in the datasheets of both support parts.

---
 .../bindings/iio/pressure/meas,ms5611.yaml    | 57 +++++++++++++++++++
 .../bindings/iio/pressure/ms5611.txt          | 19 -------
 2 files changed, 57 insertions(+), 19 deletions(-)
Documentation/devicetree/bindings/iio/pressure/meas,ms5611.yaml new file +57 -0
new file mode 100644
index 000000000000..4f06707450bf
@@ -0,0 +1,57 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/pressure/meas,ms5611.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Measurement Specialities ms5611 and similar pressure sensors
+
+maintainers:
+  - Tomasz Duszynski <[email protected]>
+
+description: |
+  Pressure sensors from MEAS Switzerland with SPI and I2C bus interfaces.
+
+properties:
+  compatible:
+    enum:
+      - meas,ms5607
+      - meas,ms5611
+
+  reg:
+    maxItems: 1
+
+  vdd-supply: true
+
+  spi-max-frequency:
+    maximum: 20000000
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        pressure@77 {
+            compatible = "meas,ms5607";
+            reg = <0x77>;
+            vdd-supply = <&ldo_3v3_gnss>;
+        };
+    };
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+        pressure@0 {
+            compatible = "meas,ms5611";
+            reg = <0>;
+            vdd-supply = <&ldo_3v3_gnss>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/pressure/ms5611.txt deleted +0 -19
deleted file mode 100644
index 17bca866c084..000000000000
@@ -1,19 +0,0 @@
-MEAS ms5611 family pressure sensors
-
-Pressure sensors from MEAS Switzerland with SPI and I2C bus interfaces.
-
-Required properties:
-- compatible: "meas,ms5611" or "meas,ms5607"
-- reg: the I2C address or SPI chip select the device will respond to
-
-Optional properties:
-- vdd-supply: an optional regulator that needs to be on to provide VDD
-  power to the sensor.
-
-Example:
-
-ms5607@77 {
-	compatible = "meas,ms5607";
-	reg = <0x77>;
-	vdd-supply = <&ldo_3v3_gnss>;
-};
Signature · 1 line
2.28.0
author maintainer
#11 lore raw

PATCH 8/29 dt-bindings:iio:pressure:hoperf,hp03 yaml conversion

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

One quirk in the txt file was that the xclr gpio was specified as gpio-xclr rather than gpios-xclr. I've fixed that in the yaml version.

---
 .../bindings/iio/pressure/hoperf,hp03.yaml    | 47 +++++++++++++++++++
 .../devicetree/bindings/iio/pressure/hp03.txt | 17 -------
 2 files changed, 47 insertions(+), 17 deletions(-)
Documentation/devicetree/bindings/iio/pressure/hoperf,hp03.yaml new file +47 -0
new file mode 100644
index 000000000000..69a3759e23db
@@ -0,0 +1,47 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/pressure/hoperf,hp03.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: HopeRF HP03 digital pressure/temperature sensors
+
+maintainers:
+  - Marek Vasut <[email protected]>
+
+description: |
+  Digital pressure and temperature sensor with an I2C interface.
+
+properties:
+  compatible:
+    const: hoperf,hp03
+
+  reg:
+    maxItems: 1
+
+  xclr-gpios:
+    description:
+      The XCLR pin is a reset of the ADC in the chip, it must be pulled
+      HI before the conversion and readout of the value from the ADC
+      registers and pulled LO afterward.
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        pressure@77 {
+            compatible = "hoperf,hp03";
+            reg = <0x77>;
+            xclr-gpios = <&portc 0 0x0>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/pressure/hp03.txt deleted +0 -17
deleted file mode 100644
index 831dbee7a5c3..000000000000
@@ -1,17 +0,0 @@
-HopeRF HP03 digital pressure/temperature sensors
-
-Required properties:
-- compatible: must be "hoperf,hp03"
-- xclr-gpio: must be device tree identifier of the XCLR pin.
-             The XCLR pin is a reset of the ADC in the chip,
-             it must be pulled HI before the conversion and
-             readout of the value from the ADC registers and
-             pulled LO afterward.
-
-Example:
-
-hp03@77 {
-	compatible = "hoperf,hp03";
-	reg = <0x77>;
-	xclr-gpio = <&portc 0 0x0>;
-};
Signature · 1 line
2.28.0
#12 lore raw

Re: [PATCH 08/29] dt-bindings:iio:pressure:hoperf,hp03 yaml conversion

Quoted 5 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

One quirk in the txt file was that the xclr gpio was specified as gpio-xclr rather than gpios-xclr. I've fixed that in the

xclr-gpios?, not gpios?-xclr

Quoted 88 lines

yaml version.

---
 .../bindings/iio/pressure/hoperf,hp03.yaml    | 47 +++++++++++++++++++
 .../devicetree/bindings/iio/pressure/hp03.txt | 17 -------
 2 files changed, 47 insertions(+), 17 deletions(-)
Documentation/devicetree/bindings/iio/pressure/hoperf,hp03.yaml new file +47 -0
new file mode 100644
index 000000000000..69a3759e23db
@@ -0,0 +1,47 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/pressure/hoperf,hp03.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: HopeRF HP03 digital pressure/temperature sensors
+
+maintainers:
+  - Marek Vasut <[email protected]>
+
+description: |
+  Digital pressure and temperature sensor with an I2C interface.
+
+properties:
+  compatible:
+    const: hoperf,hp03
+
+  reg:
+    maxItems: 1
+
+  xclr-gpios:
+    description:
+      The XCLR pin is a reset of the ADC in the chip, it must be pulled
+      HI before the conversion and readout of the value from the ADC
+      registers and pulled LO afterward.
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        pressure@77 {
+            compatible = "hoperf,hp03";
+            reg = <0x77>;
+            xclr-gpios = <&portc 0 0x0>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/pressure/hp03.txt deleted +0 -18
deleted file mode 100644
index 831dbee7a5c3..000000000000
@@ -1,17 +0,0 @@
-HopeRF HP03 digital pressure/temperature sensors
-
-Required properties:
-- compatible: must be "hoperf,hp03"
-- xclr-gpio: must be device tree identifier of the XCLR pin.
-             The XCLR pin is a reset of the ADC in the chip,
-             it must be pulled HI before the conversion and
-             readout of the value from the ADC registers and
-             pulled LO afterward.
-
-Example:
-
-hp03@77 {
-       compatible = "hoperf,hp03";
-       reg = <0x77>;
-       xclr-gpio = <&portc 0 0x0>;
-};
--

2.28.0

#13 lore raw

Re: [PATCH 08/29] dt-bindings:iio:pressure:hoperf,hp03 yaml conversion

Quoted 8 lines · On Mon, 12 Oct 2020 08:06:46 -0500 Rob Herring <[email protected]> wrote:
Quoted 5 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

One quirk in the txt file was that the xclr gpio was specified as gpio-xclr rather than gpios-xclr. I've fixed that in the

xclr-gpios?, not gpios?-xclr

I clearly have a very short memory when writing patch descriptions. Indeed, xclr-gpios is what this should say.

Quoted 89 lines
Quoted 89 lines

yaml version.

---
 .../bindings/iio/pressure/hoperf,hp03.yaml    | 47 +++++++++++++++++++
 .../devicetree/bindings/iio/pressure/hp03.txt | 17 -------
 2 files changed, 47 insertions(+), 17 deletions(-)
Documentation/devicetree/bindings/iio/pressure/hoperf,hp03.yaml new file +47 -0
new file mode 100644
index 000000000000..69a3759e23db
@@ -0,0 +1,47 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/pressure/hoperf,hp03.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: HopeRF HP03 digital pressure/temperature sensors
+
+maintainers:
+  - Marek Vasut <[email protected]>
+
+description: |
+  Digital pressure and temperature sensor with an I2C interface.
+
+properties:
+  compatible:
+    const: hoperf,hp03
+
+  reg:
+    maxItems: 1
+
+  xclr-gpios:
+    description:
+      The XCLR pin is a reset of the ADC in the chip, it must be pulled
+      HI before the conversion and readout of the value from the ADC
+      registers and pulled LO afterward.
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        pressure@77 {
+            compatible = "hoperf,hp03";
+            reg = <0x77>;
+            xclr-gpios = <&portc 0 0x0>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/pressure/hp03.txt deleted +0 -18
deleted file mode 100644
index 831dbee7a5c3..000000000000
@@ -1,17 +0,0 @@
-HopeRF HP03 digital pressure/temperature sensors
-
-Required properties:
-- compatible: must be "hoperf,hp03"
-- xclr-gpio: must be device tree identifier of the XCLR pin.
-             The XCLR pin is a reset of the ADC in the chip,
-             it must be pulled HI before the conversion and
-             readout of the value from the ADC registers and
-             pulled LO afterward.
-
-Example:
-
-hp03@77 {
-       compatible = "hoperf,hp03";
-       reg = <0x77>;
-       xclr-gpio = <&portc 0 0x0>;
-};
--

2.28.0

author maintainer
#14 lore raw

PATCH 9/29 dt-bindings:iio:proximity:semtech,sx9500 yaml conversion.

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Simple conversion. There hasn't been much activity around this driver for a long time and I don't think I have any up to date contact details for the original authors. As such, I've listed myself as the binding maintainer. More than happy to hand it off to someone more relevant though!

---
 .../iio/proximity/semtech,sx9500.yaml         | 50 +++++++++++++++++++
 .../bindings/iio/proximity/sx9500.txt         | 23 ---------
 2 files changed, 50 insertions(+), 23 deletions(-)
Documentation/devicetree/bindings/iio/proximity/semtech,sx9500.yaml new file +50 -0
new file mode 100644
index 000000000000..66dd01506859
@@ -0,0 +1,50 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/proximity/semtech,sx9500.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Semtech's SX9500 capacitive proximity button device
+
+maintainers:
+  - Jonathan Cameron <[email protected]>
+
+properties:
+  compatible:
+    const: semtech,sx9500
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+  reset-gpios:
+    description:
+      GPIO connected to the active low reset pin.
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+  - interrupts
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/interrupt-controller/irq.h>
+    #include <dt-bindings/gpio/gpio.h>
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        proximity@28 {
+            compatible = "semtech,sx9500";
+            reg = <0x28>;
+            interrupt-parent = <&gpio2>;
+            interrupts = <16 IRQ_TYPE_LEVEL_LOW>;
+            reset-gpios = <&gpio2 10 GPIO_ACTIVE_LOW>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/proximity/sx9500.txt deleted +0 -23
deleted file mode 100644
index c54455db3bec..000000000000
@@ -1,23 +0,0 @@
-Semtech's SX9500 capacitive proximity button device driver
-
-Required properties:
-	- compatible: must be "semtech,sx9500"
-	- reg: i2c address where to find the device
-	- interrupts : the sole interrupt generated by the device
-
-	Refer to interrupt-controller/interrupts.txt for generic
-	interrupt client node bindings.
-
-Optional properties:
-	- reset-gpios: Reference to the GPIO connected to the device's active
-	  low reset pin.
-
-Example:
-
-sx9500@28 {
-	compatible = "semtech,sx9500";
-	reg = <0x28>;
-	interrupt-parent = <&gpio2>;
-	interrupts = <16 IRQ_TYPE_LEVEL_LOW>;
-	reset-gpios = <&gpio2 10 GPIO_ACTIVE_LOW>;
-};
Signature · 1 line
2.28.0
author maintainer
#15 lore raw

PATCH 10/29 dt-bindings:iio:proximity:st,vl53l0x yaml conversion

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Straight forward conversion from txt to yaml.

---
 .../bindings/iio/proximity/st,vl53l0x.yaml    | 42 +++++++++++++++++++
 .../bindings/iio/proximity/vl53l0x.txt        | 18 --------
 2 files changed, 42 insertions(+), 18 deletions(-)
Documentation/devicetree/bindings/iio/proximity/st,vl53l0x.yaml new file +42 -0
new file mode 100644
index 000000000000..656460d9d8c8
@@ -0,0 +1,42 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/proximity/st,vl53l0x.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: ST VL53L0X ToF ranging sensor
+
+maintainers:
+  - Song Qiang <[email protected]>
+
+properties:
+  compatible:
+    const: st,vl53l0x
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/interrupt-controller/irq.h>
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        proximity@29 {
+            compatible = "st,vl53l0x";
+            reg = <0x29>;
+            interrupt-parent = <&gpio>;
+            interrupts = <23 IRQ_TYPE_EDGE_FALLING>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/proximity/vl53l0x.txt deleted +0 -18
deleted file mode 100644
index dfe00eb961cd..000000000000
@@ -1,18 +0,0 @@
-ST VL53L0X ToF ranging sensor
-
-Required properties:
-	- compatible: must be "st,vl53l0x"
-	- reg: i2c address where to find the device
-
-Optional properties:
-	- interrupts:	Interrupt for notifying that new measurement is ready.
-			If no interrupt is specified, polling is used.
-
-Example:
-
-vl53l0x@29 {
-	compatible = "st,vl53l0x";
-	reg = <0x29>;
-	interrupt-parent = <&gpio>;
-	interrupts = <23 IRQ_TYPE_EDGE_FALLING>;
-};
Signature · 1 line
2.28.0
author maintainer
#16 lore raw

PATCH 11/29 dt-bindings:iio:proximity:ams,as3935 yaml conversion

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

A straight forward conversion of this binding. I have added a maximum SPI frequency from the datasheet.

---
 .../bindings/iio/proximity/ams,as3935.yaml    | 71 +++++++++++++++++++
 .../bindings/iio/proximity/as3935.txt         | 34 ---------
 2 files changed, 71 insertions(+), 34 deletions(-)
Documentation/devicetree/bindings/iio/proximity/ams,as3935.yaml new file +71 -0
new file mode 100644
index 000000000000..7fcba5d6d508
@@ -0,0 +1,71 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/proximity/ams,as3935.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Austrian Microsystems AS3935 Franklin lightning sensor
+
+maintainers:
+  - Matt Ranostay <[email protected]>
+
+description:
+  This lightening distance sensor uses an I2C or SPI interface. The
+  binding currently only covers the SPI option.
+
+properties:
+  compatible:
+    const: ams,as3935
+
+  reg:
+    maxItems: 1
+
+  spi-max-frequency:
+    maximum: 2000000
+
+  spi-cpha: true
+
+  interrupts:
+    maxItems: 1
+
+  ams,tuning-capacitor-pf:
+    $ref: /schemas/types.yaml#/definitions/uint32
+    description:
+      Calibration tuning capacitor stepping value. This will require using
+      the calibration data from the manufacturer.
+    minimum: 0
+    maximum: 120
+
+  ams,nflwdth:
+    $ref: /schemas/types.yaml#/definitions/uint32
+    description:
+      Set the noise and watchdog threshold register on startup. This will
+      need to set according to the noise from the MCU board, and possibly
+      the local environment. Refer to the datasheet for the threshold settings.
+
+required:
+  - compatible
+  - reg
+  - spi-cpha
+  - interrupts
+
+additionalProperties: false
+
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+    lightning@0 {
+            compatible = "ams,as3935";
+            reg = <0>;
+            spi-max-frequency = <400000>;
+            spi-cpha;
+            interrupt-parent = <&gpio1>;
+            interrupts = <16 1>;
+            ams,tuning-capacitor-pf = <80>;
+            ams,nflwdth = <0x44>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/proximity/as3935.txt deleted +0 -34
deleted file mode 100644
index 849115585d55..000000000000
@@ -1,34 +0,0 @@
-Austrian Microsystems AS3935 Franklin lightning sensor device driver
-
-Required properties:
-	- compatible: must be "ams,as3935"
-	- reg: SPI chip select number for the device
-	- spi-max-frequency: specifies maximum SPI clock frequency
-	- spi-cpha: SPI Mode 1. Refer to spi/spi-bus.txt for generic SPI
-	slave node bindings.
-	- interrupts : the sole interrupt generated by the device
-
-	Refer to interrupt-controller/interrupts.txt for generic
-	interrupt client node bindings.
-
-Optional properties:
-	- ams,tuning-capacitor-pf: Calibration tuning capacitor stepping
-	  value 0 - 120pF. This will require using the calibration data from
-	  the manufacturer.
-	- ams,nflwdth: Set the noise and watchdog threshold register on
-	  startup. This will need to set according to the noise from the
-	  MCU board, and possibly the local environment. Refer to the
-	  datasheet for the threshold settings.
-
-Example:
-
-as3935@0 {
-	compatible = "ams,as3935";
-	reg = <0>;
-	spi-max-frequency = <400000>;
-	spi-cpha;
-	interrupt-parent = <&gpio1>;
-	interrupts = <16 1>;
-	ams,tuning-capacitor-pf = <80>;
-	ams,nflwdth = <0x44>;
-};
Signature · 1 line
2.28.0
Acked-by on v1 11/29
#17 lore raw

Re: [PATCH 11/29] dt-bindings:iio:proximity:ams,as3935 yaml conversion

Quoted 8 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

A straight forward conversion of this binding. I have added a maximum SPI frequency from the datasheet.

Quoted 125 lines
---
 .../bindings/iio/proximity/ams,as3935.yaml    | 71 +++++++++++++++++++
 .../bindings/iio/proximity/as3935.txt         | 34 ---------
 2 files changed, 71 insertions(+), 34 deletions(-)
Documentation/devicetree/bindings/iio/proximity/ams,as3935.yaml new file +71 -0
new file mode 100644
index 000000000000..7fcba5d6d508
@@ -0,0 +1,71 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/proximity/ams,as3935.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Austrian Microsystems AS3935 Franklin lightning sensor
+
+maintainers:
+  - Matt Ranostay <[email protected]>
+
+description:
+  This lightening distance sensor uses an I2C or SPI interface. The
+  binding currently only covers the SPI option.
+
+properties:
+  compatible:
+    const: ams,as3935
+
+  reg:
+    maxItems: 1
+
+  spi-max-frequency:
+    maximum: 2000000
+
+  spi-cpha: true
+
+  interrupts:
+    maxItems: 1
+
+  ams,tuning-capacitor-pf:
+    $ref: /schemas/types.yaml#/definitions/uint32
+    description:
+      Calibration tuning capacitor stepping value. This will require using
+      the calibration data from the manufacturer.
+    minimum: 0
+    maximum: 120
+
+  ams,nflwdth:
+    $ref: /schemas/types.yaml#/definitions/uint32
+    description:
+      Set the noise and watchdog threshold register on startup. This will
+      need to set according to the noise from the MCU board, and possibly
+      the local environment. Refer to the datasheet for the threshold settings.
+
+required:
+  - compatible
+  - reg
+  - spi-cpha
+  - interrupts
+
+additionalProperties: false
+
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+    lightning@0 {
+            compatible = "ams,as3935";
+            reg = <0>;
+            spi-max-frequency = <400000>;
+            spi-cpha;
+            interrupt-parent = <&gpio1>;
+            interrupts = <16 1>;
+            ams,tuning-capacitor-pf = <80>;
+            ams,nflwdth = <0x44>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/proximity/as3935.txt deleted +0 -35
deleted file mode 100644
index 849115585d55..000000000000
@@ -1,34 +0,0 @@
-Austrian Microsystems AS3935 Franklin lightning sensor device driver
-
-Required properties:
-       - compatible: must be "ams,as3935"
-       - reg: SPI chip select number for the device
-       - spi-max-frequency: specifies maximum SPI clock frequency
-       - spi-cpha: SPI Mode 1. Refer to spi/spi-bus.txt for generic SPI
-       slave node bindings.
-       - interrupts : the sole interrupt generated by the device
-
-       Refer to interrupt-controller/interrupts.txt for generic
-       interrupt client node bindings.
-
-Optional properties:
-       - ams,tuning-capacitor-pf: Calibration tuning capacitor stepping
-         value 0 - 120pF. This will require using the calibration data from
-         the manufacturer.
-       - ams,nflwdth: Set the noise and watchdog threshold register on
-         startup. This will need to set according to the noise from the
-         MCU board, and possibly the local environment. Refer to the
-         datasheet for the threshold settings.
-
-Example:
-
-as3935@0 {
-       compatible = "ams,as3935";
-       reg = <0>;
-       spi-max-frequency = <400000>;
-       spi-cpha;
-       interrupt-parent = <&gpio1>;
-       interrupts = <16 1>;
-       ams,tuning-capacitor-pf = <80>;
-       ams,nflwdth = <0x44>;
-};
--

2.28.0

author maintainer
#18 lore raw

PATCH 12/29 dt-bindings:iio:dac:ti,dac5571 yaml conversion.

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

A few tweaks in this conversion.
* The example didn't have the I2C address of 4C in the node name so fixed that.
* The reference voltage in the txt file is an optional binding, but the driver is making use of it to provide the scaling of the output channels. As such I have made it required going forwards.

---
 .../bindings/iio/dac/ti,dac5571.txt           | 24 ---------
 .../bindings/iio/dac/ti,dac5571.yaml          | 52 +++++++++++++++++++
 2 files changed, 52 insertions(+), 24 deletions(-)
Documentation/devicetree/bindings/iio/dac/ti,dac5571.txt deleted +0 -24
deleted file mode 100644
index 03af6b9a4d07..000000000000
@@ -1,24 +0,0 @@
-* Texas Instruments DAC5571 Family
-
-Required properties:
- - compatible: Should contain
-    "ti,dac5571"
-    "ti,dac6571"
-    "ti,dac7571"
-    "ti,dac5574"
-    "ti,dac6574"
-    "ti,dac7574"
-    "ti,dac5573"
-    "ti,dac6573"
-    "ti,dac7573"
- - reg: Should contain the DAC I2C address
-
-Optional properties:
- - vref-supply: The regulator supply for DAC reference voltage
-
-Example:
-dac@0 {
-	compatible = "ti,dac5571";
-	reg = <0x4C>;
-	vref-supply = <&vdd_supply>;
-};
Documentation/devicetree/bindings/iio/dac/ti,dac5571.yaml new file +52 -0

52 lines not on this page · raw message

Signature · 1 line
2.28.0
#19 lore raw

Re: [PATCH 12/29] dt-bindings:iio:dac:ti,dac5571 yaml conversion.

Quoted 9 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

A few tweaks in this conversion.
* The example didn't have the I2C address of 4C in the node name so fixed that.
* The reference voltage in the txt file is an optional binding, but the driver is making use of it to provide the scaling of the output channels. As such I have made it required going forwards.

Quoted 3 lines

Looks good :)

/Sean

author maintainer
#20 lore raw

Re: [PATCH 12/29] dt-bindings:iio:dac:ti,dac5571 yaml conversion.

Quoted 10 lines · On Sun, 11 Oct 2020 19:47:19 +0200 Sean Nyekjaer <[email protected]> wrote:
Quoted 9 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

A few tweaks in this conversion.
* The example didn't have the I2C address of 4C in the node name so fixed that.
* The reference voltage in the txt file is an optional binding, but the driver is making use of it to provide the scaling of the output channels. As such I have made it required going forwards.

Quoted 4 lines
Quoted 3 lines

Looks good :)

Hi Sean, Good to know, but if you are happy to give a formal Acked-by, or Reviewed-by always appreciated!

Thanks,

Jonathan

Quoted 2 lines

/Sean

Acked-by
#21 lore raw

Re: [PATCH 12/29] dt-bindings:iio:dac:ti,dac5571 yaml conversion.

Quoted 13 lines · Jonathan Cameron
Quoted 10 lines · On Sun, 11 Oct 2020 19:47:19 +0200 Sean Nyekjaer <[email protected]> wrote:
Quoted 9 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

A few tweaks in this conversion.
* The example didn't have the I2C address of 4C in the node name so fixed that.
* The reference voltage in the txt file is an optional binding, but the driver is making use of it to provide the scaling of the output channels. As such I have made it required going forwards.

Quoted 6 lines
Quoted 4 lines
Quoted 3 lines

Looks good :)

Hi Sean, Good to know, but if you are happy to give a formal Acked-by, or Reviewed-by always appreciated!

Sure :)
I just thought it would be weird then I already had the Cc...

/Sean

author maintainer
#22 lore raw

PATCH 13/29 dt-bindings:iio:dac:ti,dac7311 yaml conversion

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Very simple conversion of this binding from txt to yaml.

Cc Charles-Antoine Couret <[email protected]>
---
 .../bindings/iio/dac/ti,dac7311.txt           | 23 ---------
 .../bindings/iio/dac/ti,dac7311.yaml          | 49 +++++++++++++++++++
 2 files changed, 49 insertions(+), 23 deletions(-)
Documentation/devicetree/bindings/iio/dac/ti,dac7311.txt deleted +0 -23
deleted file mode 100644
index e5a507db5e01..000000000000
@@ -1,23 +0,0 @@
-TI DAC7311 device tree bindings
-
-Required properties:
-- compatible: must be set to:
-	* "ti,dac7311"
-	* "ti,dac6311"
-	* "ti,dac5311"
-- reg: spi chip select number for the device
-- vref-supply: The regulator supply for ADC reference voltage
-
-Optional properties:
-- spi-max-frequency: Max SPI frequency to use
-
-Example:
-
-	spi_master {
-		dac@0 {
-			compatible = "ti,dac7311";
-			reg = <0>; /* CS0 */
-			spi-max-frequency = <1000000>;
-			vref-supply = <&vdd_supply>;
-		};
-	};
Documentation/devicetree/bindings/iio/dac/ti,dac7311.yaml new file +49 -0

49 lines not on this page · raw message

Signature · 1 line
2.28.0
author maintainer
#23 lore raw

PATCH 14/29 dt-bindings:iio:dac:ti,dac7512 yaml conversion

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

This one is a bit interesting because the binding was moved from misc a while back, but the linux support for this device is provided via the ad5446 DAC driver which doesn't currently have a binding.

For now, lets just convert this file over, but we may want to think about consolidating this with proper documentation of the bindings for the other parts supported by the ad5446 driver.

As Daniel Mack does not seem to have been active since 2015, I've put myself as maintainer of this binding for now.

---
 .../bindings/iio/dac/ti,dac7512.txt           | 20 ---------
 .../bindings/iio/dac/ti,dac7512.yaml          | 42 +++++++++++++++++++
 2 files changed, 42 insertions(+), 20 deletions(-)
Documentation/devicetree/bindings/iio/dac/ti,dac7512.txt deleted +0 -20
deleted file mode 100644
index 1db45939dac9..000000000000
@@ -1,20 +0,0 @@
-TI DAC7512 DEVICETREE BINDINGS
-
-Required properties:
-
-	- "compatible"		Must be set to "ti,dac7512"
-
-Property rules described in Documentation/devicetree/bindings/spi/spi-bus.txt
-apply. In particular, "reg" and "spi-max-frequency" properties must be given.
-
-
-Example:
-
-	spi_master {
-		dac7512: dac7512@0 {
-			compatible = "ti,dac7512";
-			reg = <0>; /* CS0 */
-			spi-max-frequency = <1000000>;
-		};
-	};
-
Documentation/devicetree/bindings/iio/dac/ti,dac7512.yaml new file +42 -0

42 lines not on this page · raw message

Signature · 1 line
2.28.0
author maintainer
#24 lore raw

PATCH 15/29 dt-bindings:iio:dac:ti,dac7612 yaml conversion

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Simple conversion from txt to yaml. No significant adjustments.

Cc Ricardo Ribalda Delgado <[email protected]>
---
 .../bindings/iio/dac/ti,dac7612.txt           | 28 ----------
 .../bindings/iio/dac/ti,dac7612.yaml          | 53 +++++++++++++++++++
 2 files changed, 53 insertions(+), 28 deletions(-)
Documentation/devicetree/bindings/iio/dac/ti,dac7612.txt deleted +0 -28
deleted file mode 100644
index 17af395b99d9..000000000000
@@ -1,28 +0,0 @@
-* Texas Instruments Dual, 12-Bit Serial Input Digital-to-Analog Converter
-
-The DAC7612 is a dual, 12-bit digital-to-analog converter (DAC) with guaranteed
-12-bit monotonicity performance over the industrial temperature range.
-Is is programmable through an SPI interface.
-
-The internal DACs are loaded when the LOADDACS pin is pulled down.
-
-https://www.ti.com/lit/ds/sbas106/sbas106.pdf
-
-Required Properties:
-- compatible: Should be one of:
-		"ti,dac7612"
-		"ti,dac7612u"
-		"ti,dac7612ub"
-- reg: Definition as per Documentation/devicetree/bindings/spi/spi-bus.txt
-
-Optional Properties:
-- ti,loaddacs-gpios: GPIO descriptor for the LOADDACS pin.
-- spi-*: Definition as per Documentation/devicetree/bindings/spi/spi-bus.txt
-
-Example:
-
-	dac@1 {
-		compatible = "ti,dac7612";
-		reg = <0x1>;
-		ti,loaddacs-gpios = <&msmgpio 25 GPIO_ACTIVE_LOW>;
-	};
Documentation/devicetree/bindings/iio/dac/ti,dac7612.yaml new file +53 -0

53 lines not on this page · raw message

Signature · 1 line
2.28.0
#25 lore raw

Re: [PATCH 15/29] dt-bindings:iio:dac:ti,dac7612 yaml conversion

Quoted 108 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Simple conversion from txt to yaml. No significant adjustments.

Cc Ricardo Ribalda Delgado <[email protected]>
---
 .../bindings/iio/dac/ti,dac7612.txt           | 28 ----------
 .../bindings/iio/dac/ti,dac7612.yaml          | 53 +++++++++++++++++++
 2 files changed, 53 insertions(+), 28 deletions(-)
Documentation/devicetree/bindings/iio/dac/ti,dac7612.txt deleted +0 -28
deleted file mode 100644
index 17af395b99d9..000000000000
@@ -1,28 +0,0 @@
-* Texas Instruments Dual, 12-Bit Serial Input Digital-to-Analog Converter
-
-The DAC7612 is a dual, 12-bit digital-to-analog converter (DAC) with guaranteed
-12-bit monotonicity performance over the industrial temperature range.
-Is is programmable through an SPI interface.
-
-The internal DACs are loaded when the LOADDACS pin is pulled down.
-
-https://www.ti.com/lit/ds/sbas106/sbas106.pdf
-
-Required Properties:
-- compatible: Should be one of:
-               "ti,dac7612"
-               "ti,dac7612u"
-               "ti,dac7612ub"
-- reg: Definition as per Documentation/devicetree/bindings/spi/spi-bus.txt
-
-Optional Properties:
-- ti,loaddacs-gpios: GPIO descriptor for the LOADDACS pin.
-- spi-*: Definition as per Documentation/devicetree/bindings/spi/spi-bus.txt
-
-Example:
-
-       dac@1 {
-               compatible = "ti,dac7612";
-               reg = <0x1>;
-               ti,loaddacs-gpios = <&msmgpio 25 GPIO_ACTIVE_LOW>;
-       };
Documentation/devicetree/bindings/iio/dac/ti,dac7612.yaml new file +53 -1
new file mode 100644
index 000000000000..d172b142f6ed
@@ -0,0 +1,53 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/dac/ti,dac7612.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments DAC7612 family of DACs
+
+description:
+  The DAC7612 is a dual, 12-bit digital-to-analog converter (DAC) with
+  guaranteed 12-bit monotonicity performance over the industrial temperature
+  range. Is is programmable through an SPI interface.
+
+maintainers:
+  - Ricardo Ribalda Delgado <[email protected]>
+
+properties:
+  compatible:
+    enum:
+      - ti,dac7612
+      - ti,dac7612u
+      - ti,dac7612ub
+
+  reg:
+    maxItems: 1
+
+  ti,loaddacs-gpios:
+    description:
+      DACs are loaded when the pin connected to this GPIO is pulled low.
+    maxItems: 1
+
+  spi-max-frequency: true
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/gpio/gpio.h>
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        dac@1 {
+            compatible = "ti,dac7612";
+            reg = <0x1>;
+            ti,loaddacs-gpios = <&msmgpio 25 GPIO_ACTIVE_LOW>;
+        };
+    };
+...
--

2.28.0

Signature · 1 line
Ricardo Ribalda
author maintainer
#26 lore raw

Re: [PATCH 15/29] dt-bindings:iio:dac:ti,dac7612 yaml conversion

Quoted 1 line · On Thu, 15 Oct 2020 10:49:08 +0200 Ricardo Ribalda Delgado…

Hi Ricardo,

I've converted that to an Acked-by. This one doesn't convey any DCO related info, so Signed-off-by isn't appropriate.

Thanks,

Jonathan

Quoted 112 lines · Jonathan Cameron
Quoted 108 lines

From: Jonathan Cameron <[email protected]>

Simple conversion from txt to yaml. No significant adjustments.

Cc Ricardo Ribalda Delgado <[email protected]>
---
 .../bindings/iio/dac/ti,dac7612.txt           | 28 ----------
 .../bindings/iio/dac/ti,dac7612.yaml          | 53 +++++++++++++++++++
 2 files changed, 53 insertions(+), 28 deletions(-)
Documentation/devicetree/bindings/iio/dac/ti,dac7612.txt deleted +0 -28
deleted file mode 100644
index 17af395b99d9..000000000000
@@ -1,28 +0,0 @@
-* Texas Instruments Dual, 12-Bit Serial Input Digital-to-Analog Converter
-
-The DAC7612 is a dual, 12-bit digital-to-analog converter (DAC) with guaranteed
-12-bit monotonicity performance over the industrial temperature range.
-Is is programmable through an SPI interface.
-
-The internal DACs are loaded when the LOADDACS pin is pulled down.
-
-https://www.ti.com/lit/ds/sbas106/sbas106.pdf
-
-Required Properties:
-- compatible: Should be one of:
-               "ti,dac7612"
-               "ti,dac7612u"
-               "ti,dac7612ub"
-- reg: Definition as per Documentation/devicetree/bindings/spi/spi-bus.txt
-
-Optional Properties:
-- ti,loaddacs-gpios: GPIO descriptor for the LOADDACS pin.
-- spi-*: Definition as per Documentation/devicetree/bindings/spi/spi-bus.txt
-
-Example:
-
-       dac@1 {
-               compatible = "ti,dac7612";
-               reg = <0x1>;
-               ti,loaddacs-gpios = <&msmgpio 25 GPIO_ACTIVE_LOW>;
-       };
Documentation/devicetree/bindings/iio/dac/ti,dac7612.yaml new file +53 -1
new file mode 100644
index 000000000000..d172b142f6ed
@@ -0,0 +1,53 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/dac/ti,dac7612.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments DAC7612 family of DACs
+
+description:
+  The DAC7612 is a dual, 12-bit digital-to-analog converter (DAC) with
+  guaranteed 12-bit monotonicity performance over the industrial temperature
+  range. Is is programmable through an SPI interface.
+
+maintainers:
+  - Ricardo Ribalda Delgado <[email protected]>
+
+properties:
+  compatible:
+    enum:
+      - ti,dac7612
+      - ti,dac7612u
+      - ti,dac7612ub
+
+  reg:
+    maxItems: 1
+
+  ti,loaddacs-gpios:
+    description:
+      DACs are loaded when the pin connected to this GPIO is pulled low.
+    maxItems: 1
+
+  spi-max-frequency: true
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/gpio/gpio.h>
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        dac@1 {
+            compatible = "ti,dac7612";
+            reg = <0x1>;
+            ti,loaddacs-gpios = <&msmgpio 25 GPIO_ACTIVE_LOW>;
+        };
+    };
+...
--

2.28.0

author maintainer
#27 lore raw

PATCH 16/29 dt-bindings:iio:dac:ti,dac082s085 yaml conversion

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Fairly simple conversion, but it could be tighter than currently specified.

Is there a clean way to specify a negative dependency? For now I have just put in the description field that we must have spi-cpol or spi-cpha but not both.

---
 .../bindings/iio/dac/ti,dac082s085.yaml       | 58 +++++++++++++++++++
 .../bindings/iio/dac/ti-dac082s085.txt        | 34 -----------
 2 files changed, 58 insertions(+), 34 deletions(-)
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +58 -0
new file mode 100644
index 000000000000..255481f2fee9
@@ -0,0 +1,58 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/dac/ti,dac082s085.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments DAC082s085 and similar DACs
+
+description:
+  A familly of Texas Instruments 8/10/12-bit 2/4-channel DACs
+
+maintainers:
+  - Lukas Wunner <[email protected]>
+
+properties:
+  compatible:
+    enum:
+      - ti,dac082s085
+      - ti,dac102s085
+      - ti,dac122s085
+      - ti,dac084s085
+      - ti,dac104s085
+      - ti,dac124s085
+
+  reg:
+    maxItems: 1
+
+  spi-cpha: true
+  spi-cpol:
+    description:
+      Should be either spi-cpha, or spi-cpol but not both.
+
+  vref-supply: true
+
+  spi-max-frequency: true
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        dac@0 {
+            compatible = "ti,dac082s085";
+            reg = <0>;
+            spi-max-frequency = <40000000>;
+            spi-cpol;
+            spi-cpha;
+            vref-supply = <&vref_2v5_reg>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/dac/ti-dac082s085.txt deleted +0 -34
deleted file mode 100644
index 9cb0e10df704..000000000000
@@ -1,34 +0,0 @@
-Texas Instruments 8/10/12-bit 2/4-channel DAC driver
-
-Required properties:
- - compatible:		Must be one of:
-			"ti,dac082s085"
-			"ti,dac102s085"
-			"ti,dac122s085"
-			"ti,dac084s085"
-			"ti,dac104s085"
-			"ti,dac124s085"
- - reg: 		Chip select number.
- - spi-cpha, spi-cpol:	SPI mode (0,1) or (1,0) must be used, so specify
-			either spi-cpha or spi-cpol (but not both).
- - vref-supply: 	Phandle to the external reference voltage supply.
-
-For other required and optional properties of SPI slave nodes please refer to
-../../spi/spi-bus.txt.
-
-Example:
-	vref_2v5_reg: regulator-vref {
-		compatible = "regulator-fixed";
-		regulator-name = "2v5";
-		regulator-min-microvolt = <2500000>;
-		regulator-max-microvolt = <2500000>;
-		regulator-always-on;
-	};
-
-	dac@0 {
-		compatible = "ti,dac082s085";
-		reg = <0>;
-		spi-max-frequency = <40000000>;
-		spi-cpol;
-		vref-supply = <&vref_2v5_reg>;
-	};
Signature · 1 line
2.28.0
#28 lore raw

Re: [PATCH 16/29] dt-bindings:iio:dac:ti,dac082s085 yaml conversion

Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml line 10

Quoted 13 lines · Jonathan Cameron
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +10 -0
@@ -0,0 +1,58 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/dac/ti,dac082s085.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments DAC082s085 and similar DACs
+
+description:
+  A familly of Texas Instruments 8/10/12-bit 2/4-channel DACs
           ^^

s/familly/family

Quoted 6 lines
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +6 -0
+  spi-cpha: true
+  spi-cpol:
+    description:
+      Should be either spi-cpha, or spi-cpol but not both.
+
+  vref-supply: true

[...]

Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml line 39

Quoted 3 lines
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +3 -0
+required:
+  - compatible
+  - reg

"vref-supply" and ("spi-cpha" xor "spi-cpol") are also requird per the existing txt file.

Quoted 5 lines
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +5 -0
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;

Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml line 57

Quoted 10 lines
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +10 -0
+
+        dac@0 {
+            compatible = "ti,dac082s085";
+            reg = <0>;
+            spi-max-frequency = <40000000>;
+            spi-cpol;
+            spi-cpha;
+            vref-supply = <&vref_2v5_reg>;
+        };
+    };

Hm, why wasn't the "vref_2v5_reg" node carried over from the txt file?

Thanks,

Lukas

author maintainer
#29 lore raw

Re: [PATCH 16/29] dt-bindings:iio:dac:ti,dac082s085 yaml conversion

Quoted 24 lines · On Wed, 28 Oct 2020 21:31:40 +0100 Lukas Wunner <[email protected]> wrote:

Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml line 10

Quoted 13 lines · Jonathan Cameron
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +10 -0
@@ -0,0 +1,58 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/dac/ti,dac082s085.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments DAC082s085 and similar DACs
+
+description:
+  A familly of Texas Instruments 8/10/12-bit 2/4-channel DACs  
           ^^

s/familly/family

Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml line 33

Quoted 6 lines
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +6 -0
+  spi-cpha: true
+  spi-cpol:
+    description:
+      Should be either spi-cpha, or spi-cpol but not both.
+
+  vref-supply: true  
Quoted 7 lines

[...]

Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml line 39

Quoted 3 lines
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +3 -0
+required:
+  - compatible
+  - reg  

"vref-supply" and ("spi-cpha" xor "spi-cpol") are also requird per the existing txt file.

I have no idea how to specify the spi-cpha xor spi-cpol unfortunately. Have a question out to Rob on that one.

vref-supply was a stupid mistake from me. Will fix.

Quoted 11 lines
Quoted 11 lines
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +9 -0
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        dac@0 {
+            compatible = "ti,dac082s085";
+            reg = <0>;
Quoted 8 lines

Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml line 57

Quoted 6 lines
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +6 -0
+            spi-max-frequency = <40000000>;
+            spi-cpol;
+            spi-cpha;
+            vref-supply = <&vref_2v5_reg>;
+        };
+    };  

Hm, why wasn't the "vref_2v5_reg" node carried over from the txt file?

Showing how to supply a regulator isn't generally necessary in an example. I don't mind having it there though so can keep it
(as the fixed regulator binding has been converted to yaml)

Quoted 4 lines

Thanks,

Lukas

#30 lore raw

Re: [PATCH 16/29] dt-bindings:iio:dac:ti,dac082s085 yaml conversion

Quoted 20 lines · Jonathan Cameron
Quoted 10 lines · On Wed, 28 Oct 2020 21:31:40 +0100 Lukas Wunner <[email protected]> wrote:
Quoted 9 lines · Jonathan Cameron
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +9 -0
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        dac@0 {
+            compatible = "ti,dac082s085";
+            reg = <0>;
Quoted 8 lines

Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml line 57

Quoted 6 lines
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +6 -0
+            spi-max-frequency = <40000000>;
+            spi-cpol;
+            spi-cpha;
+            vref-supply = <&vref_2v5_reg>;
+        };
+    };  

Hm, why wasn't the "vref_2v5_reg" node carried over from the txt file?

Quoted 3 lines

Showing how to supply a regulator isn't generally necessary in an example. I don't mind having it there though so can keep it
(as the fixed regulator binding has been converted to yaml)

The "vref_2v5_reg" node is referenced by the "dac@0" node, so I included it in the example for completeness. I'd appreciate if it could be carried over to the YAML file, unless its inclusion is a bad practice.

Thanks,

Lukas

author maintainer
#31 lore raw

Re: [PATCH 16/29] dt-bindings:iio:dac:ti,dac082s085 yaml conversion

Quoted 21 lines · On Thu, 29 Oct 2020 20:10:14 +0100 Lukas Wunner <[email protected]> wrote:
Quoted 20 lines · Jonathan Cameron
Quoted 18 lines · On Wed, 28 Oct 2020 21:31:40 +0100 Lukas Wunner <[email protected]> wrote:
Quoted 5 lines · Jonathan Cameron
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +5 -0
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;

Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml line 57

Quoted 10 lines
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +10 -0
+
+        dac@0 {
+            compatible = "ti,dac082s085";
+            reg = <0>;
+            spi-max-frequency = <40000000>;
+            spi-cpol;
+            spi-cpha;
+            vref-supply = <&vref_2v5_reg>;
+        };
+    };    

Hm, why wasn't the "vref_2v5_reg" node carried over from the txt file?

Quoted 7 lines
Quoted 3 lines

Showing how to supply a regulator isn't generally necessary in an example. I don't mind having it there though so can keep it
(as the fixed regulator binding has been converted to yaml)

The "vref_2v5_reg" node is referenced by the "dac@0" node, so I included it in the example for completeness. I'd appreciate if it could be carried over to the YAML file, unless its inclusion is a bad practice.

Sure. Will do so. Many bindings don't do it, but nor problem with being more specific.

If we followed the logic of including referenced nodes, some bindings would end up including nearly a whole board dts. That's not the case here though so no problem.

Jonathan

Quoted 4 lines

Thanks,

Lukas

author maintainer
#32 lore raw

Re: [PATCH 16/29] dt-bindings:iio:dac:ti,dac082s085 yaml conversion

In reply to Jonathan Cameron
Quoted 32 lines · On Thu, 29 Oct 2020 15:50:25 +0000 Jonathan Cameron <[email protected]> wrote:
Quoted 29 lines · On Wed, 28 Oct 2020 21:31:40 +0100 Lukas Wunner <[email protected]> wrote:

Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml line 10

Quoted 13 lines · Jonathan Cameron
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +10 -0
@@ -0,0 +1,58 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/dac/ti,dac082s085.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments DAC082s085 and similar DACs
+
+description:
+  A familly of Texas Instruments 8/10/12-bit 2/4-channel DACs    
           ^^

s/familly/family

Quoted 6 lines
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +6 -0
+  spi-cpha: true
+  spi-cpol:
+    description:
+      Should be either spi-cpha, or spi-cpol but not both.
+
+  vref-supply: true    

[...]

Quoted 3 lines
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +3 -0
+required:
+  - compatible
+  - reg    
Quoted 5 lines
Quoted 2 lines

"vref-supply" and ("spi-cpha" xor "spi-cpol") are also requird per the existing txt file.

I have no idea how to specify the spi-cpha xor spi-cpol unfortunately. Have a question out to Rob on that one.

I tracked down an xor example in another yaml repo that seems to work (it's convoluted to put it lightly!) so I'll put that in the next version but will drop Rob's reviewed-by on the basis it's a substantial change.

Jonathan

Quoted 32 lines

vref-supply was a stupid mistake from me. Will fix.

Quoted 11 lines
Quoted 11 lines
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +9 -0
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        dac@0 {
+            compatible = "ti,dac082s085";
+            reg = <0>;
Quoted 8 lines

Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml line 57

Quoted 6 lines
Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml new file +6 -0
+            spi-max-frequency = <40000000>;
+            spi-cpol;
+            spi-cpha;
+            vref-supply = <&vref_2v5_reg>;
+        };
+    };    

Hm, why wasn't the "vref_2v5_reg" node carried over from the txt file?

Showing how to supply a regulator isn't generally necessary in an example. I don't mind having it there though so can keep it
(as the fixed regulator binding has been converted to yaml)

Quoted 4 lines

Thanks,

Lukas

author maintainer
#33 lore raw

PATCH 17/29 dt-bindings:iio:dac:adi,ad7303 yaml conversion

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Converted to maintain the requirement for Vdd-supply as per original file. It is possible we could relax this requirement to make it at least one of Vdd-supply and REF-supply. We need to establish the scaling of the output channel and if REF-supply is provided that is used instead of Vdd-supply, hence I cannot see why a dummy regulator cannot be used for Vdd-supply if this happens.

For now, let us keep it simple.

Cc Lars-Peter Clausen <[email protected]>
---
 .../devicetree/bindings/iio/dac/ad7303.txt    | 23 ---------
 .../bindings/iio/dac/adi,ad7303.yaml          | 51 +++++++++++++++++++
 2 files changed, 51 insertions(+), 23 deletions(-)
Documentation/devicetree/bindings/iio/dac/ad7303.txt deleted +0 -23
deleted file mode 100644
index 914610f0556e..000000000000
@@ -1,23 +0,0 @@
-Analog Devices AD7303 DAC device driver
-
-Required properties:
-	- compatible: Must be "adi,ad7303"
-	- reg: SPI chip select number for the device
-	- spi-max-frequency: Max SPI frequency to use (< 30000000)
-	- Vdd-supply: Phandle to the Vdd power supply
-
-Optional properties:
-	- REF-supply: Phandle to the external reference voltage supply. This should
-	  only be set if there is an external reference voltage connected to the REF
-	  pin. If the property is not set Vdd/2 is used as the reference voltage.
-
-Example:
-
-		ad7303@4 {
-			compatible = "adi,ad7303";
-			reg = <4>;
-			spi-max-frequency = <10000000>;
-			Vdd-supply = <&vdd_supply>;
-			adi,use-external-reference;
-			REF-supply = <&vref_supply>;
-		};
Documentation/devicetree/bindings/iio/dac/adi,ad7303.yaml new file +51 -0

51 lines not on this page · raw message

Signature · 1 line
2.28.0
#34 lore raw

Re: [PATCH 17/29] dt-bindings:iio:dac:adi,ad7303 yaml conversion

Quoted 90 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Converted to maintain the requirement for Vdd-supply as per original file. It is possible we could relax this requirement to make it at least one of Vdd-supply and REF-supply. We need to establish the scaling of the output channel and if REF-supply is provided that is used instead of Vdd-supply, hence I cannot see why a dummy regulator cannot be used for Vdd-supply if this happens.

For now, let us keep it simple.

Cc Lars-Peter Clausen <[email protected]>
---
  .../devicetree/bindings/iio/dac/ad7303.txt    | 23 ---------
  .../bindings/iio/dac/adi,ad7303.yaml          | 51 +++++++++++++++++++
  2 files changed, 51 insertions(+), 23 deletions(-)
Documentation/devicetree/bindings/iio/dac/ad7303.txt deleted +0 -23
deleted file mode 100644
index 914610f0556e..000000000000
@@ -1,23 +0,0 @@
-Analog Devices AD7303 DAC device driver
-
-Required properties:
-	- compatible: Must be "adi,ad7303"
-	- reg: SPI chip select number for the device
-	- spi-max-frequency: Max SPI frequency to use (< 30000000)
-	- Vdd-supply: Phandle to the Vdd power supply
-
-Optional properties:
-	- REF-supply: Phandle to the external reference voltage supply. This should
-	  only be set if there is an external reference voltage connected to the REF
-	  pin. If the property is not set Vdd/2 is used as the reference voltage.
-
-Example:
-
-		ad7303@4 {
-			compatible = "adi,ad7303";
-			reg = <4>;
-			spi-max-frequency = <10000000>;
-			Vdd-supply = <&vdd_supply>;
-			adi,use-external-reference;
-			REF-supply = <&vref_supply>;
-		};
Documentation/devicetree/bindings/iio/dac/adi,ad7303.yaml new file +37 -0
new file mode 100644
index 000000000000..f76c31bf6ee3
@@ -0,0 +1,51 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/dac/adi,ad7303.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Analog Devices AD7303 DAC
+
+maintainers:
+  - Lars-Peter Clausen <[email protected]>
+
+properties:
+  compatible:
+    const: adi,ad7303
+
+  reg:
+    maxItems: 1
+
+  Vdd-supply:
+    description:
+      Used to calculate output channel scalling if REF-supply not specified.
+  REF-supply:
+    description:
+      If not provided, Vdd/2 is used as the reference voltage.
+
+  spi-max-frequency:
+    maximum: 30000000
+
+required:
+  - compatible
+  - reg
+  - Vdd-supply
+
+additionalProperties: false
+
+examples:
+  - |

Documentation/devicetree/bindings/iio/dac/adi,ad7303.yaml line 47

Quoted 10 lines
Documentation/devicetree/bindings/iio/dac/adi,ad7303.yaml new file +10 -0
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        dac@4 {
+            compatible = "adi,ad7303";
+            reg = <4>;
+            spi-max-frequency = <10000000>;
+            Vdd-supply = <&vdd_supply>;
+            adi,use-external-reference;

This is a bug in the original example. But might as well take this as chance to remove the 'adi,use-external-reference' here, since that property does not exist.

Quoted 4 lines
Documentation/devicetree/bindings/iio/dac/adi,ad7303.yaml new file +4 -0
+            REF-supply = <&vref_supply>;
+        };
+    };
+...
author maintainer
#35 lore raw

Re: [PATCH 17/29] dt-bindings:iio:dac:adi,ad7303 yaml conversion

Quoted 96 lines · On Sun, 11 Oct 2020 19:13:32 +0200 Lars-Peter Clausen <[email protected]> wrote:
Quoted 95 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Converted to maintain the requirement for Vdd-supply as per original file. It is possible we could relax this requirement to make it at least one of Vdd-supply and REF-supply. We need to establish the scaling of the output channel and if REF-supply is provided that is used instead of Vdd-supply, hence I cannot see why a dummy regulator cannot be used for Vdd-supply if this happens.

For now, let us keep it simple.

Cc Lars-Peter Clausen <[email protected]>
---
  .../devicetree/bindings/iio/dac/ad7303.txt    | 23 ---------
  .../bindings/iio/dac/adi,ad7303.yaml          | 51 +++++++++++++++++++
  2 files changed, 51 insertions(+), 23 deletions(-)
Documentation/devicetree/bindings/iio/dac/ad7303.txt deleted +0 -23
deleted file mode 100644
index 914610f0556e..000000000000
@@ -1,23 +0,0 @@
-Analog Devices AD7303 DAC device driver
-
-Required properties:
-	- compatible: Must be "adi,ad7303"
-	- reg: SPI chip select number for the device
-	- spi-max-frequency: Max SPI frequency to use (< 30000000)
-	- Vdd-supply: Phandle to the Vdd power supply
-
-Optional properties:
-	- REF-supply: Phandle to the external reference voltage supply. This should
-	  only be set if there is an external reference voltage connected to the REF
-	  pin. If the property is not set Vdd/2 is used as the reference voltage.
-
-Example:
-
-		ad7303@4 {
-			compatible = "adi,ad7303";
-			reg = <4>;
-			spi-max-frequency = <10000000>;
-			Vdd-supply = <&vdd_supply>;
-			adi,use-external-reference;
-			REF-supply = <&vref_supply>;
-		};
Documentation/devicetree/bindings/iio/dac/adi,ad7303.yaml new file +42 -0
new file mode 100644
index 000000000000..f76c31bf6ee3
@@ -0,0 +1,51 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/dac/adi,ad7303.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Analog Devices AD7303 DAC
+
+maintainers:
+  - Lars-Peter Clausen <[email protected]>
+
+properties:
+  compatible:
+    const: adi,ad7303
+
+  reg:
+    maxItems: 1
+
+  Vdd-supply:
+    description:
+      Used to calculate output channel scalling if REF-supply not specified.
+  REF-supply:
+    description:
+      If not provided, Vdd/2 is used as the reference voltage.
+
+  spi-max-frequency:
+    maximum: 30000000
+
+required:
+  - compatible
+  - reg
+  - Vdd-supply
+
+additionalProperties: false
+
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        dac@4 {
Quoted 8 lines

Documentation/devicetree/bindings/iio/dac/adi,ad7303.yaml line 47

Quoted 5 lines
Documentation/devicetree/bindings/iio/dac/adi,ad7303.yaml new file +5 -0
+            compatible = "adi,ad7303";
+            reg = <4>;
+            spi-max-frequency = <10000000>;
+            Vdd-supply = <&vdd_supply>;
+            adi,use-external-reference;  

This is a bug in the original example. But might as well take this as chance to remove the 'adi,use-external-reference' here, since that property does not exist.

Good point. Will fix in v2.

Thanks,

Jonathan

Quoted 6 lines
Quoted 4 lines
Documentation/devicetree/bindings/iio/dac/adi,ad7303.yaml new file +4 -0
+            REF-supply = <&vref_supply>;
+        };
+    };
+...  
author maintainer
#36 lore raw

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

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Simple conversion of this straight forward binding.

Cc Ismail H. Kose <[email protected]>
Cc Ismail H. Kose <[email protected]>
---
 .../devicetree/bindings/iio/dac/ds4424.txt    | 20 ---------
 .../bindings/iio/dac/maxim,ds4424.yaml        | 45 +++++++++++++++++++
 2 files changed, 45 insertions(+), 20 deletions(-)
Documentation/devicetree/bindings/iio/dac/ds4424.txt deleted +0 -20
deleted file mode 100644
index eaebbf8dab40..000000000000
@@ -1,20 +0,0 @@
-Maxim Integrated DS4422/DS4424 7-bit Sink/Source Current DAC Device Driver
-
-Datasheet publicly available at:
-https://datasheets.maximintegrated.com/en/ds/DS4422-DS4424.pdf
-
-Required properties:
-	- compatible: Should be one of
-		maxim,ds4422
-		maxim,ds4424
-	- reg: Should contain the DAC I2C address
-
-Optional properties:
-	- vcc-supply: Power supply is optional. If not defined, driver will ignore it.
-
-Example:
-	ds4224@10 {
-		compatible = "maxim,ds4424";
-		reg = <0x10>; /* When A0, A1 pins are ground */
-		vcc-supply = <&vcc_3v3>;
-	};
Documentation/devicetree/bindings/iio/dac/maxim,ds4424.yaml new file +45 -0

45 lines not on this page · raw message

Signature · 1 line
2.28.0
author maintainer
#37 lore raw

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

Quoted 7 lines · On Sun, 11 Oct 2020 18:07:38 +0100 Jonathan Cameron <[email protected]> wrote:

From: Jonathan Cameron <[email protected]>

Simple conversion of this straight forward binding.

Cc Ismail H. Kose <[email protected]>
Cc Ismail H. Kose <[email protected]>

Ismail's Maxim address bounces, so I've switched to the gmail one for v2. @Ismail: If you'd rather not be listed as maintaining this binding then let me know.

Thanks,

Jonathan

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

PATCH 19/29 dt-bindings:iio:dac:fsl,vf610-dac yaml conversion

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Simple binding to convert. Example expanded a little to include an example bus.

---
 .../bindings/iio/dac/fsl,vf610-dac.yaml       | 55 +++++++++++++++++++
 .../devicetree/bindings/iio/dac/vf610-dac.txt | 20 -------
 2 files changed, 55 insertions(+), 20 deletions(-)
Documentation/devicetree/bindings/iio/dac/fsl,vf610-dac.yaml new file +55 -0
new file mode 100644
index 000000000000..999c715c6179
@@ -0,0 +1,55 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/dac/fsl,vf610-dac.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Freescale vf610 Digital to Analog Converter
+
+maintainers:
+  - Sanchayan Maity <[email protected]>
+
+properties:
+  compatible:
+    const: fsl,vf610-dac
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+  clocks:
+    maxItems: 1
+
+  clock-names:
+    const: dac
+
+required:
+  - compatible
+  - reg
+  - interrupts
+  - clocks
+  - clock-names
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/interrupt-controller/irq.h>
+    #include <dt-bindings/clock/vf610-clock.h>
+    bus@40000000 {
+        compatible = "fsl,aips-bus", "simple-bus";
+        reg = <0x40000000 0x00070000>;
+        ranges;
+        #address-cells = <1>;
+        #size-cells = <1>;
+        dac@400cc000 {
+            compatible = "fsl,vf610-dac";
+            reg = <0x400cc000 0x1000>;
+            interrupts = <55 IRQ_TYPE_LEVEL_HIGH>;
+            clock-names = "dac";
+            clocks = <&clks VF610_CLK_DAC0>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/dac/vf610-dac.txt deleted +0 -20
deleted file mode 100644
index 20c6c7ae9687..000000000000
@@ -1,20 +0,0 @@
-Freescale vf610 Digital to Analog Converter bindings
-
-The devicetree bindings are for the new DAC driver written for
-vf610 SoCs from Freescale.
-
-Required properties:
-- compatible: Should contain "fsl,vf610-dac"
-- reg: Offset and length of the register set for the device
-- interrupts: Should contain the interrupt for the device
-- clocks: The clock is needed by the DAC controller
-- clock-names: Must contain "dac" matching entry in the clocks property.
-
-Example:
-dac0: dac@400cc000 {
-	compatible = "fsl,vf610-dac";
-	reg = <0x400cc000 0x1000>;
-	interrupts = <55 IRQ_TYPE_LEVEL_HIGH>;
-	clock-names = "dac";
-	clocks = <&clks VF610_CLK_DAC0>;
-};
Signature · 1 line
2.28.0
author maintainer
#39 lore raw

PATCH 20/29 dt-bindings:iio:dac:microchip,mcp4725 yaml conversion

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

I'm not sure vdd-supply absolutely has to be provided if vref-supply is, but as the previous binding docs stated it was required it seems reasonable to leave it as such.

---
 .../devicetree/bindings/iio/dac/mcp4725.txt   | 35 ---------
 .../bindings/iio/dac/microchip,mcp4725.yaml   | 71 +++++++++++++++++++
 2 files changed, 71 insertions(+), 35 deletions(-)
Documentation/devicetree/bindings/iio/dac/mcp4725.txt deleted +0 -35
deleted file mode 100644
index 1bc6c093fbfe..000000000000
@@ -1,35 +0,0 @@
-Microchip mcp4725 and mcp4726 DAC device driver
-
-Required properties:
-	- compatible: Must be "microchip,mcp4725" or "microchip,mcp4726"
-	- reg: Should contain the DAC I2C address
-	- vdd-supply: Phandle to the Vdd power supply. This supply is used as a
-	  voltage reference on mcp4725. It is used as a voltage reference on
-	  mcp4726 if there is no vref-supply specified.
-
-Optional properties (valid only for mcp4726):
-	- vref-supply: Optional phandle to the Vref power supply. Vref pin is
-	  used as a voltage reference when this supply is specified.
-	- microchip,vref-buffered: Boolean to enable buffering of the external
-	  Vref pin. This boolean is not valid without the vref-supply. Quoting
-	  the datasheet: This is offered in cases where the reference voltage
-	  does not have the current capability not to drop its voltage when
-	  connected to the internal resistor ladder circuit.
-
-Examples:
-
-	/* simple mcp4725 */
-	mcp4725@60 {
-		compatible = "microchip,mcp4725";
-		reg = <0x60>;
-		vdd-supply = <&vdac_vdd>;
-	};
-
-	/* mcp4726 with the buffered external reference voltage */
-	mcp4726@60 {
-		compatible = "microchip,mcp4726";
-		reg = <0x60>;
-		vdd-supply = <&vdac_vdd>;
-		vref-supply = <&vdac_vref>;
-		microchip,vref-buffered;
-	};
Documentation/devicetree/bindings/iio/dac/microchip,mcp4725.yaml new file +71 -0

71 lines not on this page · raw message

Signature · 1 line
2.28.0
#40 lore raw

Re: [PATCH 20/29] dt-bindings:iio:dac:microchip,mcp4725 yaml conversion

Hi Jonathan,

Quoted 5 lines · On Sun, 11 Oct 2020 18:07:40 +0100 Jonathan Cameron <[email protected]> wrote:

From: Jonathan Cameron <[email protected]>

I'm not sure vdd-supply absolutely has to be provided if vref-supply is, but as the previous binding docs stated it was required it seems reasonable to leave it as such.

Good catch. Vdd is useless on MCP4726 if Vref is specified. The driver requires Vdd...

How to proceed there?

Thanks,

Tomas

Quoted 125 lines
---
 .../devicetree/bindings/iio/dac/mcp4725.txt   | 35 ---------
 .../bindings/iio/dac/microchip,mcp4725.yaml   | 71 +++++++++++++++++++
 2 files changed, 71 insertions(+), 35 deletions(-)
Documentation/devicetree/bindings/iio/dac/mcp4725.txt deleted +0 -35
deleted file mode 100644
index 1bc6c093fbfe..000000000000
@@ -1,35 +0,0 @@
-Microchip mcp4725 and mcp4726 DAC device driver
-
-Required properties:
-	- compatible: Must be "microchip,mcp4725" or "microchip,mcp4726"
-	- reg: Should contain the DAC I2C address
-	- vdd-supply: Phandle to the Vdd power supply. This supply is used as a
-	  voltage reference on mcp4725. It is used as a voltage reference on
-	  mcp4726 if there is no vref-supply specified.
-
-Optional properties (valid only for mcp4726):
-	- vref-supply: Optional phandle to the Vref power supply. Vref pin is
-	  used as a voltage reference when this supply is specified.
-	- microchip,vref-buffered: Boolean to enable buffering of the external
-	  Vref pin. This boolean is not valid without the vref-supply. Quoting
-	  the datasheet: This is offered in cases where the reference voltage
-	  does not have the current capability not to drop its voltage when
-	  connected to the internal resistor ladder circuit.
-
-Examples:
-
-	/* simple mcp4725 */
-	mcp4725@60 {
-		compatible = "microchip,mcp4725";
-		reg = <0x60>;
-		vdd-supply = <&vdac_vdd>;
-	};
-
-	/* mcp4726 with the buffered external reference voltage */
-	mcp4726@60 {
-		compatible = "microchip,mcp4726";
-		reg = <0x60>;
-		vdd-supply = <&vdac_vdd>;
-		vref-supply = <&vdac_vref>;
-		microchip,vref-buffered;
-	};
Documentation/devicetree/bindings/iio/dac/microchip,mcp4725.yaml new file +71 -0
new file mode 100644
index 000000000000..271998610ceb
@@ -0,0 +1,71 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/dac/microchip,mcp4725.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Microchip mcp4725 and mcp4726 DAC
+
+maintainers:
+  - Tomas Novotny <[email protected]>
+
+properties:
+  compatible:
+    enum:
+      - microchip,mcp4725
+      - microchip,mcp4726
+
+  reg:
+    maxItems: 1
+
+  vdd-supply:
+    description: |
+      Provides both power and acts as the reference supply on the mcp4725.
+      For the mcp4726 it will be used as the reference voltage if vref-supply
+      is not provided.
+
+  vref-supply:
+    description:
+      Vref pin is used as a voltage reference when this supply is specified.
+
+  microchip,vref-buffered:
+    type: boolean
+    description: |
+      Enable buffering of the external Vref pin. This boolean is not valid
+      without the vref-supply. Quoting the datasheet: This is offered in
+      cases where the reference voltage does not have the current
+      capability not to drop its voltage when connected to the internal
+      resistor ladder circuit.
+
+allOf:
+  - if:
+      not:
+        properties:
+          compatible:
+            contains:
+              const: microchip,mcp4726
+    then:
+      properties:
+        vref-supply: false
+        microchip,vref-buffered: false
+
+required:
+  - compatible
+  - reg
+  - vdd-supply
+
+additionalProperties: false
+
+examples:
+  - |
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        mcp4725@60 {
+            compatible = "microchip,mcp4725";
+            reg = <0x60>;
+            vdd-supply = <&vdac_vdd>;
+        };
+    };
+...
#41 lore raw

Re: [PATCH 20/29] dt-bindings:iio:dac:microchip,mcp4725 yaml conversion

Quoted 5 lines · On Mon, 12 Oct 2020 16:02:30 +0200 Tomas Novotny <[email protected]> wrote:

Hi Jonathan,

On Sun, 11 Oct 2020 18:07:40 +0100
Jonathan Cameron <[email protected]> wrote:

Quoted 8 lines
Quoted 5 lines

From: Jonathan Cameron <[email protected]>

I'm not sure vdd-supply absolutely has to be provided if vref-supply is, but as the previous binding docs stated it was required it seems reasonable to leave it as such.

Good catch. Vdd is useless on MCP4726 if Vref is specified. The driver requires Vdd...

The driver will get the regulator but as it's not via an optional call it the regulator core will provide a stub regulator. If the ref regulator is present, all that will happen with vdd is a regulator_enable() call which is fine with a stub regulator (it's
a noop). So we should be good to update the binding to specify
the requirement. Perhaps it's one to do as a follow up patch?
Given any existing DT must be providing that regulator, there is no rush for us to fix it :)

Quoted 132 lines

How to proceed there?

Thanks,

Tomas

Quoted 125 lines
---
 .../devicetree/bindings/iio/dac/mcp4725.txt   | 35 ---------
 .../bindings/iio/dac/microchip,mcp4725.yaml   | 71 +++++++++++++++++++
 2 files changed, 71 insertions(+), 35 deletions(-)
Documentation/devicetree/bindings/iio/dac/mcp4725.txt deleted +0 -35
deleted file mode 100644
index 1bc6c093fbfe..000000000000
@@ -1,35 +0,0 @@
-Microchip mcp4725 and mcp4726 DAC device driver
-
-Required properties:
-	- compatible: Must be "microchip,mcp4725" or "microchip,mcp4726"
-	- reg: Should contain the DAC I2C address
-	- vdd-supply: Phandle to the Vdd power supply. This supply is used as a
-	  voltage reference on mcp4725. It is used as a voltage reference on
-	  mcp4726 if there is no vref-supply specified.
-
-Optional properties (valid only for mcp4726):
-	- vref-supply: Optional phandle to the Vref power supply. Vref pin is
-	  used as a voltage reference when this supply is specified.
-	- microchip,vref-buffered: Boolean to enable buffering of the external
-	  Vref pin. This boolean is not valid without the vref-supply. Quoting
-	  the datasheet: This is offered in cases where the reference voltage
-	  does not have the current capability not to drop its voltage when
-	  connected to the internal resistor ladder circuit.
-
-Examples:
-
-	/* simple mcp4725 */
-	mcp4725@60 {
-		compatible = "microchip,mcp4725";
-		reg = <0x60>;
-		vdd-supply = <&vdac_vdd>;
-	};
-
-	/* mcp4726 with the buffered external reference voltage */
-	mcp4726@60 {
-		compatible = "microchip,mcp4726";
-		reg = <0x60>;
-		vdd-supply = <&vdac_vdd>;
-		vref-supply = <&vdac_vref>;
-		microchip,vref-buffered;
-	};
Documentation/devicetree/bindings/iio/dac/microchip,mcp4725.yaml new file +71 -0
new file mode 100644
index 000000000000..271998610ceb
@@ -0,0 +1,71 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/dac/microchip,mcp4725.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Microchip mcp4725 and mcp4726 DAC
+
+maintainers:
+  - Tomas Novotny <[email protected]>
+
+properties:
+  compatible:
+    enum:
+      - microchip,mcp4725
+      - microchip,mcp4726
+
+  reg:
+    maxItems: 1
+
+  vdd-supply:
+    description: |
+      Provides both power and acts as the reference supply on the mcp4725.
+      For the mcp4726 it will be used as the reference voltage if vref-supply
+      is not provided.
+
+  vref-supply:
+    description:
+      Vref pin is used as a voltage reference when this supply is specified.
+
+  microchip,vref-buffered:
+    type: boolean
+    description: |
+      Enable buffering of the external Vref pin. This boolean is not valid
+      without the vref-supply. Quoting the datasheet: This is offered in
+      cases where the reference voltage does not have the current
+      capability not to drop its voltage when connected to the internal
+      resistor ladder circuit.
+
+allOf:
+  - if:
+      not:
+        properties:
+          compatible:
+            contains:
+              const: microchip,mcp4726
+    then:
+      properties:
+        vref-supply: false
+        microchip,vref-buffered: false
+
+required:
+  - compatible
+  - reg
+  - vdd-supply
+
+additionalProperties: false
+
+examples:
+  - |
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        mcp4725@60 {
+            compatible = "microchip,mcp4725";
+            reg = <0x60>;
+            vdd-supply = <&vdac_vdd>;
+        };
+    };
+...  
#42 lore raw

Re: [PATCH 20/29] dt-bindings:iio:dac:microchip,mcp4725 yaml conversion

Hi Jonathan,

Quoted 17 lines · On Mon, 12 Oct 2020 15:39:23 +0100 Jonathan Cameron…
Quoted 5 lines · On Mon, 12 Oct 2020 16:02:30 +0200 Tomas Novotny <[email protected]> wrote:

Hi Jonathan,

On Sun, 11 Oct 2020 18:07:40 +0100
Jonathan Cameron <[email protected]> wrote:

Quoted 8 lines
Quoted 5 lines

From: Jonathan Cameron <[email protected]>

I'm not sure vdd-supply absolutely has to be provided if vref-supply is, but as the previous binding docs stated it was required it seems reasonable to leave it as such.

Good catch. Vdd is useless on MCP4726 if Vref is specified. The driver requires Vdd...

Quoted 8 lines

The driver will get the regulator but as it's not via an optional call it the regulator core will provide a stub regulator. If the ref regulator is present, all that will happen with vdd is a regulator_enable() call which is fine with a stub regulator (it's
a noop). So we should be good to update the binding to specify
the requirement. Perhaps it's one to do as a follow up patch?
Given any existing DT must be providing that regulator, there is no rush for us to fix it :)

ok, I see, I will handle with a follow up patch when this will be merged. Thanks,

Tomas

Quoted 133 lines
Quoted 131 lines

How to proceed there?

Thanks,

Tomas

Quoted 125 lines
---
 .../devicetree/bindings/iio/dac/mcp4725.txt   | 35 ---------
 .../bindings/iio/dac/microchip,mcp4725.yaml   | 71 +++++++++++++++++++
 2 files changed, 71 insertions(+), 35 deletions(-)
Documentation/devicetree/bindings/iio/dac/mcp4725.txt deleted +0 -35
deleted file mode 100644
index 1bc6c093fbfe..000000000000
@@ -1,35 +0,0 @@
-Microchip mcp4725 and mcp4726 DAC device driver
-
-Required properties:
-	- compatible: Must be "microchip,mcp4725" or "microchip,mcp4726"
-	- reg: Should contain the DAC I2C address
-	- vdd-supply: Phandle to the Vdd power supply. This supply is used as a
-	  voltage reference on mcp4725. It is used as a voltage reference on
-	  mcp4726 if there is no vref-supply specified.
-
-Optional properties (valid only for mcp4726):
-	- vref-supply: Optional phandle to the Vref power supply. Vref pin is
-	  used as a voltage reference when this supply is specified.
-	- microchip,vref-buffered: Boolean to enable buffering of the external
-	  Vref pin. This boolean is not valid without the vref-supply. Quoting
-	  the datasheet: This is offered in cases where the reference voltage
-	  does not have the current capability not to drop its voltage when
-	  connected to the internal resistor ladder circuit.
-
-Examples:
-
-	/* simple mcp4725 */
-	mcp4725@60 {
-		compatible = "microchip,mcp4725";
-		reg = <0x60>;
-		vdd-supply = <&vdac_vdd>;
-	};
-
-	/* mcp4726 with the buffered external reference voltage */
-	mcp4726@60 {
-		compatible = "microchip,mcp4726";
-		reg = <0x60>;
-		vdd-supply = <&vdac_vdd>;
-		vref-supply = <&vdac_vref>;
-		microchip,vref-buffered;
-	};
Documentation/devicetree/bindings/iio/dac/microchip,mcp4725.yaml new file +71 -0
new file mode 100644
index 000000000000..271998610ceb
@@ -0,0 +1,71 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/dac/microchip,mcp4725.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Microchip mcp4725 and mcp4726 DAC
+
+maintainers:
+  - Tomas Novotny <[email protected]>
+
+properties:
+  compatible:
+    enum:
+      - microchip,mcp4725
+      - microchip,mcp4726
+
+  reg:
+    maxItems: 1
+
+  vdd-supply:
+    description: |
+      Provides both power and acts as the reference supply on the mcp4725.
+      For the mcp4726 it will be used as the reference voltage if vref-supply
+      is not provided.
+
+  vref-supply:
+    description:
+      Vref pin is used as a voltage reference when this supply is specified.
+
+  microchip,vref-buffered:
+    type: boolean
+    description: |
+      Enable buffering of the external Vref pin. This boolean is not valid
+      without the vref-supply. Quoting the datasheet: This is offered in
+      cases where the reference voltage does not have the current
+      capability not to drop its voltage when connected to the internal
+      resistor ladder circuit.
+
+allOf:
+  - if:
+      not:
+        properties:
+          compatible:
+            contains:
+              const: microchip,mcp4726
+    then:
+      properties:
+        vref-supply: false
+        microchip,vref-buffered: false
+
+required:
+  - compatible
+  - reg
+  - vdd-supply
+
+additionalProperties: false
+
+examples:
+  - |
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        mcp4725@60 {
+            compatible = "microchip,mcp4725";
+            reg = <0x60>;
+            vdd-supply = <&vdac_vdd>;
+        };
+    };
+...    
author maintainer
#43 lore raw

PATCH 21/29 dt-bindings:iio:dac:maxim,max5821 yaml conversion

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Simple txt to yaml conversion for this binding description.

---
 .../devicetree/bindings/iio/dac/max5821.txt   | 14 ------
 .../bindings/iio/dac/maxim,max5821.yaml       | 44 +++++++++++++++++++
 2 files changed, 44 insertions(+), 14 deletions(-)
Documentation/devicetree/bindings/iio/dac/max5821.txt deleted +0 -14
deleted file mode 100644
index 54276ce8c971..000000000000
@@ -1,14 +0,0 @@
-Maxim max5821 DAC device driver
-
-Required properties:
-	- compatible: Must be "maxim,max5821"
-	- reg: Should contain the DAC I2C address
-	- vref-supply: Phandle to the vref power supply
-
-Example:
-
-	max5821@38 {
-		compatible = "maxim,max5821";
-		reg = <0x38>;
-		vref-supply = <&reg_max5821>;
-	};
Documentation/devicetree/bindings/iio/dac/maxim,max5821.yaml new file +44 -0

44 lines not on this page · raw message

Signature · 1 line
2.28.0
author maintainer
#44 lore raw

PATCH 22/29 dt-bindings:iio:dac:nxp,lpc1850-dac yaml conversion.

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Very similar binding to that for the ADC on the same device. Conversion from txt to yaml format.

---
 .../bindings/iio/dac/lpc1850-dac.txt          | 19 ------
 .../bindings/iio/dac/nxp,lpc1850-dac.yaml     | 58 +++++++++++++++++++
 2 files changed, 58 insertions(+), 19 deletions(-)
Documentation/devicetree/bindings/iio/dac/lpc1850-dac.txt deleted +0 -19
deleted file mode 100644
index 42db783c4e75..000000000000
@@ -1,19 +0,0 @@
-NXP LPC1850 DAC bindings
-
-Required properties:
-- compatible: Should be "nxp,lpc1850-dac"
-- reg: Offset and length of the register set for the ADC device
-- interrupts: The interrupt number for the ADC device
-- clocks: The root clock of the ADC controller
-- vref-supply: The regulator supply ADC reference voltage
-- resets: phandle to reset controller and line specifier
-
-Example:
-dac: dac@400e1000 {
-	compatible = "nxp,lpc1850-dac";
-	reg = <0x400e1000 0x1000>;
-	interrupts = <0>;
-	clocks = <&ccu1 CLK_APB3_DAC>;
-	vref-supply = <&reg_vdda>;
-	resets = <&rgu 42>;
-};
Documentation/devicetree/bindings/iio/dac/nxp,lpc1850-dac.yaml new file +58 -0

58 lines not on this page · raw message

Signature · 1 line
2.28.0
author maintainer
#45 lore raw

Re: [PATCH 22/29] dt-bindings:iio:dac:nxp,lpc1850-dac yaml conversion.

Quoted 7 lines · On Sun, 11 Oct 2020 18:07:42 +0100 Jonathan Cameron <[email protected]> wrote:

From: Jonathan Cameron <[email protected]>

Very similar binding to that for the ADC on the same device. Conversion from txt to yaml format.

Joachim's email is bouncing, so I'll list myself as maintainer for this one. @Vladimir, you are listed as maintainer of the lpc18xx parts in general. Any views on maintaining this binding?

+CC Vladimir Zapolskiy

Quoted 94 lines
---
 .../bindings/iio/dac/lpc1850-dac.txt          | 19 ------
 .../bindings/iio/dac/nxp,lpc1850-dac.yaml     | 58 +++++++++++++++++++
 2 files changed, 58 insertions(+), 19 deletions(-)
Documentation/devicetree/bindings/iio/dac/lpc1850-dac.txt deleted +0 -19
deleted file mode 100644
index 42db783c4e75..000000000000
@@ -1,19 +0,0 @@
-NXP LPC1850 DAC bindings
-
-Required properties:
-- compatible: Should be "nxp,lpc1850-dac"
-- reg: Offset and length of the register set for the ADC device
-- interrupts: The interrupt number for the ADC device
-- clocks: The root clock of the ADC controller
-- vref-supply: The regulator supply ADC reference voltage
-- resets: phandle to reset controller and line specifier
-
-Example:
-dac: dac@400e1000 {
-	compatible = "nxp,lpc1850-dac";
-	reg = <0x400e1000 0x1000>;
-	interrupts = <0>;
-	clocks = <&ccu1 CLK_APB3_DAC>;
-	vref-supply = <&reg_vdda>;
-	resets = <&rgu 42>;
-};
Documentation/devicetree/bindings/iio/dac/nxp,lpc1850-dac.yaml new file +58 -0
new file mode 100644
index 000000000000..2728ec3433e0
@@ -0,0 +1,58 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/dac/nxp,lpc1850-dac.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: NXP LPC1850 DAC bindings
+
+maintainers:
+  - Joachim Eastwood <[email protected]>
+
+description:
+  Supports the DAC found on the LPC1850 SoC.
+
+properties:
+  compatible:
+    const: nxp,lpc1850-dac
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+  clocks:
+    maxItems: 1
+
+  vref-supply: true
+
+  resets:
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+  - interrupts
+  - clocks
+  - vref-supply
+  - resets
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/clock/lpc18xx-ccu.h>
+    soc {
+        #address-cells = <1>;
+        #size-cells = <1>;
+        dac: dac@400e1000 {
+            compatible = "nxp,lpc1850-dac";
+            reg = <0x400e1000 0x1000>;
+            interrupts = <0>;
+            clocks = <&ccu1 CLK_APB3_DAC>;
+            vref-supply = <&reg_vdda>;
+            resets = <&rgu 42>;
+        };
+    };
+...
Acked-by on v1 22/29
#46 lore raw

Re: [PATCH 22/29] dt-bindings:iio:dac:nxp,lpc1850-dac yaml conversion.

In reply to Jonathan Cameron

Hi Jonathan,

Quoted 5 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Very similar binding to that for the ADC on the same device. Conversion from txt to yaml format.

Quoted 7 lines
---
  .../bindings/iio/dac/lpc1850-dac.txt          | 19 ------
  .../bindings/iio/dac/nxp,lpc1850-dac.yaml     | 58 +++++++++++++++++++
  2 files changed, 58 insertions(+), 19 deletions(-)

the conversion looks totally correct, thank you.

--
Best wishes,
Vladimir

author maintainer
#47 lore raw

PATCH 23/29 dt-bindings:iio:dac:adi,ad5758 yaml conversion

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

I have put Michael as maintainer on this one. Happy to change it to someone else though.

One issue in here, is I cannot have an example with a negative limit on the range. There are very few such yaml bindings in existence but the thermal-zones.yaml has the same problem. If there is any means of fixing this let me know. For now I'm sticking to positive range values in the example.

Cc Michael Hennerich <[email protected]>
---
 .../devicetree/bindings/iio/dac/ad5758.txt    |  83 -----------
 .../bindings/iio/dac/adi,ad5758.yaml          | 129 ++++++++++++++++++
 2 files changed, 129 insertions(+), 83 deletions(-)
Documentation/devicetree/bindings/iio/dac/ad5758.txt deleted +0 -83
deleted file mode 100644
index 2f607f41f9d3..000000000000
@@ -1,83 +0,0 @@
-Analog Devices AD5758 DAC device driver
-
-Required properties for the AD5758:
-	- compatible: Must be "adi,ad5758"
-	- reg: SPI chip select number for the device
-	- spi-max-frequency: Max SPI frequency to use (< 50000000)
-	- spi-cpha: is the only mode that is supported
-
-Required properties:
-
- - adi,dc-dc-mode: Mode of operation of the dc-to-dc converter
-		   Dynamic Power Control (DPC)
-		   In this mode, the AD5758 circuitry senses the output
-		   voltage and dynamically regulates the supply voltage,
-		   VDPC+, to meet compliance requirements plus an optimized
-		   headroom voltage for the output buffer.
-
-		   Programmable Power Control (PPC)
-		   In this mode, the VDPC+ voltage is user-programmable to
-		   a fixed level that needs to accommodate the maximum output
-		   load required.
-
-		   The output of the DAC core is either converted to a
-		   current or voltage output at the VIOUT pin. Only one mode
-		   can be enabled at any one time.
-
-		   The following values are currently supported:
-			* 1: DPC current mode
-			* 2: DPC voltage mode
-			* 3: PPC current mode
-
- Depending on the selected output mode (voltage or current) one of the
- two properties must
- be present:
-
- - adi,range-microvolt: Voltage output range
-		The array of voltage output ranges must contain two fields:
-		* <0 5000000>: 0 V to 5 V voltage range
-		* <0 10000000>: 0 V to 10 V voltage range
-		* <(-5000000) 5000000>: ±5 V voltage range
-		* <(-10000000) 10000000>: ±10 V voltage range
- - adi,range-microamp: Current output range
-		The array of current output ranges must contain two fields:
-		* <0 20000>: 0 mA to 20 mA current range
-		* <0 24000>: 0 mA to 24 mA current range
-		* <4 24000>: 4 mA to 20 mA current range
-		* <(-20000) 20000>: ±20 mA current range
-		* <(-24000) 24000>: ±24 mA current range
-		* <(-1000) 22000>: −1 mA to +22 mA current range
-
-Optional properties:
-
- - reset-gpios : GPIO spec for the RESET pin. If specified, it will be
-		 asserted during driver probe.
-
- - adi,dc-dc-ilim-microamp: The dc-to-dc converter current limit
-		   The following values are currently supported [uA]:
-			* 150000
-			* 200000
-			* 250000
-			* 300000
-			* 350000
-			* 400000
-
- - adi,slew-time-us: The time it takes for the output to reach the
- full scale [uS]
-		     The supported range is between 133us up to 1023984375us
-
-AD5758 Example:
-
-	dac@0 {
-		compatible = "adi,ad5758";
-		reg = <0>;
-		spi-max-frequency = <1000000>;
-		spi-cpha;
-
-		reset-gpios = <&gpio 22 0>;
-
-		adi,dc-dc-mode = <2>;
-		adi,range-microvolt = <0 10000000>;
-		adi,dc-dc-ilim-microamp = <200000>;
-		adi,slew-time-us = <125000>;
-	};
Documentation/devicetree/bindings/iio/dac/adi,ad5758.yaml new file +129 -0

129 lines not on this page · raw message

Signature · 1 line
2.28.0
author maintainer
#48 lore raw

PATCH 24/29 dt-bindings:iio:temperature:melexis,mlx90614 yaml conversion

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Simple conversion from txt to yaml.
I've listed all 3 authors of the driver as maintainers.

Cc Peter Meerwald <[email protected]>
Cc Vianney le Clément de Saint-Marcq <[email protected]>
Cc Crt Mori <[email protected]>
---
 .../iio/temperature/melexis,mlx90614.yaml     | 51 +++++++++++++++++++
 .../bindings/iio/temperature/mlx90614.txt     | 24 ---------
 2 files changed, 51 insertions(+), 24 deletions(-)
Documentation/devicetree/bindings/iio/temperature/melexis,mlx90614.yaml new file +51 -0
new file mode 100644
index 000000000000..dcda203b2ba5
@@ -0,0 +1,51 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/temperature/melexis,mlx90614.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Melexis MLX90614 contactless IR temperature sensor
+
+maintainers:
+  - Peter Meerwald <[email protected]>
+  - Vianney le Clément de Saint-Marcq <[email protected]>
+  - Crt Mori <[email protected]>
+
+description: |
+  http://melexis.com/Infrared-Thermometer-Sensors/Infrared-Thermometer-Sensors/MLX90614-615.aspx
+
+properties:
+  compatible:
+    const: melexis,mlx90614
+
+  reg:
+    maxItems: 1
+
+  wakeup-gpios:
+    description:
+      GPIO connected to the SDA line to hold low in order to wake up the
+      device.  In normal operation, the GPIO is set as input and will
+      not interfere in I2C communication.  There is no need for a GPIO
+      driving the SCL line.  If no GPIO is given, power management is disabled.
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/gpio/gpio.h>
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        temp-sensor@5a {
+            compatible = "melexis,mlx90614";
+            reg = <0x5a>;
+            wakeup-gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/temperature/mlx90614.txt deleted +0 -24
deleted file mode 100644
index 9be57b036092..000000000000
@@ -1,24 +0,0 @@
-* Melexis MLX90614 contactless IR temperature sensor
-
-http://melexis.com/Infrared-Thermometer-Sensors/Infrared-Thermometer-Sensors/MLX90614-615.aspx
-
-Required properties:
-
-  - compatible: should be "melexis,mlx90614"
-  - reg: the I2C address of the sensor
-
-Optional properties:
-
-  - wakeup-gpios: device tree identifier of the GPIO connected to the SDA line
-      to hold low in order to wake up the device.  In normal operation, the
-      GPIO is set as input and will not interfere in I2C communication.  There
-      is no need for a GPIO driving the SCL line.  If no GPIO is given, power
-      management is disabled.
-
-Example:
-
-mlx90614@5a {
-	compatible = "melexis,mlx90614";
-	reg = <0x5a>;
-	wakeup-gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
-};
Signature · 1 line
2.28.0
Acked-by on v1 24/29
#49 lore raw

Re: [PATCH 24/29] dt-bindings:iio:temperature:melexis,mlx90614 yaml conversion

Thanks for the conversion. No idea which tag to put, so:

Quoted 105 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Simple conversion from txt to yaml.
I've listed all 3 authors of the driver as maintainers.

Cc Peter Meerwald <[email protected]>
Cc Vianney le Clément de Saint-Marcq <[email protected]>
Cc Crt Mori <[email protected]>
---
 .../iio/temperature/melexis,mlx90614.yaml     | 51 +++++++++++++++++++
 .../bindings/iio/temperature/mlx90614.txt     | 24 ---------
 2 files changed, 51 insertions(+), 24 deletions(-)
Documentation/devicetree/bindings/iio/temperature/melexis,mlx90614.yaml new file +51 -0
new file mode 100644
index 000000000000..dcda203b2ba5
@@ -0,0 +1,51 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/temperature/melexis,mlx90614.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Melexis MLX90614 contactless IR temperature sensor
+
+maintainers:
+  - Peter Meerwald <[email protected]>
+  - Vianney le Clément de Saint-Marcq <[email protected]>
+  - Crt Mori <[email protected]>
+
+description: |
+  http://melexis.com/Infrared-Thermometer-Sensors/Infrared-Thermometer-Sensors/MLX90614-615.aspx
+
+properties:
+  compatible:
+    const: melexis,mlx90614
+
+  reg:
+    maxItems: 1
+
+  wakeup-gpios:
+    description:
+      GPIO connected to the SDA line to hold low in order to wake up the
+      device.  In normal operation, the GPIO is set as input and will
+      not interfere in I2C communication.  There is no need for a GPIO
+      driving the SCL line.  If no GPIO is given, power management is disabled.
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/gpio/gpio.h>
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        temp-sensor@5a {
+            compatible = "melexis,mlx90614";
+            reg = <0x5a>;
+            wakeup-gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/temperature/mlx90614.txt deleted +0 -25
deleted file mode 100644
index 9be57b036092..000000000000
@@ -1,24 +0,0 @@
-* Melexis MLX90614 contactless IR temperature sensor
-
-http://melexis.com/Infrared-Thermometer-Sensors/Infrared-Thermometer-Sensors/MLX90614-615.aspx
-
-Required properties:
-
-  - compatible: should be "melexis,mlx90614"
-  - reg: the I2C address of the sensor
-
-Optional properties:
-
-  - wakeup-gpios: device tree identifier of the GPIO connected to the SDA line
-      to hold low in order to wake up the device.  In normal operation, the
-      GPIO is set as input and will not interfere in I2C communication.  There
-      is no need for a GPIO driving the SCL line.  If no GPIO is given, power
-      management is disabled.
-
-Example:
-
-mlx90614@5a {
-       compatible = "melexis,mlx90614";
-       reg = <0x5a>;
-       wakeup-gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
-};
--

2.28.0

#50 lore raw

Re: [PATCH 24/29] dt-bindings:iio:temperature:melexis,mlx90614 yaml conversion

Hi Jonathan,
I got mail bounce (account doesn't exist) from Vianney le Clément de Saint-Marcq <[email protected]>, so I would assume he is not working there anymore. I think we can remove him from the maintainers list?

Best regards,
Crt

Quoted 110 lines · Crt Mori

Thanks for the conversion. No idea which tag to put, so:

Quoted 105 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Simple conversion from txt to yaml.
I've listed all 3 authors of the driver as maintainers.

Cc Peter Meerwald <[email protected]>
Cc Vianney le Clément de Saint-Marcq <[email protected]>
Cc Crt Mori <[email protected]>
---
 .../iio/temperature/melexis,mlx90614.yaml     | 51 +++++++++++++++++++
 .../bindings/iio/temperature/mlx90614.txt     | 24 ---------
 2 files changed, 51 insertions(+), 24 deletions(-)
Documentation/devicetree/bindings/iio/temperature/melexis,mlx90614.yaml new file +51 -0
new file mode 100644
index 000000000000..dcda203b2ba5
@@ -0,0 +1,51 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/temperature/melexis,mlx90614.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Melexis MLX90614 contactless IR temperature sensor
+
+maintainers:
+  - Peter Meerwald <[email protected]>
+  - Vianney le Clément de Saint-Marcq <[email protected]>
+  - Crt Mori <[email protected]>
+
+description: |
+  http://melexis.com/Infrared-Thermometer-Sensors/Infrared-Thermometer-Sensors/MLX90614-615.aspx
+
+properties:
+  compatible:
+    const: melexis,mlx90614
+
+  reg:
+    maxItems: 1
+
+  wakeup-gpios:
+    description:
+      GPIO connected to the SDA line to hold low in order to wake up the
+      device.  In normal operation, the GPIO is set as input and will
+      not interfere in I2C communication.  There is no need for a GPIO
+      driving the SCL line.  If no GPIO is given, power management is disabled.
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/gpio/gpio.h>
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        temp-sensor@5a {
+            compatible = "melexis,mlx90614";
+            reg = <0x5a>;
+            wakeup-gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/temperature/mlx90614.txt deleted +0 -25
deleted file mode 100644
index 9be57b036092..000000000000
@@ -1,24 +0,0 @@
-* Melexis MLX90614 contactless IR temperature sensor
-
-http://melexis.com/Infrared-Thermometer-Sensors/Infrared-Thermometer-Sensors/MLX90614-615.aspx
-
-Required properties:
-
-  - compatible: should be "melexis,mlx90614"
-  - reg: the I2C address of the sensor
-
-Optional properties:
-
-  - wakeup-gpios: device tree identifier of the GPIO connected to the SDA line
-      to hold low in order to wake up the device.  In normal operation, the
-      GPIO is set as input and will not interfere in I2C communication.  There
-      is no need for a GPIO driving the SCL line.  If no GPIO is given, power
-      management is disabled.
-
-Example:
-
-mlx90614@5a {
-       compatible = "melexis,mlx90614";
-       reg = <0x5a>;
-       wakeup-gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
-};
--

2.28.0

#51 lore raw

Re: [PATCH 24/29] dt-bindings:iio:temperature:melexis,mlx90614 yaml conversion

Quoted 5 lines · On Mon, 12 Oct 2020 10:00:15 +0200 Crt Mori <[email protected]> wrote:

Hi Jonathan,
I got mail bounce (account doesn't exist) from Vianney le Clément de Saint-Marcq <[email protected]>, so I would assume he is not working there anymore. I think we can remove him from the maintainers list?

yup.

I put it in the cover letter, but one of the side effects of sending this series out is to identify who we no longer have contact details for and switch / drop them as necessary. Will drop Vianney unless anyone has a working email address.

Thanks,

Jonathan

Quoted 115 lines

Best regards,
Crt

Quoted 110 lines · Crt Mori

Thanks for the conversion. No idea which tag to put, so:

Quoted 105 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Simple conversion from txt to yaml.
I've listed all 3 authors of the driver as maintainers.

Cc Peter Meerwald <[email protected]>
Cc Vianney le Clément de Saint-Marcq <[email protected]>
Cc Crt Mori <[email protected]>
---
 .../iio/temperature/melexis,mlx90614.yaml     | 51 +++++++++++++++++++
 .../bindings/iio/temperature/mlx90614.txt     | 24 ---------
 2 files changed, 51 insertions(+), 24 deletions(-)
Documentation/devicetree/bindings/iio/temperature/melexis,mlx90614.yaml new file +51 -0
new file mode 100644
index 000000000000..dcda203b2ba5
@@ -0,0 +1,51 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/temperature/melexis,mlx90614.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Melexis MLX90614 contactless IR temperature sensor
+
+maintainers:
+  - Peter Meerwald <[email protected]>
+  - Vianney le Clément de Saint-Marcq <[email protected]>
+  - Crt Mori <[email protected]>
+
+description: |
+  http://melexis.com/Infrared-Thermometer-Sensors/Infrared-Thermometer-Sensors/MLX90614-615.aspx
+
+properties:
+  compatible:
+    const: melexis,mlx90614
+
+  reg:
+    maxItems: 1
+
+  wakeup-gpios:
+    description:
+      GPIO connected to the SDA line to hold low in order to wake up the
+      device.  In normal operation, the GPIO is set as input and will
+      not interfere in I2C communication.  There is no need for a GPIO
+      driving the SCL line.  If no GPIO is given, power management is disabled.
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/gpio/gpio.h>
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        temp-sensor@5a {
+            compatible = "melexis,mlx90614";
+            reg = <0x5a>;
+            wakeup-gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/temperature/mlx90614.txt deleted +0 -25
deleted file mode 100644
index 9be57b036092..000000000000
@@ -1,24 +0,0 @@
-* Melexis MLX90614 contactless IR temperature sensor
-
-http://melexis.com/Infrared-Thermometer-Sensors/Infrared-Thermometer-Sensors/MLX90614-615.aspx
-
-Required properties:
-
-  - compatible: should be "melexis,mlx90614"
-  - reg: the I2C address of the sensor
-
-Optional properties:
-
-  - wakeup-gpios: device tree identifier of the GPIO connected to the SDA line
-      to hold low in order to wake up the device.  In normal operation, the
-      GPIO is set as input and will not interfere in I2C communication.  There
-      is no need for a GPIO driving the SCL line.  If no GPIO is given, power
-      management is disabled.
-
-Example:
-
-mlx90614@5a {
-       compatible = "melexis,mlx90614";
-       reg = <0x5a>;
-       wakeup-gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
-};
--

2.28.0

author maintainer
#52 lore raw

PATCH 25/29 dt-bindings:iio:temperature:melexis,mlx90632 conversion to yaml

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Technically this could have gone in trivial-devices.yaml, but I have kept it as a separate binding due to the detailed additional description from the text file.

---
 .../iio/temperature/melexis,mlx90632.yaml     | 55 +++++++++++++++++++
 .../bindings/iio/temperature/mlx90632.txt     | 28 ----------
 2 files changed, 55 insertions(+), 28 deletions(-)
Documentation/devicetree/bindings/iio/temperature/melexis,mlx90632.yaml new file +55 -0
new file mode 100644
index 000000000000..b547ddcd544a
@@ -0,0 +1,55 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/temperature/melexis,mlx90632.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Melexis MLX90632 contactless Infra Red temperature sensor
+
+maintainers:
+  - Crt Mori <[email protected]>
+
+description: |
+  https://www.melexis.com/en/documents/documentation/datasheets/datasheet-mlx90632
+
+  There are various applications for the Infra Red contactless temperature
+  sensor and MLX90632 is most suitable for consumer applications where
+  measured object temperature is in range between -20 to 200 degrees
+  Celsius with relative error of measurement below 1 degree Celsius in
+  object temperature range for industrial applications. Since it can
+  operate and measure ambient temperature in range of -20 to 85 degrees
+  Celsius it is suitable also for outdoor use.
+
+  Be aware that electronics surrounding the sensor can increase ambient
+  temperature. MLX90632 can be calibrated to reduce the housing effect via
+  already existing EEPROM parameters.
+
+  Since measured object emissivity effects Infra Red energy emitted,
+  emissivity should be set before requesting the object temperature.
+
+properties:
+  compatible:
+    const: melexis,mlx90632
+
+  reg:
+    maxItems: 1
+    description: Default is 0x3a, but can be reprogrammed.
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        temp-sensor@3a {
+            compatible = "melexis,mlx90632";
+            reg = <0x3a>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/temperature/mlx90632.txt deleted +0 -28
deleted file mode 100644
index 0b05812001f8..000000000000
@@ -1,28 +0,0 @@
-* Melexis MLX90632 contactless Infra Red temperature sensor
-
-Link to datasheet: https://www.melexis.com/en/documents/documentation/datasheets/datasheet-mlx90632
-
-There are various applications for the Infra Red contactless temperature sensor
-and MLX90632 is most suitable for consumer applications where measured object
-temperature is in range between -20 to 200 degrees Celsius with relative error
-of measurement below 1 degree Celsius in object temperature range for
-industrial applications. Since it can operate and measure ambient temperature
-in range of -20 to 85 degrees Celsius it is suitable also for outdoor use.
-
-Be aware that electronics surrounding the sensor can increase ambient
-temperature. MLX90632 can be calibrated to reduce the housing effect via
-already existing EEPROM parameters.
-
-Since measured object emissivity effects Infra Red energy emitted, emissivity
-should be set before requesting the object temperature.
-
-Required properties:
-  - compatible: should be "melexis,mlx90632"
-  - reg: the I2C address of the sensor (default 0x3a)
-
-Example:
-
-mlx90632@3a {
-	compatible = "melexis,mlx90632";
-	reg = <0x3a>;
-};
Signature · 1 line
2.28.0
Acked-by on v1 25/29
#53 lore raw

Re: [PATCH 25/29] dt-bindings:iio:temperature:melexis,mlx90632 conversion to yaml

Thanks for the conversion. No idea which tag to put, so:

Quoted 112 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Technically this could have gone in trivial-devices.yaml, but I have kept it as a separate binding due to the detailed additional description from the text file.

---
 .../iio/temperature/melexis,mlx90632.yaml     | 55 +++++++++++++++++++
 .../bindings/iio/temperature/mlx90632.txt     | 28 ----------
 2 files changed, 55 insertions(+), 28 deletions(-)
Documentation/devicetree/bindings/iio/temperature/melexis,mlx90632.yaml new file +55 -0
new file mode 100644
index 000000000000..b547ddcd544a
@@ -0,0 +1,55 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/temperature/melexis,mlx90632.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Melexis MLX90632 contactless Infra Red temperature sensor
+
+maintainers:
+  - Crt Mori <[email protected]>
+
+description: |
+  https://www.melexis.com/en/documents/documentation/datasheets/datasheet-mlx90632
+
+  There are various applications for the Infra Red contactless temperature
+  sensor and MLX90632 is most suitable for consumer applications where
+  measured object temperature is in range between -20 to 200 degrees
+  Celsius with relative error of measurement below 1 degree Celsius in
+  object temperature range for industrial applications. Since it can
+  operate and measure ambient temperature in range of -20 to 85 degrees
+  Celsius it is suitable also for outdoor use.
+
+  Be aware that electronics surrounding the sensor can increase ambient
+  temperature. MLX90632 can be calibrated to reduce the housing effect via
+  already existing EEPROM parameters.
+
+  Since measured object emissivity effects Infra Red energy emitted,
+  emissivity should be set before requesting the object temperature.
+
+properties:
+  compatible:
+    const: melexis,mlx90632
+
+  reg:
+    maxItems: 1
+    description: Default is 0x3a, but can be reprogrammed.
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        temp-sensor@3a {
+            compatible = "melexis,mlx90632";
+            reg = <0x3a>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/temperature/mlx90632.txt deleted +0 -29
deleted file mode 100644
index 0b05812001f8..000000000000
@@ -1,28 +0,0 @@
-* Melexis MLX90632 contactless Infra Red temperature sensor
-
-Link to datasheet: https://www.melexis.com/en/documents/documentation/datasheets/datasheet-mlx90632
-
-There are various applications for the Infra Red contactless temperature sensor
-and MLX90632 is most suitable for consumer applications where measured object
-temperature is in range between -20 to 200 degrees Celsius with relative error
-of measurement below 1 degree Celsius in object temperature range for
-industrial applications. Since it can operate and measure ambient temperature
-in range of -20 to 85 degrees Celsius it is suitable also for outdoor use.
-
-Be aware that electronics surrounding the sensor can increase ambient
-temperature. MLX90632 can be calibrated to reduce the housing effect via
-already existing EEPROM parameters.
-
-Since measured object emissivity effects Infra Red energy emitted, emissivity
-should be set before requesting the object temperature.
-
-Required properties:
-  - compatible: should be "melexis,mlx90632"
-  - reg: the I2C address of the sensor (default 0x3a)
-
-Example:
-
-mlx90632@3a {
-       compatible = "melexis,mlx90632";
-       reg = <0x3a>;
-};
--

2.28.0

author maintainer
#54 lore raw

PATCH 26/29 dt-bindings:iio:temperature:meas,tsys01 move to trivial-devices.yaml

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

The existing binding description brings little value and the similar meas,* parts are in trivial-devices.yaml so move this one there to join them.

Cc Manivannan Sadhasivam <[email protected]>
---
 .../bindings/iio/temperature/tsys01.txt       | 19 -------------------
 .../devicetree/bindings/trivial-devices.yaml  |  2 ++
 2 files changed, 2 insertions(+), 19 deletions(-)
Documentation/devicetree/bindings/iio/temperature/tsys01.txt deleted +0 -19
deleted file mode 100644
index 0d5cc5595d0c..000000000000
@@ -1,19 +0,0 @@
-* TSYS01 - Measurement Specialties temperature sensor
-
-Required properties:
-
-	- compatible: should be "meas,tsys01"
-	- reg: I2C address of the sensor (changeable via CSB pin)
-
-		------------------------
-		| CSB | Device Address |
-		------------------------
-		   1         0x76
-		   0	     0x77
-
-Example:
-
-tsys01@76 {
-	compatible = "meas,tsys01";
-	reg = <0x76>;
-};
Documentation/devicetree/bindings/trivial-devices.yaml +2 -0
index a8db256c2a93..6410fc0df435 100644
@@ -140,6 +140,8 @@ properties:
           - meas,ms8607-humidity
             # Measurement Specialities temp and pressure part of ms8607 device
           - meas,ms8607-temppressure
+            # Measurement Specialties temperature sensor
+          - meas,tsys01
             # Microchip differential I2C ADC, 1 Channel, 18 bit
           - microchip,mcp3421
             # Microchip differential I2C ADC, 2 Channel, 18 bit
Signature · 1 line
2.28.0
author maintainer
#55 lore raw

PATCH 27/29 dt-bindings:iio:temperature:maxim,max31856 yaml conversion.

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Simple txt to yaml conversion of this binding.

---
 .../bindings/iio/temperature/max31856.txt     | 24 ---------
 .../iio/temperature/maxim,max31856.yaml       | 54 +++++++++++++++++++
 2 files changed, 54 insertions(+), 24 deletions(-)
Documentation/devicetree/bindings/iio/temperature/max31856.txt deleted +0 -24
deleted file mode 100644
index 06ab43bb4de8..000000000000
@@ -1,24 +0,0 @@
-Maxim MAX31856 thermocouple support
-
-https://datasheets.maximintegrated.com/en/ds/MAX31856.pdf
-
-Optional property:
-	- thermocouple-type: Type of thermocouple (THERMOCOUPLE_TYPE_K if
-		omitted). Supported types are B, E, J, K, N, R, S, T.
-
-Required properties:
-	- compatible: must be "maxim,max31856"
-	- reg: SPI chip select number for the device
-	- spi-max-frequency: As per datasheet max. supported freq is 5000000
-	- spi-cpha: must be defined for max31856 to enable SPI mode 1
-
-	Refer to spi/spi-bus.txt for generic SPI slave bindings.
-
- Example:
-	temp-sensor@0 {
-		compatible = "maxim,max31856";
-		reg = <0>;
-		spi-max-frequency = <5000000>;
-		spi-cpha;
-		thermocouple-type = <THERMOCOUPLE_TYPE_K>;
-	};
Documentation/devicetree/bindings/iio/temperature/maxim,max31856.yaml new file +54 -0

54 lines not on this page · raw message

Signature · 1 line
2.28.0
author maintainer
#56 lore raw

PATCH 28/29 dt-bindings:iio:temperature:maxim_thermocouple.txt to maxim,max31855k.yaml

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Given we already have another maxim thermocouple driver that isn't covered by this binding it seems a better idea to chose to name it after a specific part.

I added an additional example for the maxim,max6755 to illustrate the need for spi-cpha for that part.

---
 .../iio/temperature/maxim,max31855k.yaml      | 76 +++++++++++++++++++
 .../iio/temperature/maxim_thermocouple.txt    | 24 ------
 2 files changed, 76 insertions(+), 24 deletions(-)
Documentation/devicetree/bindings/iio/temperature/maxim,max31855k.yaml new file +76 -0
new file mode 100644
index 000000000000..835e2d06b523
@@ -0,0 +1,76 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/temperature/maxim,max31855k.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Maxim MAX31855 and similar thermocouples
+
+maintainers:
+  - Matt Ranostay <[email protected]>
+
+description: |
+  https://datasheets.maximintegrated.com/en/ds/MAX6675.pdf
+  https://datasheets.maximintegrated.com/en/ds/MAX31855.pdf
+
+properties:
+  compatible:
+    description:
+      The generic maxim,max31855 compatible is deprecated in favour of
+      the thermocouple type specific varients.
+    enum:
+      - maxim,max6675
+      - maxim,max31855
+      - maxim,max31855k
+      - maxim,max31855j
+      - maxim,max31855n
+      - maxim,max31855s
+      - maxim,max31855t
+      - maxim,max31855e
+      - maxim,max31855r
+
+  reg:
+    maxItems: 1
+
+  spi-max-frequency: true
+  spi-cpha: true
+
+required:
+  - compatible
+  - reg
+
+allOf:
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - maxim,max6675
+    then:
+      required:
+        - spi-cpha
+    else:
+      properties:
+        spi-cpha: false
+
+additionalProperties: false
+
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        temp-sensor@0 {
+            compatible = "maxim,max31855k";
+            reg = <0>;
+            spi-max-frequency = <4300000>;
+        };
+        temp-sensor@1 {
+            compatible = "maxim,max6675";
+            reg = <1>;
+            spi-max-frequency = <4300000>;
+            spi-cpha;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/temperature/maxim_thermocouple.txt deleted +0 -24
deleted file mode 100644
index bb85cd0e039c..000000000000
@@ -1,24 +0,0 @@
-Maxim thermocouple support
-
-* https://datasheets.maximintegrated.com/en/ds/MAX6675.pdf
-* https://datasheets.maximintegrated.com/en/ds/MAX31855.pdf
-
-Required properties:
-
-	- compatible: must be "maxim,max6675" or one of the following:
-	   "maxim,max31855k", "maxim,max31855j", "maxim,max31855n",
-	   "maxim,max31855s", "maxim,max31855t", "maxim,max31855e",
-	   "maxim,max31855r"; the generic "max,max31855" is deprecated.
-	- reg: SPI chip select number for the device
-	- spi-max-frequency: must be 4300000
-	- spi-cpha: must be defined for max6675 to enable SPI mode 1
-
-	Refer to spi/spi-bus.txt for generic SPI slave bindings.
-
-Example:
-
-	max31855@0 {
-		compatible = "maxim,max31855k";
-		reg = <0>;
-		spi-max-frequency = <4300000>;
-	};
Signature · 1 line
2.28.0
Acked-by on v1 28/29
#57 lore raw

Re: [PATCH 28/29] dt-bindings:iio:temperature:maxim_thermocouple.txt to maxim,max31855k.yaml

Quoted 33 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Given we already have another maxim thermocouple driver that isn't covered by this binding it seems a better idea to chose to name it after a specific part.

I added an additional example for the maxim,max6755 to illustrate the need for spi-cpha for that part.

---
 .../iio/temperature/maxim,max31855k.yaml      | 76 +++++++++++++++++++
 .../iio/temperature/maxim_thermocouple.txt    | 24 ------
 2 files changed, 76 insertions(+), 24 deletions(-)
Documentation/devicetree/bindings/iio/temperature/maxim,max31855k.yaml new file +10 -0
new file mode 100644
index 000000000000..835e2d06b523
@@ -0,0 +1,76 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/temperature/maxim,max31855k.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Maxim MAX31855 and similar thermocouples
+
+maintainers:
+  - Matt Ranostay <[email protected]>

Documentation/devicetree/bindings/iio/temperature/maxim,max31855k.yaml line 20

Quoted 10 lines
Documentation/devicetree/bindings/iio/temperature/maxim,max31855k.yaml new file +10 -0
+
+description: |
+  https://datasheets.maximintegrated.com/en/ds/MAX6675.pdf
+  https://datasheets.maximintegrated.com/en/ds/MAX31855.pdf
+
+properties:
+  compatible:
+    description:
+      The generic maxim,max31855 compatible is deprecated in favour of
+      the thermocouple type specific varients.

Typo of "variants"

Otherwise looks good to me.

Quoted 89 lines
Documentation/devicetree/bindings/iio/temperature/maxim,max31855k.yaml new file +56 -0
+    enum:
+      - maxim,max6675
+      - maxim,max31855
+      - maxim,max31855k
+      - maxim,max31855j
+      - maxim,max31855n
+      - maxim,max31855s
+      - maxim,max31855t
+      - maxim,max31855e
+      - maxim,max31855r
+
+  reg:
+    maxItems: 1
+
+  spi-max-frequency: true
+  spi-cpha: true
+
+required:
+  - compatible
+  - reg
+
+allOf:
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - maxim,max6675
+    then:
+      required:
+        - spi-cpha
+    else:
+      properties:
+        spi-cpha: false
+
+additionalProperties: false
+
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        temp-sensor@0 {
+            compatible = "maxim,max31855k";
+            reg = <0>;
+            spi-max-frequency = <4300000>;
+        };
+        temp-sensor@1 {
+            compatible = "maxim,max6675";
+            reg = <1>;
+            spi-max-frequency = <4300000>;
+            spi-cpha;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/temperature/maxim_thermocouple.txt deleted +0 -25
deleted file mode 100644
index bb85cd0e039c..000000000000
@@ -1,24 +0,0 @@
-Maxim thermocouple support
-
-* https://datasheets.maximintegrated.com/en/ds/MAX6675.pdf
-* https://datasheets.maximintegrated.com/en/ds/MAX31855.pdf
-
-Required properties:
-
-       - compatible: must be "maxim,max6675" or one of the following:
-          "maxim,max31855k", "maxim,max31855j", "maxim,max31855n",
-          "maxim,max31855s", "maxim,max31855t", "maxim,max31855e",
-          "maxim,max31855r"; the generic "max,max31855" is deprecated.
-       - reg: SPI chip select number for the device
-       - spi-max-frequency: must be 4300000
-       - spi-cpha: must be defined for max6675 to enable SPI mode 1
-
-       Refer to spi/spi-bus.txt for generic SPI slave bindings.
-
-Example:
-
-       max31855@0 {
-               compatible = "maxim,max31855k";
-               reg = <0>;
-               spi-max-frequency = <4300000>;
-       };
--

2.28.0

author maintainer
#58 lore raw

PATCH 29/29 dt-bindings:iio:temperature:ti,tmp07 yaml conversion

In reply to Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Simple conversion from txt to yaml.

Cc Manivannan Sadhasivam <[email protected]>
---
 .../bindings/iio/temperature/ti,tmp007.yaml   | 57 +++++++++++++++++++
 .../bindings/iio/temperature/tmp007.txt       | 33 -----------
 2 files changed, 57 insertions(+), 33 deletions(-)
Documentation/devicetree/bindings/iio/temperature/ti,tmp007.yaml new file +57 -0
new file mode 100644
index 000000000000..3c2b7189fa2e
@@ -0,0 +1,57 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/temperature/ti,tmp007.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: IR thermopile sensor with integrated math engine
+
+maintainers:
+  - Manivannan Sadhasivam <[email protected]>
+
+description: |
+  http://www.ti.com/lit/ds/symlink/tmp007.pdf
+
+properties:
+  compatible:
+    const: ti,tmp007
+
+  reg:
+    description: |
+      The I2C address of the sensor (changeable via ADR pins)
+      ------------------------------
+      |ADR1 | ADR0 | Device Address|
+      ------------------------------
+         0      0        0x40
+         0      1        0x41
+         0     SDA       0x42
+         0     SCL       0x43
+         1      0        0x44
+         1      1        0x45
+         1     SDA       0x46
+         1     SCL       0x47
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        temp-sensor@40 {
+            compatible = "ti,tmp007";
+            reg = <0x40>;
+            interrupt-parent = <&gpio0>;
+            interrupts = <5 0x08>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/temperature/tmp007.txt deleted +0 -33
deleted file mode 100644
index da0af234a357..000000000000
@@ -1,33 +0,0 @@
-* TI TMP007 - IR thermopile sensor with integrated math engine
-
-Link to datasheet: http://www.ti.com/lit/ds/symlink/tmp007.pdf
-
-Required properties:
-
-  - compatible: should be "ti,tmp007"
-  - reg: the I2C address of the sensor (changeable via ADR pins)
-		------------------------------
-		|ADR1 | ADR0 | Device Address|
-		------------------------------
-		   0      0        0x40
-		   0	  1	   0x41
-		   0	 SDA       0x42
-		   0     SCL       0x43
-		   1      0        0x44
-		   1      1        0x45
-		   1	 SDA	   0x46
-		   1     SCL       0x47
-
-Optional properties:
-
-  - interrupts: interrupt mapping for GPIO IRQ (level active low)
-
-Example:
-
-tmp007@40 {
-        compatible = "ti,tmp007";
-        reg = <0x40>;
-	interrupt-parent = <&gpio0>;
-	interrupts = <5 0x08>;
-};
-
Signature · 1 line
2.28.0
Acked-by on v1 29/29
#59 lore raw

Re: [PATCH 29/29] dt-bindings:iio:temperature:ti,tmp07 yaml conversion

Quoted 6 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

Simple conversion from txt to yaml.

Cc Manivannan Sadhasivam <[email protected]>

Thanks,
Mani

Quoted 110 lines
---
 .../bindings/iio/temperature/ti,tmp007.yaml   | 57 +++++++++++++++++++
 .../bindings/iio/temperature/tmp007.txt       | 33 -----------
 2 files changed, 57 insertions(+), 33 deletions(-)
Documentation/devicetree/bindings/iio/temperature/ti,tmp007.yaml new file +57 -0
new file mode 100644
index 000000000000..3c2b7189fa2e
@@ -0,0 +1,57 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/temperature/ti,tmp007.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: IR thermopile sensor with integrated math engine
+
+maintainers:
+  - Manivannan Sadhasivam <[email protected]>
+
+description: |
+  http://www.ti.com/lit/ds/symlink/tmp007.pdf
+
+properties:
+  compatible:
+    const: ti,tmp007
+
+  reg:
+    description: |
+      The I2C address of the sensor (changeable via ADR pins)
+      ------------------------------
+      |ADR1 | ADR0 | Device Address|
+      ------------------------------
+         0      0        0x40
+         0      1        0x41
+         0     SDA       0x42
+         0     SCL       0x43
+         1      0        0x44
+         1      1        0x45
+         1     SDA       0x46
+         1     SCL       0x47
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        temp-sensor@40 {
+            compatible = "ti,tmp007";
+            reg = <0x40>;
+            interrupt-parent = <&gpio0>;
+            interrupts = <5 0x08>;
+        };
+    };
+...
Documentation/devicetree/bindings/iio/temperature/tmp007.txt deleted +0 -33
deleted file mode 100644
index da0af234a357..000000000000
@@ -1,33 +0,0 @@
-* TI TMP007 - IR thermopile sensor with integrated math engine
-
-Link to datasheet: http://www.ti.com/lit/ds/symlink/tmp007.pdf
-
-Required properties:
-
-  - compatible: should be "ti,tmp007"
-  - reg: the I2C address of the sensor (changeable via ADR pins)
-		------------------------------
-		|ADR1 | ADR0 | Device Address|
-		------------------------------
-		   0      0        0x40
-		   0	  1	   0x41
-		   0	 SDA       0x42
-		   0     SCL       0x43
-		   1      0        0x44
-		   1      1        0x45
-		   1	 SDA	   0x46
-		   1     SCL       0x47
-
-Optional properties:
-
-  - interrupts: interrupt mapping for GPIO IRQ (level active low)
-
-Example:
-
-tmp007@40 {
-        compatible = "ti,tmp007";
-        reg = <0x40>;
-	interrupt-parent = <&gpio0>;
-	interrupts = <5 0x08>;
-};
-
Signature · 1 line
2.28.0
Reviewed-by on the v1 series
#60 lore raw
In reply to Jonathan Cameron
Quoted 52 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

This set mostly consists of low hanging fruit along the way to converting all the existing IIO bindings.

A few questions scattered throughout though. Whilst my skills in these are hopefully improving it seems there are still plenty more corner cases that I'm not sure how to handle! I'm sure I'll have forgotten something that I should already know as well.

I'm expecting some of these to bounce due to changes of addresses etc. If I can't track down up to date emails, I'll switch them maintainer to myself on the basis I'll be reviewing any incoming changes for these anyway.

Thanks,

Jonathan

Jonathan Cameron (29):
dt-bindings:iio:humidity:hdc100x Drop separate doc + add to
trivial-devices
dt-bindings:iio:humidity:htu21 Drop separate doc + add to
trivial-devices
dt-bindings:iio:humidity:st,hts221 yaml conversion. dt-bindings:iio:humidity:dht11 yaml conversion dt-bindings:iio:pressure:ms5637 Drop separate doc + add to
trivial-devices
dt-bindings:iio:pressure:murata,zpa2326 yaml conversion dt-bindings:iio:pressure:meas,ms5611 yaml conversion. dt-bindings:iio:pressure:hoperf,hp03 yaml conversion dt-bindings:iio:proximity:semtech,sx9500 yaml conversion. dt-bindings:iio:proximity:st,vl53l0x yaml conversion dt-bindings:iio:proximity:ams,as3935 yaml conversion dt-bindings:iio:dac:ti,dac5571 yaml conversion. dt-bindings:iio:dac:ti,dac7311 yaml conversion dt-bindings:iio:dac:ti,dac7512 yaml conversion dt-bindings:iio:dac:ti,dac7612 yaml conversion dt-bindings:iio:dac:ti,dac082s085 yaml conversion dt-bindings:iio:dac:adi,ad7303 yaml conversion dt-bindings:iio:dac:maxim,ds4424 yaml conversion dt-bindings:iio:dac:fsl,vf610-dac yaml conversion dt-bindings:iio:dac:microchip,mcp4725 yaml conversion dt-bindings:iio:dac:maxim,max5821 yaml conversion dt-bindings:iio:dac:nxp,lpc1850-dac yaml conversion. dt-bindings:iio:dac:adi,ad5758 yaml conversion dt-bindings:iio:temperature:melexis,mlx90614 yaml conversion dt-bindings:iio:temperature:melexis,mlx90632 conversion to yaml dt-bindings:iio:temperature:meas,tsys01 move to trivial-devices.yaml dt-bindings:iio:temperature:maxim,max31856 yaml conversion. dt-bindings:iio:temperature:maxim_thermocouple.txt to

Quoted 2 lines
    maxim,max31855k.yaml

dt-bindings:iio:temperature:ti,tmp07 yaml conversion

For the series,

Though, you didn't Cc the DT list so no semi-automated checks will run which would have pointed out the problem Lars-Peter did.

Rob

#61 lore raw
Quoted 56 lines · On Mon, 12 Oct 2020 08:20:12 -0500 Rob Herring <[email protected]> wrote:
Quoted 52 lines · Jonathan Cameron

From: Jonathan Cameron <[email protected]>

This set mostly consists of low hanging fruit along the way to converting all the existing IIO bindings.

A few questions scattered throughout though. Whilst my skills in these are hopefully improving it seems there are still plenty more corner cases that I'm not sure how to handle! I'm sure I'll have forgotten something that I should already know as well.

I'm expecting some of these to bounce due to changes of addresses etc. If I can't track down up to date emails, I'll switch them maintainer to myself on the basis I'll be reviewing any incoming changes for these anyway.

Thanks,

Jonathan

Jonathan Cameron (29):
dt-bindings:iio:humidity:hdc100x Drop separate doc + add to
trivial-devices
dt-bindings:iio:humidity:htu21 Drop separate doc + add to
trivial-devices
dt-bindings:iio:humidity:st,hts221 yaml conversion. dt-bindings:iio:humidity:dht11 yaml conversion dt-bindings:iio:pressure:ms5637 Drop separate doc + add to
trivial-devices
dt-bindings:iio:pressure:murata,zpa2326 yaml conversion dt-bindings:iio:pressure:meas,ms5611 yaml conversion. dt-bindings:iio:pressure:hoperf,hp03 yaml conversion dt-bindings:iio:proximity:semtech,sx9500 yaml conversion. dt-bindings:iio:proximity:st,vl53l0x yaml conversion dt-bindings:iio:proximity:ams,as3935 yaml conversion dt-bindings:iio:dac:ti,dac5571 yaml conversion. dt-bindings:iio:dac:ti,dac7311 yaml conversion dt-bindings:iio:dac:ti,dac7512 yaml conversion dt-bindings:iio:dac:ti,dac7612 yaml conversion dt-bindings:iio:dac:ti,dac082s085 yaml conversion dt-bindings:iio:dac:adi,ad7303 yaml conversion dt-bindings:iio:dac:maxim,ds4424 yaml conversion dt-bindings:iio:dac:fsl,vf610-dac yaml conversion dt-bindings:iio:dac:microchip,mcp4725 yaml conversion dt-bindings:iio:dac:maxim,max5821 yaml conversion dt-bindings:iio:dac:nxp,lpc1850-dac yaml conversion. dt-bindings:iio:dac:adi,ad5758 yaml conversion dt-bindings:iio:temperature:melexis,mlx90614 yaml conversion dt-bindings:iio:temperature:melexis,mlx90632 conversion to yaml dt-bindings:iio:temperature:meas,tsys01 move to trivial-devices.yaml dt-bindings:iio:temperature:maxim,max31856 yaml conversion. dt-bindings:iio:temperature:maxim_thermocouple.txt to

Quoted 2 lines
    maxim,max31855k.yaml

dt-bindings:iio:temperature:ti,tmp07 yaml conversion

Quoted 6 lines

For the series,

Though, you didn't Cc the DT list so no semi-automated checks will run which would have pointed out the problem Lars-Peter did.

Gah. Sorry about that. I'll pick up acks and do a v2 which I'll make sure goes to the list, as we aren't in a particular rush for these.

Thanks,

Jonathan

Quoted 2 lines

Rob