1f8ec8912SLad Prabhakar# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2f8ec8912SLad Prabhakar%YAML 1.2
3f8ec8912SLad Prabhakar---
4*32671977SRob Herring$id: http://devicetree.org/schemas/clock/renesas,rzg2l-cpg.yaml#
5*32671977SRob Herring$schema: http://devicetree.org/meta-schemas/core.yaml#
6f8ec8912SLad Prabhakar
74a526957SPhil Edworthytitle: Renesas RZ/{G2L,V2L,V2M} Clock Pulse Generator / Module Standby Mode
8f8ec8912SLad Prabhakar
9f8ec8912SLad Prabhakarmaintainers:
10f8ec8912SLad Prabhakar  - Geert Uytterhoeven <geert+renesas@glider.be>
11f8ec8912SLad Prabhakar
12f8ec8912SLad Prabhakardescription: |
133733db1fSBiju Das  On Renesas RZ/{G2L,V2L}-alike SoC's, the CPG (Clock Pulse Generator) and Module
144a526957SPhil Edworthy  Standby Mode share the same register block. On RZ/V2M, the functionality is
154a526957SPhil Edworthy  similar, but does not have Clock Monitor Registers.
16f8ec8912SLad Prabhakar
17f8ec8912SLad Prabhakar  They provide the following functionalities:
18f8ec8912SLad Prabhakar    - The CPG block generates various core clocks,
19f8ec8912SLad Prabhakar    - The Module Standby Mode block provides two functions:
20f8ec8912SLad Prabhakar        1. Module Standby, providing a Clock Domain to control the clock supply
21f8ec8912SLad Prabhakar           to individual SoC devices,
22f8ec8912SLad Prabhakar        2. Reset Control, to perform a software reset of individual SoC devices.
23f8ec8912SLad Prabhakar
24f8ec8912SLad Prabhakarproperties:
25f8ec8912SLad Prabhakar  compatible:
26678eb675SBiju Das    enum:
27e312ae92SLad Prabhakar      - renesas,r9a07g043-cpg # RZ/G2UL{Type-1,Type-2} and RZ/Five
28678eb675SBiju Das      - renesas,r9a07g044-cpg # RZ/G2{L,LC}
29678eb675SBiju Das      - renesas,r9a07g054-cpg # RZ/V2L
304a526957SPhil Edworthy      - renesas,r9a09g011-cpg # RZ/V2M
31f8ec8912SLad Prabhakar
32f8ec8912SLad Prabhakar  reg:
33f8ec8912SLad Prabhakar    maxItems: 1
34f8ec8912SLad Prabhakar
35f8ec8912SLad Prabhakar  clocks:
36f8ec8912SLad Prabhakar    maxItems: 1
37f8ec8912SLad Prabhakar
38f8ec8912SLad Prabhakar  clock-names:
39f8ec8912SLad Prabhakar    description:
40f8ec8912SLad Prabhakar      Clock source to CPG can be either from external clock input (EXCLK) or
41f8ec8912SLad Prabhakar      crystal oscillator (XIN/XOUT).
42f8ec8912SLad Prabhakar    const: extal
43f8ec8912SLad Prabhakar
44f8ec8912SLad Prabhakar  '#clock-cells':
45f8ec8912SLad Prabhakar    description: |
46f8ec8912SLad Prabhakar      - For CPG core clocks, the two clock specifier cells must be "CPG_CORE"
47f8ec8912SLad Prabhakar        and a core clock reference, as defined in
48fc9e0167SGeert Uytterhoeven        <dt-bindings/clock/r9a0*-cpg.h>,
49f8ec8912SLad Prabhakar      - For module clocks, the two clock specifier cells must be "CPG_MOD" and
50fc9e0167SGeert Uytterhoeven        a module number, as defined in <dt-bindings/clock/r9a0*-cpg.h>.
51f8ec8912SLad Prabhakar    const: 2
52f8ec8912SLad Prabhakar
53f8ec8912SLad Prabhakar  '#power-domain-cells':
54f8ec8912SLad Prabhakar    description:
55f8ec8912SLad Prabhakar      SoC devices that are part of the CPG/Module Standby Mode Clock Domain and
56f8ec8912SLad Prabhakar      can be power-managed through Module Standby should refer to the CPG device
57f8ec8912SLad Prabhakar      node in their "power-domains" property, as documented by the generic PM
58f8ec8912SLad Prabhakar      Domain bindings in Documentation/devicetree/bindings/power/power-domain.yaml.
59f8ec8912SLad Prabhakar    const: 0
60f8ec8912SLad Prabhakar
61f8ec8912SLad Prabhakar  '#reset-cells':
62f8ec8912SLad Prabhakar    description:
63f8ec8912SLad Prabhakar      The single reset specifier cell must be the module number, as defined in
64fc9e0167SGeert Uytterhoeven      <dt-bindings/clock/r9a0*-cpg.h>.
65f8ec8912SLad Prabhakar    const: 1
66f8ec8912SLad Prabhakar
67f8ec8912SLad Prabhakarrequired:
68f8ec8912SLad Prabhakar  - compatible
69f8ec8912SLad Prabhakar  - reg
70f8ec8912SLad Prabhakar  - clocks
71f8ec8912SLad Prabhakar  - clock-names
72f8ec8912SLad Prabhakar  - '#clock-cells'
73f8ec8912SLad Prabhakar  - '#power-domain-cells'
74f8ec8912SLad Prabhakar  - '#reset-cells'
75f8ec8912SLad Prabhakar
76f8ec8912SLad PrabhakaradditionalProperties: false
77f8ec8912SLad Prabhakar
78f8ec8912SLad Prabhakarexamples:
79f8ec8912SLad Prabhakar  - |
80f8ec8912SLad Prabhakar    cpg: clock-controller@11010000 {
81f8ec8912SLad Prabhakar            compatible = "renesas,r9a07g044-cpg";
82f8ec8912SLad Prabhakar            reg = <0x11010000 0x10000>;
83f8ec8912SLad Prabhakar            clocks = <&extal_clk>;
84f8ec8912SLad Prabhakar            clock-names = "extal";
85f8ec8912SLad Prabhakar            #clock-cells = <2>;
86f8ec8912SLad Prabhakar            #power-domain-cells = <0>;
87f8ec8912SLad Prabhakar            #reset-cells = <1>;
88f8ec8912SLad Prabhakar    };
89