diff mbox series

[v4,09/11] media: dt-bindings: Make sure items in data-lanes are unique

Message ID 20210915120240.21572-10-p.yadav@ti.com
State Superseded
Headers show
Series CSI2RX support on J721E | expand

Commit Message

Pratyush Yadav Sept. 15, 2021, 12:02 p.m. UTC
The data-lanes property maps the logical lane numbers to the physical
lane numbers. The position of an entry is the logical lane number and
its value is the physical lane number. Since one physical lane can only
map to one logical lane, no number in the list should repeat. Add the
uniqueItems constraint on the property to enforce this.

Signed-off-by: Pratyush Yadav <p.yadav@ti.com>

---

Changes in v4:
- New in v4.

 Documentation/devicetree/bindings/media/video-interfaces.yaml | 1 +
 1 file changed, 1 insertion(+)

Comments

Rob Herring (Arm) Sept. 21, 2021, 9:31 p.m. UTC | #1
On Wed, 15 Sep 2021 17:32:38 +0530, Pratyush Yadav wrote:
> The data-lanes property maps the logical lane numbers to the physical

> lane numbers. The position of an entry is the logical lane number and

> its value is the physical lane number. Since one physical lane can only

> map to one logical lane, no number in the list should repeat. Add the

> uniqueItems constraint on the property to enforce this.

> 

> Signed-off-by: Pratyush Yadav <p.yadav@ti.com>

> 

> ---

> 

> Changes in v4:

> - New in v4.

> 

>  Documentation/devicetree/bindings/media/video-interfaces.yaml | 1 +

>  1 file changed, 1 insertion(+)

> 


Acked-by: Rob Herring <robh@kernel.org>
Laurent Pinchart Oct. 6, 2021, 11:47 p.m. UTC | #2
Hi Pratyush,

Thank you for the patch.

On Wed, Sep 15, 2021 at 05:32:38PM +0530, Pratyush Yadav wrote:
> The data-lanes property maps the logical lane numbers to the physical

> lane numbers. The position of an entry is the logical lane number and

> its value is the physical lane number. Since one physical lane can only

> map to one logical lane, no number in the list should repeat. Add the

> uniqueItems constraint on the property to enforce this.

> 

> Signed-off-by: Pratyush Yadav <p.yadav@ti.com>


Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>


> ---

> 

> Changes in v4:

> - New in v4.

> 

>  Documentation/devicetree/bindings/media/video-interfaces.yaml | 1 +

>  1 file changed, 1 insertion(+)

> 

> diff --git a/Documentation/devicetree/bindings/media/video-interfaces.yaml b/Documentation/devicetree/bindings/media/video-interfaces.yaml

> index 4391dce2caee..4bce93efae5f 100644

> --- a/Documentation/devicetree/bindings/media/video-interfaces.yaml

> +++ b/Documentation/devicetree/bindings/media/video-interfaces.yaml

> @@ -158,6 +158,7 @@ properties:

>      $ref: /schemas/types.yaml#/definitions/uint32-array

>      minItems: 1

>      maxItems: 8

> +    uniqueItems: true

>      items:

>        # Assume up to 9 physical lane indices

>        maximum: 8


-- 
Regards,

Laurent Pinchart
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/media/video-interfaces.yaml b/Documentation/devicetree/bindings/media/video-interfaces.yaml
index 4391dce2caee..4bce93efae5f 100644
--- a/Documentation/devicetree/bindings/media/video-interfaces.yaml
+++ b/Documentation/devicetree/bindings/media/video-interfaces.yaml
@@ -158,6 +158,7 @@  properties:
     $ref: /schemas/types.yaml#/definitions/uint32-array
     minItems: 1
     maxItems: 8
+    uniqueItems: true
     items:
       # Assume up to 9 physical lane indices
       maximum: 8