diff mbox series

[v4,03/10] dt-bindings: media: rkisp1: document different irq possibilities

Message ID 20210616215211.4002992-4-heiko@sntech.de
State New
Headers show
Series rkisp1 support for px30 | expand

Commit Message

Heiko Stuebner June 16, 2021, 9:52 p.m. UTC
From: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>

Some variants have one irq signaling all of MI, MIPI and ISP events
while some rkisp1 variants use separate irqs for each.

Adapt the binding to handle both cases.

Signed-off-by: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>
---
 .../devicetree/bindings/media/rockchip-isp1.yaml         | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

Comments

Dafna Hirschfeld June 17, 2021, 7:17 a.m. UTC | #1
Hi,

On 17.06.21 00:52, Heiko Stuebner wrote:
> From: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>
> 
> Some variants have one irq signaling all of MI, MIPI and ISP events
> while some rkisp1 variants use separate irqs for each.
> 
> Adapt the binding to handle both cases.
> 
> Signed-off-by: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>
> ---
>   .../devicetree/bindings/media/rockchip-isp1.yaml         | 9 ++++++++-
>   1 file changed, 8 insertions(+), 1 deletion(-)
> 
> diff --git a/Documentation/devicetree/bindings/media/rockchip-isp1.yaml b/Documentation/devicetree/bindings/media/rockchip-isp1.yaml
> index 2f8f0625d22e..80709a01c6fd 100644
> --- a/Documentation/devicetree/bindings/media/rockchip-isp1.yaml
> +++ b/Documentation/devicetree/bindings/media/rockchip-isp1.yaml
> @@ -21,7 +21,14 @@ properties:
>       maxItems: 1
>   
>     interrupts:
> -    maxItems: 1
> +    minItems: 1
> +    maxItems: 3
> +
> +  interrupt-names:
> +    items:
> +      - const: isp
> +      - const: mi
> +      - const: mipi

Since you use those names in the driver they should probably be 'required' you should do something like:

if:
   properties:
     compatible:
       contains:
         const: the-new-px30-compat..
then:
   required:
     - interrupt-names

would also be nice to add your new bindings in the example in the yaml

Thanks,
Dafna

>   
>     clocks:
>       minItems: 3
>
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/media/rockchip-isp1.yaml b/Documentation/devicetree/bindings/media/rockchip-isp1.yaml
index 2f8f0625d22e..80709a01c6fd 100644
--- a/Documentation/devicetree/bindings/media/rockchip-isp1.yaml
+++ b/Documentation/devicetree/bindings/media/rockchip-isp1.yaml
@@ -21,7 +21,14 @@  properties:
     maxItems: 1
 
   interrupts:
-    maxItems: 1
+    minItems: 1
+    maxItems: 3
+
+  interrupt-names:
+    items:
+      - const: isp
+      - const: mi
+      - const: mipi
 
   clocks:
     minItems: 3