diff mbox series

[v2,1/2] dt-bindings: iio: humidity: Add si7020 bindings

Message ID 20220512162020.33450-2-eajames@linux.ibm.com (mailing list archive)
State Changes Requested
Headers show
Series iio: humidity: si7020: Check device property for skipping reset in probe | expand

Commit Message

Eddie James May 12, 2022, 4:20 p.m. UTC
Document the si7020 bindings with a new "silabs,skip-reset" property.

Signed-off-by: Eddie James <eajames@linux.ibm.com>
---
 .../bindings/iio/humidity/silabs,si7020.yaml  | 47 +++++++++++++++++++
 .../devicetree/bindings/trivial-devices.yaml  |  2 -
 2 files changed, 47 insertions(+), 2 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml

Comments

Jonathan Cameron May 12, 2022, 4:51 p.m. UTC | #1
On Thu, 12 May 2022 11:20:19 -0500
Eddie James <eajames@linux.ibm.com> wrote:

> Document the si7020 bindings with a new "silabs,skip-reset" property.
> 
> Signed-off-by: Eddie James <eajames@linux.ibm.com>
> ---
>  .../bindings/iio/humidity/silabs,si7020.yaml  | 47 +++++++++++++++++++
>  .../devicetree/bindings/trivial-devices.yaml  |  2 -
>  2 files changed, 47 insertions(+), 2 deletions(-)
>  create mode 100644 Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml
> 
> diff --git a/Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml b/Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml
> new file mode 100644
> index 000000000000..9bee010f8d56
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml
> @@ -0,0 +1,47 @@
> +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/iio/humidity/silabs,si7020.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: SI7020 humidity + temperature sensor
> +
> +maintainers:
> +  - David Barksdale <dbarksdale@uplogix.com>

At least cc David if you are going to commit him to maintaining this binding :)
+CC David at that address.

> +
> +description: |
> +   The Silicon Labs Si7013/20/21 Relative Humidity and Temperature Sensors
> +   are i2c devices which have an identical programming interface for
> +   measuring relative humidity and temperature.
> +
> +properties:
> +  compatible:
> +    const: silabs,si7020
> +
> +  reg:
> +    maxItems: 1
> +
> +  siliabs,skip-reset:
> +    $ref: /schemas/types.yaml#/definitions/flag
> +    description:
> +      Disables resetting of the device during probe
> +
> +required:
> +  - compatible
> +  - reg
> +
> +additionalProperties: false
> +
> +examples:
> +  - |
> +    i2c0 {
> +      #address-cells = <1>;
> +      #size-cells = <0>;
> +
> +      si7021-a20@40 {
> +        silabs,skip-reset;
> +        compatible = "silabs,si7020";
> +        reg = <0x40>;
> +      };
> +    };
> +...
> diff --git a/Documentation/devicetree/bindings/trivial-devices.yaml b/Documentation/devicetree/bindings/trivial-devices.yaml
> index e5295faef52f..47a00b478867 100644
> --- a/Documentation/devicetree/bindings/trivial-devices.yaml
> +++ b/Documentation/devicetree/bindings/trivial-devices.yaml
> @@ -317,8 +317,6 @@ properties:
>            - sensortek,stk8ba50
>              # SGX Sensortech VZ89X Sensors
>            - sgx,vz89x
> -            # Relative Humidity and Temperature Sensors
> -          - silabs,si7020
>              # Skyworks SKY81452: Six-Channel White LED Driver with Touch Panel Bias Supply
>            - skyworks,sky81452
>              # Socionext SynQuacer TPM MMIO module
Eddie James May 12, 2022, 5:08 p.m. UTC | #2
On 5/12/22 11:51, Jonathan Cameron wrote:
> On Thu, 12 May 2022 11:20:19 -0500
> Eddie James <eajames@linux.ibm.com> wrote:
>
>> Document the si7020 bindings with a new "silabs,skip-reset" property.
>>
>> Signed-off-by: Eddie James <eajames@linux.ibm.com>
>> ---
>>   .../bindings/iio/humidity/silabs,si7020.yaml  | 47 +++++++++++++++++++
>>   .../devicetree/bindings/trivial-devices.yaml  |  2 -
>>   2 files changed, 47 insertions(+), 2 deletions(-)
>>   create mode 100644 Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml
>>
>> diff --git a/Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml b/Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml
>> new file mode 100644
>> index 000000000000..9bee010f8d56
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml
>> @@ -0,0 +1,47 @@
>> +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
>> +%YAML 1.2
>> +---
>> +$id: http://devicetree.org/schemas/iio/humidity/silabs,si7020.yaml#
>> +$schema: http://devicetree.org/meta-schemas/core.yaml#
>> +
>> +title: SI7020 humidity + temperature sensor
>> +
>> +maintainers:
>> +  - David Barksdale <dbarksdale@uplogix.com>
> At least cc David if you are going to commit him to maintaining this binding :)
> +CC David at that address.


Yes, my mail to him for v1 was undeliverable... I guess I should put 
myself instead.


>
>> +
>> +description: |
>> +   The Silicon Labs Si7013/20/21 Relative Humidity and Temperature Sensors
>> +   are i2c devices which have an identical programming interface for
>> +   measuring relative humidity and temperature.
>> +
>> +properties:
>> +  compatible:
>> +    const: silabs,si7020
>> +
>> +  reg:
>> +    maxItems: 1
>> +
>> +  siliabs,skip-reset:
>> +    $ref: /schemas/types.yaml#/definitions/flag
>> +    description:
>> +      Disables resetting of the device during probe
>> +
>> +required:
>> +  - compatible
>> +  - reg
>> +
>> +additionalProperties: false
>> +
>> +examples:
>> +  - |
>> +    i2c0 {
>> +      #address-cells = <1>;
>> +      #size-cells = <0>;
>> +
>> +      si7021-a20@40 {
>> +        silabs,skip-reset;
>> +        compatible = "silabs,si7020";
>> +        reg = <0x40>;
>> +      };
>> +    };
>> +...
>> diff --git a/Documentation/devicetree/bindings/trivial-devices.yaml b/Documentation/devicetree/bindings/trivial-devices.yaml
>> index e5295faef52f..47a00b478867 100644
>> --- a/Documentation/devicetree/bindings/trivial-devices.yaml
>> +++ b/Documentation/devicetree/bindings/trivial-devices.yaml
>> @@ -317,8 +317,6 @@ properties:
>>             - sensortek,stk8ba50
>>               # SGX Sensortech VZ89X Sensors
>>             - sgx,vz89x
>> -            # Relative Humidity and Temperature Sensors
>> -          - silabs,si7020
>>               # Skyworks SKY81452: Six-Channel White LED Driver with Touch Panel Bias Supply
>>             - skyworks,sky81452
>>               # Socionext SynQuacer TPM MMIO module
Krzysztof Kozlowski May 13, 2022, 8:55 a.m. UTC | #3
On 12/05/2022 18:20, Eddie James wrote:
> Document the si7020 bindings with a new "silabs,skip-reset" property.
> 
> Signed-off-by: Eddie James <eajames@linux.ibm.com>
> ---
>  .../bindings/iio/humidity/silabs,si7020.yaml  | 47 +++++++++++++++++++
>  .../devicetree/bindings/trivial-devices.yaml  |  2 -
>  2 files changed, 47 insertions(+), 2 deletions(-)
>  create mode 100644 Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml
> 
> diff --git a/Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml b/Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml
> new file mode 100644
> index 000000000000..9bee010f8d56
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml
> @@ -0,0 +1,47 @@
> +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/iio/humidity/silabs,si7020.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: SI7020 humidity + temperature sensor
> +
> +maintainers:
> +  - David Barksdale <dbarksdale@uplogix.com>
> +
> +description: |
> +   The Silicon Labs Si7013/20/21 Relative Humidity and Temperature Sensors
> +   are i2c devices which have an identical programming interface for
> +   measuring relative humidity and temperature.
> +
> +properties:
> +  compatible:
> +    const: silabs,si7020
> +
> +  reg:
> +    maxItems: 1
> +
> +  siliabs,skip-reset:
> +    $ref: /schemas/types.yaml#/definitions/flag
> +    description:
> +      Disables resetting of the device during probe
> +
> +required:
> +  - compatible
> +  - reg
> +
> +additionalProperties: false
> +
> +examples:
> +  - |
> +    i2c0 {
> +      #address-cells = <1>;
> +      #size-cells = <0>;
> +
> +      si7021-a20@40 {

Same comments as your v1. Generic node name, wrong property skip-reset
(implementation specific) and so on...

Give some time for review, before resending.


Best regards,
Krzysztof
Jonathan Cameron May 13, 2022, 4:47 p.m. UTC | #4
On Thu, 12 May 2022 12:08:57 -0500
Eddie James <eajames@linux.ibm.com> wrote:

> On 5/12/22 11:51, Jonathan Cameron wrote:
> > On Thu, 12 May 2022 11:20:19 -0500
> > Eddie James <eajames@linux.ibm.com> wrote:
> >  
> >> Document the si7020 bindings with a new "silabs,skip-reset" property.
> >>
> >> Signed-off-by: Eddie James <eajames@linux.ibm.com>
> >> ---
> >>   .../bindings/iio/humidity/silabs,si7020.yaml  | 47 +++++++++++++++++++
> >>   .../devicetree/bindings/trivial-devices.yaml  |  2 -
> >>   2 files changed, 47 insertions(+), 2 deletions(-)
> >>   create mode 100644 Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml
> >>
> >> diff --git a/Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml b/Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml
> >> new file mode 100644
> >> index 000000000000..9bee010f8d56
> >> --- /dev/null
> >> +++ b/Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml
> >> @@ -0,0 +1,47 @@
> >> +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
> >> +%YAML 1.2
> >> +---
> >> +$id: http://devicetree.org/schemas/iio/humidity/silabs,si7020.yaml#
> >> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> >> +
> >> +title: SI7020 humidity + temperature sensor
> >> +
> >> +maintainers:
> >> +  - David Barksdale <dbarksdale@uplogix.com>  
> > At least cc David if you are going to commit him to maintaining this binding :)
> > +CC David at that address.  
> 
> 
> Yes, my mail to him for v1 was undeliverable... I guess I should put 
> myself instead.
> 

That's the best answer :)
(backup is to rely on the fallback which is me but I'd definitely rather bindings
had attentive maintainers where possible!).

> 
> >  
> >> +
> >> +description: |
> >> +   The Silicon Labs Si7013/20/21 Relative Humidity and Temperature Sensors
> >> +   are i2c devices which have an identical programming interface for
> >> +   measuring relative humidity and temperature.
> >> +
> >> +properties:
> >> +  compatible:
> >> +    const: silabs,si7020
> >> +
> >> +  reg:
> >> +    maxItems: 1
> >> +
> >> +  siliabs,skip-reset:
> >> +    $ref: /schemas/types.yaml#/definitions/flag
> >> +    description:
> >> +      Disables resetting of the device during probe
> >> +
> >> +required:
> >> +  - compatible
> >> +  - reg
> >> +
> >> +additionalProperties: false
> >> +
> >> +examples:
> >> +  - |
> >> +    i2c0 {
> >> +      #address-cells = <1>;
> >> +      #size-cells = <0>;
> >> +
> >> +      si7021-a20@40 {
> >> +        silabs,skip-reset;
> >> +        compatible = "silabs,si7020";
> >> +        reg = <0x40>;
> >> +      };
> >> +    };
> >> +...
> >> diff --git a/Documentation/devicetree/bindings/trivial-devices.yaml b/Documentation/devicetree/bindings/trivial-devices.yaml
> >> index e5295faef52f..47a00b478867 100644
> >> --- a/Documentation/devicetree/bindings/trivial-devices.yaml
> >> +++ b/Documentation/devicetree/bindings/trivial-devices.yaml
> >> @@ -317,8 +317,6 @@ properties:
> >>             - sensortek,stk8ba50
> >>               # SGX Sensortech VZ89X Sensors
> >>             - sgx,vz89x
> >> -            # Relative Humidity and Temperature Sensors
> >> -          - silabs,si7020
> >>               # Skyworks SKY81452: Six-Channel White LED Driver with Touch Panel Bias Supply
> >>             - skyworks,sky81452
> >>               # Socionext SynQuacer TPM MMIO module
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml b/Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml
new file mode 100644
index 000000000000..9bee010f8d56
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/humidity/silabs,si7020.yaml
@@ -0,0 +1,47 @@ 
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/humidity/silabs,si7020.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: SI7020 humidity + temperature sensor
+
+maintainers:
+  - David Barksdale <dbarksdale@uplogix.com>
+
+description: |
+   The Silicon Labs Si7013/20/21 Relative Humidity and Temperature Sensors
+   are i2c devices which have an identical programming interface for
+   measuring relative humidity and temperature.
+
+properties:
+  compatible:
+    const: silabs,si7020
+
+  reg:
+    maxItems: 1
+
+  siliabs,skip-reset:
+    $ref: /schemas/types.yaml#/definitions/flag
+    description:
+      Disables resetting of the device during probe
+
+required:
+  - compatible
+  - reg
+
+additionalProperties: false
+
+examples:
+  - |
+    i2c0 {
+      #address-cells = <1>;
+      #size-cells = <0>;
+
+      si7021-a20@40 {
+        silabs,skip-reset;
+        compatible = "silabs,si7020";
+        reg = <0x40>;
+      };
+    };
+...
diff --git a/Documentation/devicetree/bindings/trivial-devices.yaml b/Documentation/devicetree/bindings/trivial-devices.yaml
index e5295faef52f..47a00b478867 100644
--- a/Documentation/devicetree/bindings/trivial-devices.yaml
+++ b/Documentation/devicetree/bindings/trivial-devices.yaml
@@ -317,8 +317,6 @@  properties:
           - sensortek,stk8ba50
             # SGX Sensortech VZ89X Sensors
           - sgx,vz89x
-            # Relative Humidity and Temperature Sensors
-          - silabs,si7020
             # Skyworks SKY81452: Six-Channel White LED Driver with Touch Panel Bias Supply
           - skyworks,sky81452
             # Socionext SynQuacer TPM MMIO module