diff mbox series

[v8,2/4] dt-bindings: clock: Convert qcom,mmcc to DT schema

Message ID 1573255053-10351-1-git-send-email-jhugo@codeaurora.org (mailing list archive)
State Superseded
Headers show
Series MSM8998 Multimedia Clock Controller | expand

Commit Message

Jeffrey Hugo Nov. 8, 2019, 11:17 p.m. UTC
Convert the qcom,mmcc-X clock controller binding to DT schema.

Signed-off-by: Jeffrey Hugo <jhugo@codeaurora.org>
---
 .../devicetree/bindings/clock/qcom,mmcc.txt        | 28 ----------
 .../devicetree/bindings/clock/qcom,mmcc.yaml       | 59 ++++++++++++++++++++++
 2 files changed, 59 insertions(+), 28 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/clock/qcom,mmcc.txt
 create mode 100644 Documentation/devicetree/bindings/clock/qcom,mmcc.yaml

Comments

Rob Herring (Arm) Nov. 12, 2019, 12:58 a.m. UTC | #1
On Fri, Nov 08, 2019 at 04:17:33PM -0700, Jeffrey Hugo wrote:
> Convert the qcom,mmcc-X clock controller binding to DT schema.
> 
> Signed-off-by: Jeffrey Hugo <jhugo@codeaurora.org>
> ---
>  .../devicetree/bindings/clock/qcom,mmcc.txt        | 28 ----------
>  .../devicetree/bindings/clock/qcom,mmcc.yaml       | 59 ++++++++++++++++++++++
>  2 files changed, 59 insertions(+), 28 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/clock/qcom,mmcc.txt
>  create mode 100644 Documentation/devicetree/bindings/clock/qcom,mmcc.yaml
> 
> diff --git a/Documentation/devicetree/bindings/clock/qcom,mmcc.txt b/Documentation/devicetree/bindings/clock/qcom,mmcc.txt
> deleted file mode 100644
> index 8b0f784..0000000
> --- a/Documentation/devicetree/bindings/clock/qcom,mmcc.txt
> +++ /dev/null
> @@ -1,28 +0,0 @@
> -Qualcomm Multimedia Clock & Reset Controller Binding
> -----------------------------------------------------
> -
> -Required properties :
> -- compatible : shall contain only one of the following:
> -
> -			"qcom,mmcc-apq8064"
> -			"qcom,mmcc-apq8084"
> -			"qcom,mmcc-msm8660"
> -			"qcom,mmcc-msm8960"
> -			"qcom,mmcc-msm8974"
> -			"qcom,mmcc-msm8996"
> -
> -- reg : shall contain base register location and length
> -- #clock-cells : shall contain 1
> -- #reset-cells : shall contain 1
> -
> -Optional properties :
> -- #power-domain-cells : shall contain 1
> -
> -Example:
> -	clock-controller@4000000 {
> -		compatible = "qcom,mmcc-msm8960";
> -		reg = <0x4000000 0x1000>;
> -		#clock-cells = <1>;
> -		#reset-cells = <1>;
> -		#power-domain-cells = <1>;
> -	};
> diff --git a/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml b/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml
> new file mode 100644
> index 0000000..61ed4a2
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml
> @@ -0,0 +1,59 @@
> +# SPDX-License-Identifier: GPL-2.0-only
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/bindings/clock/qcom,mmcc.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Qualcomm Multimedia Clock & Reset Controller Binding
> +
> +maintainers:
> +  - Jeffrey Hugo <jhugo@codeaurora.org>
> +
> +description: |
> +  Qualcomm multimedia clock control module which supports the clocks, resets and
> +  power domains.
> +
> +properties:
> +  compatible :
> +    enum:
> +       - qcom,mmcc-apq8064
> +       - qcom,mmcc-apq8084
> +       - qcom,mmcc-msm8660
> +       - qcom,mmcc-msm8960
> +       - qcom,mmcc-msm8974
> +       - qcom,mmcc-msm8996
> +
> +  '#clock-cells':
> +    const: 1
> +
> +  '#reset-cells':
> +    const: 1
> +
> +  '#power-domain-cells':
> +    const: 1
> +
> +  reg:
> +    maxItems: 1
> +
> +  protected-clocks:
> +    description:
> +       Protected clock specifier list as per common clock binding

Wasn't documented before. Okay to add here, but mention it in the commit 
msg.

> +
> +required:
> +  - compatible
> +  - reg
> +  - '#clock-cells'
> +  - '#reset-cells'
> +  - '#power-domain-cells'
> +
> +examples:
> +  # Example for MMCC for MSM8960:
> +  - |
> +    clock-controller@4000000 {
> +      compatible = "qcom,mmcc-msm8960";
> +      reg = <0x4000000 0x1000>;
> +      #clock-cells = <1>;
> +      #reset-cells = <1>;
> +      #power-domain-cells = <1>;
> +    };
> +...
> -- 
> Qualcomm Technologies, Inc. is a member of the
> Code Aurora Forum, a Linux Foundation Collaborative Project.
>
Jeffrey Hugo Nov. 12, 2019, 4:11 p.m. UTC | #2
On 11/11/2019 5:58 PM, Rob Herring wrote:
> On Fri, Nov 08, 2019 at 04:17:33PM -0700, Jeffrey Hugo wrote:
>> Convert the qcom,mmcc-X clock controller binding to DT schema.
>>
>> Signed-off-by: Jeffrey Hugo <jhugo@codeaurora.org>
>> ---
>>   .../devicetree/bindings/clock/qcom,mmcc.txt        | 28 ----------
>>   .../devicetree/bindings/clock/qcom,mmcc.yaml       | 59 ++++++++++++++++++++++
>>   2 files changed, 59 insertions(+), 28 deletions(-)
>>   delete mode 100644 Documentation/devicetree/bindings/clock/qcom,mmcc.txt
>>   create mode 100644 Documentation/devicetree/bindings/clock/qcom,mmcc.yaml
>>
>> diff --git a/Documentation/devicetree/bindings/clock/qcom,mmcc.txt b/Documentation/devicetree/bindings/clock/qcom,mmcc.txt
>> deleted file mode 100644
>> index 8b0f784..0000000
>> --- a/Documentation/devicetree/bindings/clock/qcom,mmcc.txt
>> +++ /dev/null
>> @@ -1,28 +0,0 @@
>> -Qualcomm Multimedia Clock & Reset Controller Binding
>> -----------------------------------------------------
>> -
>> -Required properties :
>> -- compatible : shall contain only one of the following:
>> -
>> -			"qcom,mmcc-apq8064"
>> -			"qcom,mmcc-apq8084"
>> -			"qcom,mmcc-msm8660"
>> -			"qcom,mmcc-msm8960"
>> -			"qcom,mmcc-msm8974"
>> -			"qcom,mmcc-msm8996"
>> -
>> -- reg : shall contain base register location and length
>> -- #clock-cells : shall contain 1
>> -- #reset-cells : shall contain 1
>> -
>> -Optional properties :
>> -- #power-domain-cells : shall contain 1
>> -
>> -Example:
>> -	clock-controller@4000000 {
>> -		compatible = "qcom,mmcc-msm8960";
>> -		reg = <0x4000000 0x1000>;
>> -		#clock-cells = <1>;
>> -		#reset-cells = <1>;
>> -		#power-domain-cells = <1>;
>> -	};
>> diff --git a/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml b/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml
>> new file mode 100644
>> index 0000000..61ed4a2
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml
>> @@ -0,0 +1,59 @@
>> +# SPDX-License-Identifier: GPL-2.0-only
>> +%YAML 1.2
>> +---
>> +$id: http://devicetree.org/schemas/bindings/clock/qcom,mmcc.yaml#
>> +$schema: http://devicetree.org/meta-schemas/core.yaml#
>> +
>> +title: Qualcomm Multimedia Clock & Reset Controller Binding
>> +
>> +maintainers:
>> +  - Jeffrey Hugo <jhugo@codeaurora.org>
>> +
>> +description: |
>> +  Qualcomm multimedia clock control module which supports the clocks, resets and
>> +  power domains.
>> +
>> +properties:
>> +  compatible :
>> +    enum:
>> +       - qcom,mmcc-apq8064
>> +       - qcom,mmcc-apq8084
>> +       - qcom,mmcc-msm8660
>> +       - qcom,mmcc-msm8960
>> +       - qcom,mmcc-msm8974
>> +       - qcom,mmcc-msm8996
>> +
>> +  '#clock-cells':
>> +    const: 1
>> +
>> +  '#reset-cells':
>> +    const: 1
>> +
>> +  '#power-domain-cells':
>> +    const: 1
>> +
>> +  reg:
>> +    maxItems: 1
>> +
>> +  protected-clocks:
>> +    description:
>> +       Protected clock specifier list as per common clock binding
> 
> Wasn't documented before. Okay to add here, but mention it in the commit
> msg.

Its a generic property that applies to all providers.  In the non-yaml 
bindings, its was documented in the clock-binding.txt, thus implicitly 
documented for all the bindings.  That doesn't work in yaml, so I'm 
making it explicit here (following the GCC bindings you already 
approved).  Nothing changes.

> 
>> +
>> +required:
>> +  - compatible
>> +  - reg
>> +  - '#clock-cells'
>> +  - '#reset-cells'
>> +  - '#power-domain-cells'
>> +
>> +examples:
>> +  # Example for MMCC for MSM8960:
>> +  - |
>> +    clock-controller@4000000 {
>> +      compatible = "qcom,mmcc-msm8960";
>> +      reg = <0x4000000 0x1000>;
>> +      #clock-cells = <1>;
>> +      #reset-cells = <1>;
>> +      #power-domain-cells = <1>;
>> +    };
>> +...
>> -- 
>> Qualcomm Technologies, Inc. is a member of the
>> Code Aurora Forum, a Linux Foundation Collaborative Project.
>>
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/clock/qcom,mmcc.txt b/Documentation/devicetree/bindings/clock/qcom,mmcc.txt
deleted file mode 100644
index 8b0f784..0000000
--- a/Documentation/devicetree/bindings/clock/qcom,mmcc.txt
+++ /dev/null
@@ -1,28 +0,0 @@ 
-Qualcomm Multimedia Clock & Reset Controller Binding
-----------------------------------------------------
-
-Required properties :
-- compatible : shall contain only one of the following:
-
-			"qcom,mmcc-apq8064"
-			"qcom,mmcc-apq8084"
-			"qcom,mmcc-msm8660"
-			"qcom,mmcc-msm8960"
-			"qcom,mmcc-msm8974"
-			"qcom,mmcc-msm8996"
-
-- reg : shall contain base register location and length
-- #clock-cells : shall contain 1
-- #reset-cells : shall contain 1
-
-Optional properties :
-- #power-domain-cells : shall contain 1
-
-Example:
-	clock-controller@4000000 {
-		compatible = "qcom,mmcc-msm8960";
-		reg = <0x4000000 0x1000>;
-		#clock-cells = <1>;
-		#reset-cells = <1>;
-		#power-domain-cells = <1>;
-	};
diff --git a/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml b/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml
new file mode 100644
index 0000000..61ed4a2
--- /dev/null
+++ b/Documentation/devicetree/bindings/clock/qcom,mmcc.yaml
@@ -0,0 +1,59 @@ 
+# SPDX-License-Identifier: GPL-2.0-only
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/bindings/clock/qcom,mmcc.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Qualcomm Multimedia Clock & Reset Controller Binding
+
+maintainers:
+  - Jeffrey Hugo <jhugo@codeaurora.org>
+
+description: |
+  Qualcomm multimedia clock control module which supports the clocks, resets and
+  power domains.
+
+properties:
+  compatible :
+    enum:
+       - qcom,mmcc-apq8064
+       - qcom,mmcc-apq8084
+       - qcom,mmcc-msm8660
+       - qcom,mmcc-msm8960
+       - qcom,mmcc-msm8974
+       - qcom,mmcc-msm8996
+
+  '#clock-cells':
+    const: 1
+
+  '#reset-cells':
+    const: 1
+
+  '#power-domain-cells':
+    const: 1
+
+  reg:
+    maxItems: 1
+
+  protected-clocks:
+    description:
+       Protected clock specifier list as per common clock binding
+
+required:
+  - compatible
+  - reg
+  - '#clock-cells'
+  - '#reset-cells'
+  - '#power-domain-cells'
+
+examples:
+  # Example for MMCC for MSM8960:
+  - |
+    clock-controller@4000000 {
+      compatible = "qcom,mmcc-msm8960";
+      reg = <0x4000000 0x1000>;
+      #clock-cells = <1>;
+      #reset-cells = <1>;
+      #power-domain-cells = <1>;
+    };
+...