All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/2] dt-bindings: clock: update qcom,mmcc bindings for MSM8996
@ 2022-07-05 11:27 Dmitry Baryshkov
  2022-07-05 11:27 ` [PATCH v2 1/2] dt-bindings: clock: qcom,mmcc: fix clocks/clock-names definitions Dmitry Baryshkov
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Dmitry Baryshkov @ 2022-07-05 11:27 UTC (permalink / raw)
  To: Andy Gross, Bjorn Andersson, Konrad Dybcio, Stephen Boyd,
	Michael Turquette, Rob Herring, Krzysztof Kozlowski, Taniya Das
  Cc: linux-arm-msm, linux-clk, devicetree

This is a split of binding patches from [1]. When sending the original
series I missed adding DT maintainers to the CC list, so while all the
DTS changes were accepted by Bjorn, the dt-bindings were not reviewed
(and were not taken in).

Changes since v1:
 - Moved the first condition block (clocks/clock-names requirement)
   under the allOf (requested by Krzysztof).

[1] https://lore.kernel.org/linux-arm-msm/20220617122922.769562-1-dmitry.baryshkov@linaro.org/

Dmitry Baryshkov (2):
  dt-bindings: clock: qcom,mmcc: fix clocks/clock-names definitions
  dt-bindings: clock: qcom,mmcc: define clocks/clock-names for MSM8996

 .../devicetree/bindings/clock/qcom,mmcc.yaml  | 178 ++++++++++++++----
 1 file changed, 146 insertions(+), 32 deletions(-)

-- 
2.35.1


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

* [PATCH v2 1/2] dt-bindings: clock: qcom,mmcc: fix clocks/clock-names definitions
  2022-07-05 11:27 [PATCH v2 0/2] dt-bindings: clock: update qcom,mmcc bindings for MSM8996 Dmitry Baryshkov
@ 2022-07-05 11:27 ` Dmitry Baryshkov
  2022-07-05 11:28   ` Krzysztof Kozlowski
  2022-07-05 11:27 ` [PATCH v2 2/2] dt-bindings: clock: qcom,mmcc: define clocks/clock-names for MSM8996 Dmitry Baryshkov
  2022-08-29 23:45 ` [PATCH v2 0/2] dt-bindings: clock: update qcom,mmcc bindings " Bjorn Andersson
  2 siblings, 1 reply; 5+ messages in thread
From: Dmitry Baryshkov @ 2022-07-05 11:27 UTC (permalink / raw)
  To: Andy Gross, Bjorn Andersson, Konrad Dybcio, Stephen Boyd,
	Michael Turquette, Rob Herring, Krzysztof Kozlowski, Taniya Das
  Cc: linux-arm-msm, linux-clk, devicetree

Rather than defining (incorrect) global clocks and clock-names lists,
define them per platform using conditionals. Also, while we are at it,
mark these properties as required for all platforms for which DT files
contained clocks/clock-names for the MMCC nodes from the beginning (in
addition to existing MSM8998 this adds MSM8994, SDM630 and SDM660).

Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
---
 .../devicetree/bindings/clock/qcom,mmcc.yaml  | 149 ++++++++++++++----
 1 file changed, 117 insertions(+), 32 deletions(-)

diff --git a/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml b/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml
index 32e87014bb55..6b831730a914 100644
--- a/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml
+++ b/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml
@@ -31,30 +31,12 @@ properties:
       - qcom,mmcc-sdm660
 
   clocks:
-    items:
-      - description: Board XO source
-      - description: Board sleep source
-      - description: Global PLL 0 clock
-      - description: DSI phy instance 0 dsi clock
-      - description: DSI phy instance 0 byte clock
-      - description: DSI phy instance 1 dsi clock
-      - description: DSI phy instance 1 byte clock
-      - description: HDMI phy PLL clock
-      - description: DisplayPort phy PLL vco clock
-      - description: DisplayPort phy PLL link clock
+    minItems: 9
+    maxItems: 10
 
   clock-names:
-    items:
-      - const: xo
-      - const: sleep
-      - const: gpll0
-      - const: dsi0dsi
-      - const: dsi0byte
-      - const: dsi1dsi
-      - const: dsi1byte
-      - const: hdmipll
-      - const: dpvco
-      - const: dplink
+    minItems: 9
+    maxItems: 10
 
   '#clock-cells':
     const: 1
@@ -85,16 +67,119 @@ required:
 
 additionalProperties: false
 
-if:
-  properties:
-    compatible:
-      contains:
-        const: qcom,mmcc-msm8998
-
-then:
-  required:
-    - clocks
-    - clock-names
+allOf:
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,mmcc-msm8994
+              - qcom,mmcc-msm8998
+              - qcom,mmcc-sdm630
+              - qcom,mmcc-sdm660
+    then:
+      required:
+        - clocks
+        - clock-names
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            const: qcom,mmcc-msm8994
+    then:
+      properties:
+        clocks:
+          items:
+            - description: Board XO source
+            - description: Global PLL 0 clock
+            - description: MMSS NoC AHB clock
+            - description: GFX3D clock
+            - description: DSI phy instance 0 dsi clock
+            - description: DSI phy instance 0 byte clock
+            - description: DSI phy instance 1 dsi clock
+            - description: DSI phy instance 1 byte clock
+            - description: HDMI phy PLL clock
+
+        clock-names:
+          items:
+            - const: xo
+            - const: gpll0
+            - const: mmssnoc_ahb
+            - const: oxili_gfx3d_clk_src
+            - const: dsi0pll
+            - const: dsi0pllbyte
+            - const: dsi1pll
+            - const: dsi1pllbyte
+            - const: hdmipll
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            const: qcom,mmcc-msm8998
+    then:
+      properties:
+        clocks:
+          items:
+            - description: Board XO source
+            - description: Global PLL 0 clock
+            - description: DSI phy instance 0 dsi clock
+            - description: DSI phy instance 0 byte clock
+            - description: DSI phy instance 1 dsi clock
+            - description: DSI phy instance 1 byte clock
+            - description: HDMI phy PLL clock
+            - description: DisplayPort phy PLL link clock
+            - description: DisplayPort phy PLL vco clock
+            - description: Test clock
+
+        clock-names:
+          items:
+            - const: xo
+            - const: gpll0
+            - const: dsi0dsi
+            - const: dsi0byte
+            - const: dsi1dsi
+            - const: dsi1byte
+            - const: hdmipll
+            - const: dplink
+            - const: dpvco
+            - const: core_bi_pll_test_se
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,mmcc-sdm630
+              - qcom,mmcc-sdm660
+    then:
+      properties:
+        clocks:
+          items:
+            - description: Board XO source
+            - description: Board sleep source
+            - description: Global PLL 0 clock
+            - description: Global PLL 0 DIV clock
+            - description: DSI phy instance 0 dsi clock
+            - description: DSI phy instance 0 byte clock
+            - description: DSI phy instance 1 dsi clock
+            - description: DSI phy instance 1 byte clock
+            - description: DisplayPort phy PLL link clock
+            - description: DisplayPort phy PLL vco clock
+
+        clock-names:
+          items:
+            - const: xo
+            - const: sleep_clk
+            - const: gpll0
+            - const: gpll0_div
+            - const: dsi0pll
+            - const: dsi0pllbyte
+            - const: dsi1pll
+            - const: dsi1pllbyte
+            - const: dp_link_2x_clk_divsel_five
+            - const: dp_vco_divided_clk_src_mux
 
 examples:
   # Example for MMCC for MSM8960:
-- 
2.35.1


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

* [PATCH v2 2/2] dt-bindings: clock: qcom,mmcc: define clocks/clock-names for MSM8996
  2022-07-05 11:27 [PATCH v2 0/2] dt-bindings: clock: update qcom,mmcc bindings for MSM8996 Dmitry Baryshkov
  2022-07-05 11:27 ` [PATCH v2 1/2] dt-bindings: clock: qcom,mmcc: fix clocks/clock-names definitions Dmitry Baryshkov
@ 2022-07-05 11:27 ` Dmitry Baryshkov
  2022-08-29 23:45 ` [PATCH v2 0/2] dt-bindings: clock: update qcom,mmcc bindings " Bjorn Andersson
  2 siblings, 0 replies; 5+ messages in thread
From: Dmitry Baryshkov @ 2022-07-05 11:27 UTC (permalink / raw)
  To: Andy Gross, Bjorn Andersson, Konrad Dybcio, Stephen Boyd,
	Michael Turquette, Rob Herring, Krzysztof Kozlowski, Taniya Das
  Cc: linux-arm-msm, linux-clk, devicetree, Krzysztof Kozlowski

Define clock/clock-names properties of the MMCC device node to be used
on MSM8996 platform.

Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
---
 .../devicetree/bindings/clock/qcom,mmcc.yaml  | 33 +++++++++++++++++--
 1 file changed, 31 insertions(+), 2 deletions(-)

diff --git a/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml b/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml
index 6b831730a914..ef6736198451 100644
--- a/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml
+++ b/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml
@@ -31,11 +31,11 @@ properties:
       - qcom,mmcc-sdm660
 
   clocks:
-    minItems: 9
+    minItems: 8
     maxItems: 10
 
   clock-names:
-    minItems: 9
+    minItems: 8
     maxItems: 10
 
   '#clock-cells':
@@ -113,6 +113,35 @@ allOf:
             - const: dsi1pllbyte
             - const: hdmipll
 
+  - if:
+      properties:
+        compatible:
+          contains:
+            const: qcom,mmcc-msm8996
+    then:
+      properties:
+        clocks:
+          items:
+            - description: Board XO source
+            - description: Global PLL 0 clock
+            - description: MMSS NoC AHB clock
+            - description: DSI phy instance 0 dsi clock
+            - description: DSI phy instance 0 byte clock
+            - description: DSI phy instance 1 dsi clock
+            - description: DSI phy instance 1 byte clock
+            - description: HDMI phy PLL clock
+
+        clock-names:
+          items:
+            - const: xo
+            - const: gpll0
+            - const: gcc_mmss_noc_cfg_ahb_clk
+            - const: dsi0pll
+            - const: dsi0pllbyte
+            - const: dsi1pll
+            - const: dsi1pllbyte
+            - const: hdmipll
+
   - if:
       properties:
         compatible:
-- 
2.35.1


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

* Re: [PATCH v2 1/2] dt-bindings: clock: qcom,mmcc: fix clocks/clock-names definitions
  2022-07-05 11:27 ` [PATCH v2 1/2] dt-bindings: clock: qcom,mmcc: fix clocks/clock-names definitions Dmitry Baryshkov
@ 2022-07-05 11:28   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 5+ messages in thread
From: Krzysztof Kozlowski @ 2022-07-05 11:28 UTC (permalink / raw)
  To: Dmitry Baryshkov, Andy Gross, Bjorn Andersson, Konrad Dybcio,
	Stephen Boyd, Michael Turquette, Rob Herring,
	Krzysztof Kozlowski, Taniya Das
  Cc: linux-arm-msm, linux-clk, devicetree

On 05/07/2022 13:27, Dmitry Baryshkov wrote:
> Rather than defining (incorrect) global clocks and clock-names lists,
> define them per platform using conditionals. Also, while we are at it,
> mark these properties as required for all platforms for which DT files
> contained clocks/clock-names for the MMCC nodes from the beginning (in
> addition to existing MSM8998 this adds MSM8994, SDM630 and SDM660).
> 
> Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>


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


Best regards,
Krzysztof

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

* Re: [PATCH v2 0/2] dt-bindings: clock: update qcom,mmcc bindings for MSM8996
  2022-07-05 11:27 [PATCH v2 0/2] dt-bindings: clock: update qcom,mmcc bindings for MSM8996 Dmitry Baryshkov
  2022-07-05 11:27 ` [PATCH v2 1/2] dt-bindings: clock: qcom,mmcc: fix clocks/clock-names definitions Dmitry Baryshkov
  2022-07-05 11:27 ` [PATCH v2 2/2] dt-bindings: clock: qcom,mmcc: define clocks/clock-names for MSM8996 Dmitry Baryshkov
@ 2022-08-29 23:45 ` Bjorn Andersson
  2 siblings, 0 replies; 5+ messages in thread
From: Bjorn Andersson @ 2022-08-29 23:45 UTC (permalink / raw)
  To: dmitry.baryshkov, Bjorn Andersson, robh+dt, mturquette,
	konrad.dybcio, quic_tdas, krzysztof.kozlowski+dt, agross, sboyd
  Cc: linux-arm-msm, linux-clk, devicetree

On Tue, 5 Jul 2022 14:27:32 +0300, Dmitry Baryshkov wrote:
> This is a split of binding patches from [1]. When sending the original
> series I missed adding DT maintainers to the CC list, so while all the
> DTS changes were accepted by Bjorn, the dt-bindings were not reviewed
> (and were not taken in).
> 
> Changes since v1:
>  - Moved the first condition block (clocks/clock-names requirement)
>    under the allOf (requested by Krzysztof).
> 
> [...]

Applied, thanks!

[1/2] dt-bindings: clock: qcom,mmcc: fix clocks/clock-names definitions
      commit: 73e66ddfd9984594c1f28fb756e68010924798ed
[2/2] dt-bindings: clock: qcom,mmcc: define clocks/clock-names for MSM8996
      commit: 51b0a5e044a4c49bcaf96c00123d26119da105d7

Best regards,
-- 
Bjorn Andersson <andersson@kernel.org>

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

end of thread, other threads:[~2022-08-29 23:46 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-05 11:27 [PATCH v2 0/2] dt-bindings: clock: update qcom,mmcc bindings for MSM8996 Dmitry Baryshkov
2022-07-05 11:27 ` [PATCH v2 1/2] dt-bindings: clock: qcom,mmcc: fix clocks/clock-names definitions Dmitry Baryshkov
2022-07-05 11:28   ` Krzysztof Kozlowski
2022-07-05 11:27 ` [PATCH v2 2/2] dt-bindings: clock: qcom,mmcc: define clocks/clock-names for MSM8996 Dmitry Baryshkov
2022-08-29 23:45 ` [PATCH v2 0/2] dt-bindings: clock: update qcom,mmcc bindings " Bjorn Andersson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.