public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2] media: dt-bindings: samsung,s5p-mfc: Fix iommu properties schemas
@ 2023-12-14 19:55 ` Rob Herring
  2023-12-15  5:11   ` Aakarsh Jain
                     ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Rob Herring @ 2023-12-14 19:55 UTC (permalink / raw)
  To: Mauro Carvalho Chehab, Krzysztof Kozlowski, Conor Dooley,
	Marek Szyprowski, Aakarsh Jain
  Cc: linux-media, devicetree, linux-kernel

The iommus and iommu-names property schemas have several issues. First,
'iommus-names' in the if/then schemas is the wrong name. As all the names
are the same, they can be defined at the top level instead. Then the
if/then schemas just need to define how many entries. The iommus if/then
schemas are also redundant. Best I can tell, the desire was to require 2
entries for "samsung,exynos5433-mfc", "samsung,mfc-v5", "samsung,mfc-v6",
and "samsung,mfc-v8".

Signed-off-by: Rob Herring <robh@kernel.org>
---
v2:
 - Fix some more cases of iommus-names
---
 .../bindings/media/samsung,s5p-mfc.yaml       | 33 ++++++++-----------
 1 file changed, 13 insertions(+), 20 deletions(-)

diff --git a/Documentation/devicetree/bindings/media/samsung,s5p-mfc.yaml b/Documentation/devicetree/bindings/media/samsung,s5p-mfc.yaml
index 084b44582a43..4c3250985ac3 100644
--- a/Documentation/devicetree/bindings/media/samsung,s5p-mfc.yaml
+++ b/Documentation/devicetree/bindings/media/samsung,s5p-mfc.yaml
@@ -49,7 +49,9 @@ properties:
 
   iommu-names:
     minItems: 1
-    maxItems: 2
+    items:
+      - const: left
+      - const: right
 
   power-domains:
     maxItems: 1
@@ -84,7 +86,7 @@ allOf:
             - const: sclk_mfc
         iommus:
           maxItems: 1
-        iommus-names: false
+        iommu-names: false
 
   - if:
       properties:
@@ -102,11 +104,9 @@ allOf:
             - const: aclk
             - const: aclk_xiu
         iommus:
-          maxItems: 2
-        iommus-names:
-          items:
-            - const: left
-            - const: right
+          minItems: 2
+        iommu-names:
+          minItems: 2
 
   - if:
       properties:
@@ -123,11 +123,9 @@ allOf:
             - const: mfc
             - const: sclk_mfc
         iommus:
-          maxItems: 2
-        iommus-names:
-          items:
-            - const: left
-            - const: right
+          minItems: 2
+        iommu-names:
+          minItems: 2
 
   - if:
       properties:
@@ -144,11 +142,9 @@ allOf:
           items:
             - const: mfc
         iommus:
-          maxItems: 2
-        iommus-names:
-          items:
-            - const: left
-            - const: right
+          minItems: 2
+        iommu-names:
+          minItems: 2
 
   - if:
       properties:
@@ -161,9 +157,6 @@ allOf:
         clocks:
           minItems: 1
           maxItems: 2
-        iommus:
-          minItems: 1
-          maxItems: 2
 
 examples:
   - |
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* RE: [PATCH v2] media: dt-bindings: samsung,s5p-mfc: Fix iommu properties schemas
  2023-12-14 19:55 ` [PATCH v2] media: dt-bindings: samsung,s5p-mfc: Fix iommu properties schemas Rob Herring
@ 2023-12-15  5:11   ` Aakarsh Jain
  2023-12-15  7:51   ` Krzysztof Kozlowski
  2024-01-02 16:39   ` Rob Herring
  2 siblings, 0 replies; 4+ messages in thread
From: Aakarsh Jain @ 2023-12-15  5:11 UTC (permalink / raw)
  To: 'Rob Herring', 'Mauro Carvalho Chehab',
	'Krzysztof Kozlowski', 'Conor Dooley',
	'Marek Szyprowski'
  Cc: linux-media, devicetree, linux-kernel



> -----Original Message-----
> From: Rob Herring <robh@kernel.org>
> Sent: 15 December 2023 01:26
> To: Mauro Carvalho Chehab <mchehab@kernel.org>; Krzysztof Kozlowski
> <krzysztof.kozlowski+dt@linaro.org>; Conor Dooley
> <conor+dt@kernel.org>; Marek Szyprowski <m.szyprowski@samsung.com>;
> Aakarsh Jain <aakarsh.jain@samsung.com>
> Cc: linux-media@vger.kernel.org; devicetree@vger.kernel.org; linux-
> kernel@vger.kernel.org
> Subject: [PATCH v2] media: dt-bindings: samsung,s5p-mfc: Fix iommu
> properties schemas
> 
> The iommus and iommu-names property schemas have several issues. First,
> 'iommus-names' in the if/then schemas is the wrong name. As all the names
> are the same, they can be defined at the top level instead. Then the
if/then
> schemas just need to define how many entries. The iommus if/then schemas
> are also redundant. Best I can tell, the desire was to require 2 entries
for
> "samsung,exynos5433-mfc", "samsung,mfc-v5", "samsung,mfc-v6", and
> "samsung,mfc-v8".
> 
> Signed-off-by: Rob Herring <robh@kernel.org>
> ---
> v2:
>  - Fix some more cases of iommus-names
> ---
>  .../bindings/media/samsung,s5p-mfc.yaml       | 33 ++++++++-----------
>  1 file changed, 13 insertions(+), 20 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/media/samsung,s5p-
> mfc.yaml b/Documentation/devicetree/bindings/media/samsung,s5p-
> mfc.yaml
> index 084b44582a43..4c3250985ac3 100644
> --- a/Documentation/devicetree/bindings/media/samsung,s5p-mfc.yaml
> +++ b/Documentation/devicetree/bindings/media/samsung,s5p-mfc.yaml
> @@ -49,7 +49,9 @@ properties:
> 
>    iommu-names:
>      minItems: 1
> -    maxItems: 2
> +    items:
> +      - const: left
> +      - const: right
> 
>    power-domains:
>      maxItems: 1
> @@ -84,7 +86,7 @@ allOf:
>              - const: sclk_mfc
>          iommus:
>            maxItems: 1
> -        iommus-names: false
> +        iommu-names: false
> 
>    - if:
>        properties:
> @@ -102,11 +104,9 @@ allOf:
>              - const: aclk
>              - const: aclk_xiu
>          iommus:
> -          maxItems: 2
> -        iommus-names:
> -          items:
> -            - const: left
> -            - const: right
> +          minItems: 2
> +        iommu-names:
> +          minItems: 2
> 
>    - if:
>        properties:
> @@ -123,11 +123,9 @@ allOf:
>              - const: mfc
>              - const: sclk_mfc
>          iommus:
> -          maxItems: 2
> -        iommus-names:
> -          items:
> -            - const: left
> -            - const: right
> +          minItems: 2
> +        iommu-names:
> +          minItems: 2
> 
>    - if:
>        properties:
> @@ -144,11 +142,9 @@ allOf:
>            items:
>              - const: mfc
>          iommus:
> -          maxItems: 2
> -        iommus-names:
> -          items:
> -            - const: left
> -            - const: right
> +          minItems: 2
> +        iommu-names:
> +          minItems: 2
> 
>    - if:
>        properties:
> @@ -161,9 +157,6 @@ allOf:
>          clocks:
>            minItems: 1
>            maxItems: 2
> -        iommus:
> -          minItems: 1
> -          maxItems: 2
> 
>  examples:
>    - |
> --
> 2.43.0

Reviewed-by: Aakarsh Jain <aakarsh.jain@samsung.com>


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH v2] media: dt-bindings: samsung,s5p-mfc: Fix iommu properties schemas
  2023-12-14 19:55 ` [PATCH v2] media: dt-bindings: samsung,s5p-mfc: Fix iommu properties schemas Rob Herring
  2023-12-15  5:11   ` Aakarsh Jain
@ 2023-12-15  7:51   ` Krzysztof Kozlowski
  2024-01-02 16:39   ` Rob Herring
  2 siblings, 0 replies; 4+ messages in thread
From: Krzysztof Kozlowski @ 2023-12-15  7:51 UTC (permalink / raw)
  To: Rob Herring, Mauro Carvalho Chehab, Krzysztof Kozlowski,
	Conor Dooley, Marek Szyprowski, Aakarsh Jain
  Cc: linux-media, devicetree, linux-kernel

On 14/12/2023 20:55, Rob Herring wrote:
> The iommus and iommu-names property schemas have several issues. First,
> 'iommus-names' in the if/then schemas is the wrong name. As all the names
> are the same, they can be defined at the top level instead. Then the
> if/then schemas just need to define how many entries. The iommus if/then
> schemas are also redundant. Best I can tell, the desire was to require 2
> entries for "samsung,exynos5433-mfc", "samsung,mfc-v5", "samsung,mfc-v6",
> and "samsung,mfc-v8".
> 
> Signed-off-by: Rob Herring <robh@kernel.org>
> ---

Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>

Best regards,
Krzysztof


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH v2] media: dt-bindings: samsung,s5p-mfc: Fix iommu properties schemas
  2023-12-14 19:55 ` [PATCH v2] media: dt-bindings: samsung,s5p-mfc: Fix iommu properties schemas Rob Herring
  2023-12-15  5:11   ` Aakarsh Jain
  2023-12-15  7:51   ` Krzysztof Kozlowski
@ 2024-01-02 16:39   ` Rob Herring
  2 siblings, 0 replies; 4+ messages in thread
From: Rob Herring @ 2024-01-02 16:39 UTC (permalink / raw)
  To: Rob Herring
  Cc: Mauro Carvalho Chehab, devicetree, linux-kernel, Marek Szyprowski,
	Krzysztof Kozlowski, Aakarsh Jain, linux-media, Conor Dooley


On Thu, 14 Dec 2023 13:55:52 -0600, Rob Herring wrote:
> The iommus and iommu-names property schemas have several issues. First,
> 'iommus-names' in the if/then schemas is the wrong name. As all the names
> are the same, they can be defined at the top level instead. Then the
> if/then schemas just need to define how many entries. The iommus if/then
> schemas are also redundant. Best I can tell, the desire was to require 2
> entries for "samsung,exynos5433-mfc", "samsung,mfc-v5", "samsung,mfc-v6",
> and "samsung,mfc-v8".
> 
> Signed-off-by: Rob Herring <robh@kernel.org>
> ---
> v2:
>  - Fix some more cases of iommus-names
> ---
>  .../bindings/media/samsung,s5p-mfc.yaml       | 33 ++++++++-----------
>  1 file changed, 13 insertions(+), 20 deletions(-)
> 

Applied, thanks!


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-01-02 16:43 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <CGME20231214195605epcas5p1ae2470abdb641ad8d299968fc306ec07@epcas5p1.samsung.com>
2023-12-14 19:55 ` [PATCH v2] media: dt-bindings: samsung,s5p-mfc: Fix iommu properties schemas Rob Herring
2023-12-15  5:11   ` Aakarsh Jain
2023-12-15  7:51   ` Krzysztof Kozlowski
2024-01-02 16:39   ` Rob Herring

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox