diff mbox series

[RESEND,v3,2/3] dt-bindings: iio: gyro: adxrs290: Add interrupts support

Message ID 20200910180450.29696-3-nish.malpani25@gmail.com
State New
Headers show
Series iio: gyro: adxrs290: Add triggered buffer & debugfs support | expand

Commit Message

Nishant Malpani Sept. 10, 2020, 6:04 p.m. UTC
Include 'interrupts' property and provide a suitable example for using
a GPIO interrupt line.

Signed-off-by: Nishant Malpani <nish.malpani25@gmail.com>
---

Changes in v3:
  - remove gpio.h header since unused

Changes in v2:

  - remove 'interrupts' property from the required properties list
  - rewrite commit message
---
 .../devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml     | 6 ++++++
 1 file changed, 6 insertions(+)

Comments

Jonathan Cameron Sept. 13, 2020, 9:54 a.m. UTC | #1
On Thu, 10 Sep 2020 23:34:49 +0530
Nishant Malpani <nish.malpani25@gmail.com> wrote:

> Include 'interrupts' property and provide a suitable example for using
> a GPIO interrupt line.
> 
> Signed-off-by: Nishant Malpani <nish.malpani25@gmail.com>
This one is 'so trivial' (famous last words) that I'm not going
to wait for Rob H to get to it.  Obviously anything Rob wants to add
will be most welcome and might beat me pushing this out as non rebasing.

Applied to the togreg branch of iio.git.

Thanks,
Jonathan

> ---
> 
> Changes in v3:
>   - remove gpio.h header since unused
> 
> Changes in v2:
> 
>   - remove 'interrupts' property from the required properties list
>   - rewrite commit message
> ---
>  .../devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml     | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml b/Documentation/devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml
> index 61adb2c2454b..662ec59ca0af 100644
> --- a/Documentation/devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml
> +++ b/Documentation/devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml
> @@ -28,6 +28,9 @@ properties:
>  
>    spi-cpha: true
>  
> +  interrupts:
> +    maxItems: 1
> +
>  required:
>    - compatible
>    - reg
> @@ -39,6 +42,7 @@ additionalProperties: false
>  
>  examples:
>    - |
> +    #include <dt-bindings/interrupt-controller/irq.h>
>      spi {
>          #address-cells = <1>;
>          #size-cells = <0>;
> @@ -48,6 +52,8 @@ examples:
>                     spi-max-frequency = <5000000>;
>                     spi-cpol;
>                     spi-cpha;
> +                   interrupt-parent = <&gpio>;
> +                   interrupts = <25 IRQ_TYPE_EDGE_RISING>;
>          };
>      };
>  ...
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml b/Documentation/devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml
index 61adb2c2454b..662ec59ca0af 100644
--- a/Documentation/devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml
+++ b/Documentation/devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml
@@ -28,6 +28,9 @@  properties:
 
   spi-cpha: true
 
+  interrupts:
+    maxItems: 1
+
 required:
   - compatible
   - reg
@@ -39,6 +42,7 @@  additionalProperties: false
 
 examples:
   - |
+    #include <dt-bindings/interrupt-controller/irq.h>
     spi {
         #address-cells = <1>;
         #size-cells = <0>;
@@ -48,6 +52,8 @@  examples:
                    spi-max-frequency = <5000000>;
                    spi-cpol;
                    spi-cpha;
+                   interrupt-parent = <&gpio>;
+                   interrupts = <25 IRQ_TYPE_EDGE_RISING>;
         };
     };
 ...