devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups
@ 2024-08-20  8:44 Krzysztof Kozlowski
  2024-08-20  8:44 ` [PATCH 1/3] dt-bindings: i2c: nvidia,tegra20-i2c: combine same if:then: clauses Krzysztof Kozlowski
                   ` (6 more replies)
  0 siblings, 7 replies; 10+ messages in thread
From: Krzysztof Kozlowski @ 2024-08-20  8:44 UTC (permalink / raw)
  To: Andi Shyti, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Thierry Reding, Jonathan Hunter
  Cc: linux-i2c, devicetree, linux-tegra, linux-kernel,
	Krzysztof Kozlowski

Simple cleanups for nvidia I2C.

Best regards,
Krzysztof

---
Krzysztof Kozlowski (3):
      dt-bindings: i2c: nvidia,tegra20-i2c: combine same if:then: clauses
      dt-bindings: i2c: nvidia,tegra20-i2c: restrict also clocks in if:then:
      dt-bindings: i2c: nvidia,tegra20-i2c: define power-domains top-level

 .../bindings/i2c/nvidia,tegra20-i2c.yaml           | 27 ++++++++++++----------
 1 file changed, 15 insertions(+), 12 deletions(-)
---
base-commit: 367b5c3d53e57d51a5878816804652963da90950
change-id: 20240820-dt-bindings-i2c-nvidia-895d89a18e8f

Best regards,
-- 
Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>


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

* [PATCH 1/3] dt-bindings: i2c: nvidia,tegra20-i2c: combine same if:then: clauses
  2024-08-20  8:44 [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups Krzysztof Kozlowski
@ 2024-08-20  8:44 ` Krzysztof Kozlowski
  2024-08-20  8:44 ` [PATCH 2/3] dt-bindings: i2c: nvidia,tegra20-i2c: restrict also clocks in if:then: Krzysztof Kozlowski
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 10+ messages in thread
From: Krzysztof Kozlowski @ 2024-08-20  8:44 UTC (permalink / raw)
  To: Andi Shyti, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Thierry Reding, Jonathan Hunter
  Cc: linux-i2c, devicetree, linux-tegra, linux-kernel,
	Krzysztof Kozlowski

"if:then:" block for Tegra114 and Tegra120 I2C controllers has the same
"then" part (same clocks), so combine them.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 .../devicetree/bindings/i2c/nvidia,tegra20-i2c.yaml       | 15 +++------------
 1 file changed, 3 insertions(+), 12 deletions(-)

diff --git a/Documentation/devicetree/bindings/i2c/nvidia,tegra20-i2c.yaml b/Documentation/devicetree/bindings/i2c/nvidia,tegra20-i2c.yaml
index 92fbc1a2671a..5c92ef51287d 100644
--- a/Documentation/devicetree/bindings/i2c/nvidia,tegra20-i2c.yaml
+++ b/Documentation/devicetree/bindings/i2c/nvidia,tegra20-i2c.yaml
@@ -133,18 +133,9 @@ allOf:
       properties:
         compatible:
           contains:
-            const: nvidia,tegra114-i2c
-    then:
-      properties:
-        clock-names:
-          items:
-            - const: div-clk
-
-  - if:
-      properties:
-        compatible:
-          contains:
-            const: nvidia,tegra210-i2c
+            enum:
+              - nvidia,tegra114-i2c
+              - nvidia,tegra210-i2c
     then:
       properties:
         clock-names:

-- 
2.43.0


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

* [PATCH 2/3] dt-bindings: i2c: nvidia,tegra20-i2c: restrict also clocks in if:then:
  2024-08-20  8:44 [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups Krzysztof Kozlowski
  2024-08-20  8:44 ` [PATCH 1/3] dt-bindings: i2c: nvidia,tegra20-i2c: combine same if:then: clauses Krzysztof Kozlowski
@ 2024-08-20  8:44 ` Krzysztof Kozlowski
  2024-08-20  8:44 ` [PATCH 3/3] dt-bindings: i2c: nvidia,tegra20-i2c: define power-domains top-level Krzysztof Kozlowski
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 10+ messages in thread
From: Krzysztof Kozlowski @ 2024-08-20  8:44 UTC (permalink / raw)
  To: Andi Shyti, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Thierry Reding, Jonathan Hunter
  Cc: linux-i2c, devicetree, linux-tegra, linux-kernel,
	Krzysztof Kozlowski

Both xxx and xxx-names properties with variable number of items should
be constrained in each "if:then:".  Add missing constraints for clocks,
since we have such for clock-names.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 Documentation/devicetree/bindings/i2c/nvidia,tegra20-i2c.yaml | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/Documentation/devicetree/bindings/i2c/nvidia,tegra20-i2c.yaml b/Documentation/devicetree/bindings/i2c/nvidia,tegra20-i2c.yaml
index 5c92ef51287d..eeaa07fe3875 100644
--- a/Documentation/devicetree/bindings/i2c/nvidia,tegra20-i2c.yaml
+++ b/Documentation/devicetree/bindings/i2c/nvidia,tegra20-i2c.yaml
@@ -124,6 +124,8 @@ allOf:
               - nvidia,tegra30-i2c
     then:
       properties:
+        clocks:
+          minItems: 2
         clock-names:
           items:
             - const: div-clk
@@ -138,6 +140,8 @@ allOf:
               - nvidia,tegra210-i2c
     then:
       properties:
+        clocks:
+          maxItems: 1
         clock-names:
           items:
             - const: div-clk
@@ -149,6 +153,8 @@ allOf:
             const: nvidia,tegra210-i2c-vi
     then:
       properties:
+        clocks:
+          minItems: 2
         clock-names:
           items:
             - const: div-clk

-- 
2.43.0


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

* [PATCH 3/3] dt-bindings: i2c: nvidia,tegra20-i2c: define power-domains top-level
  2024-08-20  8:44 [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups Krzysztof Kozlowski
  2024-08-20  8:44 ` [PATCH 1/3] dt-bindings: i2c: nvidia,tegra20-i2c: combine same if:then: clauses Krzysztof Kozlowski
  2024-08-20  8:44 ` [PATCH 2/3] dt-bindings: i2c: nvidia,tegra20-i2c: restrict also clocks in if:then: Krzysztof Kozlowski
@ 2024-08-20  8:44 ` Krzysztof Kozlowski
  2024-08-20 16:39 ` [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups Conor Dooley
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 10+ messages in thread
From: Krzysztof Kozlowski @ 2024-08-20  8:44 UTC (permalink / raw)
  To: Andi Shyti, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Thierry Reding, Jonathan Hunter
  Cc: linux-i2c, devicetree, linux-tegra, linux-kernel,
	Krzysztof Kozlowski

Properties are expected to be defined in top-level "properties:" block
and further customized in "if:then:".  Only one variant has power
domains, so add respective top-level property and disallow it for other
devices.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 Documentation/devicetree/bindings/i2c/nvidia,tegra20-i2c.yaml | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/Documentation/devicetree/bindings/i2c/nvidia,tegra20-i2c.yaml b/Documentation/devicetree/bindings/i2c/nvidia,tegra20-i2c.yaml
index eeaa07fe3875..b57ae6963e62 100644
--- a/Documentation/devicetree/bindings/i2c/nvidia,tegra20-i2c.yaml
+++ b/Documentation/devicetree/bindings/i2c/nvidia,tegra20-i2c.yaml
@@ -103,6 +103,9 @@ properties:
     items:
       - const: i2c
 
+  power-domains:
+    maxItems: 1
+
   dmas:
     items:
       - description: DMA channel for the reception FIFO
@@ -162,6 +165,9 @@ allOf:
         power-domains:
           items:
             - description: phandle to the VENC power domain
+    else:
+      properties:
+        power-domains: false
 
 unevaluatedProperties: false
 

-- 
2.43.0


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

* Re: [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups
  2024-08-20  8:44 [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups Krzysztof Kozlowski
                   ` (2 preceding siblings ...)
  2024-08-20  8:44 ` [PATCH 3/3] dt-bindings: i2c: nvidia,tegra20-i2c: define power-domains top-level Krzysztof Kozlowski
@ 2024-08-20 16:39 ` Conor Dooley
  2024-08-21 14:13 ` Andi Shyti
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 10+ messages in thread
From: Conor Dooley @ 2024-08-20 16:39 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Andi Shyti, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Thierry Reding, Jonathan Hunter, linux-i2c, devicetree,
	linux-tegra, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 156 bytes --]

On Tue, Aug 20, 2024 at 10:44:23AM +0200, Krzysztof Kozlowski wrote:
> Simple cleanups for nvidia I2C.

Acked-by: Conor Dooley <conor.dooley@microchip.com>

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

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

* Re: [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups
  2024-08-20  8:44 [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups Krzysztof Kozlowski
                   ` (3 preceding siblings ...)
  2024-08-20 16:39 ` [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups Conor Dooley
@ 2024-08-21 14:13 ` Andi Shyti
  2024-08-27 14:03 ` Thierry Reding
  2024-08-27 14:03 ` Thierry Reding
  6 siblings, 0 replies; 10+ messages in thread
From: Andi Shyti @ 2024-08-21 14:13 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Thierry Reding,
	Jonathan Hunter, linux-i2c, devicetree, linux-tegra, linux-kernel

Hi Krzysztof,

> Krzysztof Kozlowski (3):
>       dt-bindings: i2c: nvidia,tegra20-i2c: combine same if:then: clauses
>       dt-bindings: i2c: nvidia,tegra20-i2c: restrict also clocks in if:then:
>       dt-bindings: i2c: nvidia,tegra20-i2c: define power-domains top-level

merged to i2c/i2c-host.

Thanks,
Andi

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

* Re: [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups
  2024-08-20  8:44 [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups Krzysztof Kozlowski
                   ` (4 preceding siblings ...)
  2024-08-21 14:13 ` Andi Shyti
@ 2024-08-27 14:03 ` Thierry Reding
  2024-08-27 14:21   ` Krzysztof Kozlowski
  2024-08-27 14:03 ` Thierry Reding
  6 siblings, 1 reply; 10+ messages in thread
From: Thierry Reding @ 2024-08-27 14:03 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Andi Shyti, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Jonathan Hunter, linux-i2c, devicetree, linux-tegra, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 728 bytes --]

On Tue, Aug 20, 2024 at 10:44:23AM GMT, Krzysztof Kozlowski wrote:
> Simple cleanups for nvidia I2C.
> 
> Best regards,
> Krzysztof
> 
> ---
> Krzysztof Kozlowski (3):
>       dt-bindings: i2c: nvidia,tegra20-i2c: combine same if:then: clauses
>       dt-bindings: i2c: nvidia,tegra20-i2c: restrict also clocks in if:then:
>       dt-bindings: i2c: nvidia,tegra20-i2c: define power-domains top-level
> 
>  .../bindings/i2c/nvidia,tegra20-i2c.yaml           | 27 ++++++++++++----------
>  1 file changed, 15 insertions(+), 12 deletions(-)

It wasn't clear who you wanted to pick these up, so I've applied them to
the Tegra tree. Shout if anybody wants to take them through a different
tree.

Thanks,
Thierry

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

* Re: [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups
  2024-08-20  8:44 [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups Krzysztof Kozlowski
                   ` (5 preceding siblings ...)
  2024-08-27 14:03 ` Thierry Reding
@ 2024-08-27 14:03 ` Thierry Reding
  6 siblings, 0 replies; 10+ messages in thread
From: Thierry Reding @ 2024-08-27 14:03 UTC (permalink / raw)
  To: Andi Shyti, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Thierry Reding, Jonathan Hunter, Krzysztof Kozlowski
  Cc: linux-i2c, devicetree, linux-tegra, linux-kernel

From: Thierry Reding <treding@nvidia.com>


On Tue, 20 Aug 2024 10:44:23 +0200, Krzysztof Kozlowski wrote:
> Simple cleanups for nvidia I2C.
> 
> Best regards,
> Krzysztof
> 

Applied, thanks!

[1/3] dt-bindings: i2c: nvidia,tegra20-i2c: combine same if:then: clauses
      commit: d7ae7599809754d23cf571b849db0fead206ea67
[2/3] dt-bindings: i2c: nvidia,tegra20-i2c: restrict also clocks in if:then:
      commit: 82ce7a4dc6d43f067a520fa5b1ac5f2a83797474
[3/3] dt-bindings: i2c: nvidia,tegra20-i2c: define power-domains top-level
      commit: 2d9bac9a590ea522328ac7cdce810128ec1f333f

Best regards,
-- 
Thierry Reding <treding@nvidia.com>

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

* Re: [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups
  2024-08-27 14:03 ` Thierry Reding
@ 2024-08-27 14:21   ` Krzysztof Kozlowski
  2024-08-29  8:44     ` Thierry Reding
  0 siblings, 1 reply; 10+ messages in thread
From: Krzysztof Kozlowski @ 2024-08-27 14:21 UTC (permalink / raw)
  To: Thierry Reding
  Cc: Andi Shyti, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Jonathan Hunter, linux-i2c, devicetree, linux-tegra, linux-kernel

On 27/08/2024 16:03, Thierry Reding wrote:
> On Tue, Aug 20, 2024 at 10:44:23AM GMT, Krzysztof Kozlowski wrote:
>> Simple cleanups for nvidia I2C.
>>
>> Best regards,
>> Krzysztof
>>
>> ---
>> Krzysztof Kozlowski (3):
>>       dt-bindings: i2c: nvidia,tegra20-i2c: combine same if:then: clauses
>>       dt-bindings: i2c: nvidia,tegra20-i2c: restrict also clocks in if:then:
>>       dt-bindings: i2c: nvidia,tegra20-i2c: define power-domains top-level
>>
>>  .../bindings/i2c/nvidia,tegra20-i2c.yaml           | 27 ++++++++++++----------
>>  1 file changed, 15 insertions(+), 12 deletions(-)
> 
> It wasn't clear who you wanted to pick these up, so I've applied them to
> the Tegra tree. Shout if anybody wants to take them through a different
> tree.

They target I2C and I think they were merged by Andi:
https://lore.kernel.org/all/dkcfnidl3xgvspiusp3zftgdftyvlbxahlbumjdfl7dvxgmdmr@nomisqfu2mwb/

Best regards,
Krzysztof


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

* Re: [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups
  2024-08-27 14:21   ` Krzysztof Kozlowski
@ 2024-08-29  8:44     ` Thierry Reding
  0 siblings, 0 replies; 10+ messages in thread
From: Thierry Reding @ 2024-08-29  8:44 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Andi Shyti, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Jonathan Hunter, linux-i2c, devicetree, linux-tegra, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 1211 bytes --]

On Tue, Aug 27, 2024 at 04:21:01PM GMT, Krzysztof Kozlowski wrote:
> On 27/08/2024 16:03, Thierry Reding wrote:
> > On Tue, Aug 20, 2024 at 10:44:23AM GMT, Krzysztof Kozlowski wrote:
> >> Simple cleanups for nvidia I2C.
> >>
> >> Best regards,
> >> Krzysztof
> >>
> >> ---
> >> Krzysztof Kozlowski (3):
> >>       dt-bindings: i2c: nvidia,tegra20-i2c: combine same if:then: clauses
> >>       dt-bindings: i2c: nvidia,tegra20-i2c: restrict also clocks in if:then:
> >>       dt-bindings: i2c: nvidia,tegra20-i2c: define power-domains top-level
> >>
> >>  .../bindings/i2c/nvidia,tegra20-i2c.yaml           | 27 ++++++++++++----------
> >>  1 file changed, 15 insertions(+), 12 deletions(-)
> > 
> > It wasn't clear who you wanted to pick these up, so I've applied them to
> > the Tegra tree. Shout if anybody wants to take them through a different
> > tree.
> 
> They target I2C and I think they were merged by Andi:
> https://lore.kernel.org/all/dkcfnidl3xgvspiusp3zftgdftyvlbxahlbumjdfl7dvxgmdmr@nomisqfu2mwb/

Indeed, I hadn't seen Andi's reply in the patch tracker, so had assumed
people were waiting for me to pick them into the Tegra tree.

I'll drop them.

Thanks,
Thierry

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

end of thread, other threads:[~2024-08-29  8:44 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-08-20  8:44 [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups Krzysztof Kozlowski
2024-08-20  8:44 ` [PATCH 1/3] dt-bindings: i2c: nvidia,tegra20-i2c: combine same if:then: clauses Krzysztof Kozlowski
2024-08-20  8:44 ` [PATCH 2/3] dt-bindings: i2c: nvidia,tegra20-i2c: restrict also clocks in if:then: Krzysztof Kozlowski
2024-08-20  8:44 ` [PATCH 3/3] dt-bindings: i2c: nvidia,tegra20-i2c: define power-domains top-level Krzysztof Kozlowski
2024-08-20 16:39 ` [PATCH 0/3] dt-bindings: i2c: nvidia,tegra20-i2c: minor cleanups Conor Dooley
2024-08-21 14:13 ` Andi Shyti
2024-08-27 14:03 ` Thierry Reding
2024-08-27 14:21   ` Krzysztof Kozlowski
2024-08-29  8:44     ` Thierry Reding
2024-08-27 14:03 ` Thierry Reding

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).