public inbox for devicetree@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/3] dt-bindings: interconnect: qcom,sdm660: Disallow clocks when appropriate
@ 2026-05-03 16:16 Krzysztof Kozlowski
  2026-05-03 16:16 ` [PATCH 2/3] dt-bindings: interconnect: qcom,sm6115: Drop incorrect children if:then: block Krzysztof Kozlowski
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Krzysztof Kozlowski @ 2026-05-03 16:16 UTC (permalink / raw)
  To: Georgi Djakov, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Konrad Dybcio, linux-arm-msm, linux-pm, devicetree, linux-kernel
  Cc: Krzysztof Kozlowski

Only qcom,sdm660-mnoc and qcom,sdm660-a2noc devices from what is covered
by this binding have clocks.  Others do not, so restrict the schema to
be more accurate.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
---
 .../bindings/interconnect/qcom,sdm660.yaml          | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/Documentation/devicetree/bindings/interconnect/qcom,sdm660.yaml b/Documentation/devicetree/bindings/interconnect/qcom,sdm660.yaml
index 8f6bc6399626..51428a2b0ce0 100644
--- a/Documentation/devicetree/bindings/interconnect/qcom,sdm660.yaml
+++ b/Documentation/devicetree/bindings/interconnect/qcom,sdm660.yaml
@@ -79,6 +79,19 @@ allOf:
             - const: aggre2_usb3_axi
             - const: cfg_noc_usb2_axi
 
+  - if:
+      properties:
+        compatible:
+          enum:
+            - qcom,sdm660-bimc
+            - qcom,sdm660-cnoc
+            - qcom,sdm660-gnoc
+            - qcom,sdm660-snoc
+    then:
+      properties:
+        clocks: false
+        clock-names: false
+
 examples:
   - |
     #include <dt-bindings/clock/qcom,gcc-sdm660.h>
-- 
2.51.0


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

* [PATCH 2/3] dt-bindings: interconnect: qcom,sm6115: Drop incorrect children if:then: block
  2026-05-03 16:16 [PATCH 1/3] dt-bindings: interconnect: qcom,sdm660: Disallow clocks when appropriate Krzysztof Kozlowski
@ 2026-05-03 16:16 ` Krzysztof Kozlowski
  2026-05-04  7:57   ` Konrad Dybcio
  2026-05-03 16:16 ` [PATCH 3/3] dt-bindings: interconnect: qcom,sm6115: Restrict children and clocks Krzysztof Kozlowski
  2026-05-04  7:53 ` [PATCH 1/3] dt-bindings: interconnect: qcom,sdm660: Disallow clocks when appropriate Konrad Dybcio
  2 siblings, 1 reply; 6+ messages in thread
From: Krzysztof Kozlowski @ 2026-05-03 16:16 UTC (permalink / raw)
  To: Georgi Djakov, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Konrad Dybcio, linux-arm-msm, linux-pm, devicetree, linux-kernel
  Cc: Krzysztof Kozlowski

This binding has children, so any if:then: block restricting them,
cannot be defined in top-level allOf:if:then:properties:, because it
simply does not match these children.  The block, if it was useful,
should be defined within patternProperties for the children, however
since child nodes do not have clocks at all, there is little point in
disallowing them in the first place.

Remove completely redundant and ineffective piece of code.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
---
 .../bindings/interconnect/qcom,sm6115.yaml         | 14 --------------
 1 file changed, 14 deletions(-)

diff --git a/Documentation/devicetree/bindings/interconnect/qcom,sm6115.yaml b/Documentation/devicetree/bindings/interconnect/qcom,sm6115.yaml
index 14b1a0b08e73..67c1705af50f 100644
--- a/Documentation/devicetree/bindings/interconnect/qcom,sm6115.yaml
+++ b/Documentation/devicetree/bindings/interconnect/qcom,sm6115.yaml
@@ -95,20 +95,6 @@ allOf:
             - const: usb_axi
             - const: ipa
 
-  - if:
-      properties:
-        compatible:
-          enum:
-            - qcom,sm6115-bimc
-            - qcom,sm6115-clk-virt
-            - qcom,sm6115-mmrt-virt
-            - qcom,sm6115-mmnrt-virt
-
-    then:
-      properties:
-        clocks: false
-        clock-names: false
-
 unevaluatedProperties: false
 
 examples:
-- 
2.51.0


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

* [PATCH 3/3] dt-bindings: interconnect: qcom,sm6115: Restrict children and clocks
  2026-05-03 16:16 [PATCH 1/3] dt-bindings: interconnect: qcom,sdm660: Disallow clocks when appropriate Krzysztof Kozlowski
  2026-05-03 16:16 ` [PATCH 2/3] dt-bindings: interconnect: qcom,sm6115: Drop incorrect children if:then: block Krzysztof Kozlowski
@ 2026-05-03 16:16 ` Krzysztof Kozlowski
  2026-05-04  8:00   ` Konrad Dybcio
  2026-05-04  7:53 ` [PATCH 1/3] dt-bindings: interconnect: qcom,sdm660: Disallow clocks when appropriate Konrad Dybcio
  2 siblings, 1 reply; 6+ messages in thread
From: Krzysztof Kozlowski @ 2026-05-03 16:16 UTC (permalink / raw)
  To: Georgi Djakov, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Konrad Dybcio, linux-arm-msm, linux-pm, devicetree, linux-kernel
  Cc: Krzysztof Kozlowski

Some interconnect devices described in the binding have children and
some have clocks.  The devices which do not have them, should have this
restricted (disallowed).

qcom,sm6115-cnoc has a clock, thus also extend the example to be
complete for this device.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
---
 .../bindings/interconnect/qcom,sm6115.yaml    | 19 +++++++++++++++----
 1 file changed, 15 insertions(+), 4 deletions(-)

diff --git a/Documentation/devicetree/bindings/interconnect/qcom,sm6115.yaml b/Documentation/devicetree/bindings/interconnect/qcom,sm6115.yaml
index 67c1705af50f..cdae0acf3a1d 100644
--- a/Documentation/devicetree/bindings/interconnect/qcom,sm6115.yaml
+++ b/Documentation/devicetree/bindings/interconnect/qcom,sm6115.yaml
@@ -62,23 +62,33 @@ allOf:
   - if:
       properties:
         compatible:
-          const: qcom,sm6115-cnoc
+          const: qcom,sm6115-bimc
+    then:
+      properties:
+        clocks: false
+        clock-names: false
+      patternProperties:
+        '^interconnect-[a-z0-9]+$': false
 
+  - if:
+      properties:
+        compatible:
+          const: qcom,sm6115-cnoc
     then:
       properties:
         clocks:
           items:
             - description: USB-NoC AXI clock
-
         clock-names:
           items:
             - const: usb_axi
+      patternProperties:
+        '^interconnect-[a-z0-9]+$': false
 
   - if:
       properties:
         compatible:
           const: qcom,sm6115-snoc
-
     then:
       properties:
         clocks:
@@ -87,7 +97,6 @@ allOf:
             - description: UFS-NoC AXI clock.
             - description: USB-NoC AXI clock.
             - description: IPA clock.
-
         clock-names:
           items:
             - const: cpu_axi
@@ -135,4 +144,6 @@ examples:
         compatible = "qcom,sm6115-cnoc";
         reg = <0x01900000 0x8200>;
         #interconnect-cells = <1>;
+        clocks = <&gcc GCC_CFG_NOC_USB3_PRIM_AXI_CLK>;
+        clock-names = "usb_axi";
     };
-- 
2.51.0


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

* Re: [PATCH 1/3] dt-bindings: interconnect: qcom,sdm660: Disallow clocks when appropriate
  2026-05-03 16:16 [PATCH 1/3] dt-bindings: interconnect: qcom,sdm660: Disallow clocks when appropriate Krzysztof Kozlowski
  2026-05-03 16:16 ` [PATCH 2/3] dt-bindings: interconnect: qcom,sm6115: Drop incorrect children if:then: block Krzysztof Kozlowski
  2026-05-03 16:16 ` [PATCH 3/3] dt-bindings: interconnect: qcom,sm6115: Restrict children and clocks Krzysztof Kozlowski
@ 2026-05-04  7:53 ` Konrad Dybcio
  2 siblings, 0 replies; 6+ messages in thread
From: Konrad Dybcio @ 2026-05-04  7:53 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Georgi Djakov, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Konrad Dybcio, linux-arm-msm,
	linux-pm, devicetree, linux-kernel

On 5/3/26 6:16 PM, Krzysztof Kozlowski wrote:
> Only qcom,sdm660-mnoc and qcom,sdm660-a2noc devices from what is covered
> by this binding have clocks.  Others do not, so restrict the schema to
> be more accurate.
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
> ---

Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>

Konrad

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

* Re: [PATCH 2/3] dt-bindings: interconnect: qcom,sm6115: Drop incorrect children if:then: block
  2026-05-03 16:16 ` [PATCH 2/3] dt-bindings: interconnect: qcom,sm6115: Drop incorrect children if:then: block Krzysztof Kozlowski
@ 2026-05-04  7:57   ` Konrad Dybcio
  0 siblings, 0 replies; 6+ messages in thread
From: Konrad Dybcio @ 2026-05-04  7:57 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Georgi Djakov, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Konrad Dybcio, linux-arm-msm,
	linux-pm, devicetree, linux-kernel

On 5/3/26 6:16 PM, Krzysztof Kozlowski wrote:
> This binding has children, so any if:then: block restricting them,
> cannot be defined in top-level allOf:if:then:properties:, because it
> simply does not match these children.  The block, if it was useful,
> should be defined within patternProperties for the children, however
> since child nodes do not have clocks at all, there is little point in
> disallowing them in the first place.
> 
> Remove completely redundant and ineffective piece of code.
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
> ---

Good find, this wasn't obvious

Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>

Konrad

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

* Re: [PATCH 3/3] dt-bindings: interconnect: qcom,sm6115: Restrict children and clocks
  2026-05-03 16:16 ` [PATCH 3/3] dt-bindings: interconnect: qcom,sm6115: Restrict children and clocks Krzysztof Kozlowski
@ 2026-05-04  8:00   ` Konrad Dybcio
  0 siblings, 0 replies; 6+ messages in thread
From: Konrad Dybcio @ 2026-05-04  8:00 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Georgi Djakov, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Konrad Dybcio, linux-arm-msm,
	linux-pm, devicetree, linux-kernel

On 5/3/26 6:16 PM, Krzysztof Kozlowski wrote:
> Some interconnect devices described in the binding have children and
> some have clocks.  The devices which do not have them, should have this
> restricted (disallowed).
> 
> qcom,sm6115-cnoc has a clock, thus also extend the example to be
> complete for this device.
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
> ---

Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>

Konrad

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

end of thread, other threads:[~2026-05-04  8:00 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-05-03 16:16 [PATCH 1/3] dt-bindings: interconnect: qcom,sdm660: Disallow clocks when appropriate Krzysztof Kozlowski
2026-05-03 16:16 ` [PATCH 2/3] dt-bindings: interconnect: qcom,sm6115: Drop incorrect children if:then: block Krzysztof Kozlowski
2026-05-04  7:57   ` Konrad Dybcio
2026-05-03 16:16 ` [PATCH 3/3] dt-bindings: interconnect: qcom,sm6115: Restrict children and clocks Krzysztof Kozlowski
2026-05-04  8:00   ` Konrad Dybcio
2026-05-04  7:53 ` [PATCH 1/3] dt-bindings: interconnect: qcom,sdm660: Disallow clocks when appropriate Konrad Dybcio

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