1f8ec8912SLad Prabhakar# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2f8ec8912SLad Prabhakar%YAML 1.2
3f8ec8912SLad Prabhakar---
4f8ec8912SLad Prabhakar$id: "http://devicetree.org/schemas/clock/renesas,rzg2l-cpg.yaml#"
5f8ec8912SLad Prabhakar$schema: "http://devicetree.org/meta-schemas/core.yaml#"
6f8ec8912SLad Prabhakar
7*4a526957SPhil 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
14*4a526957SPhil Edworthy  Standby Mode share the same register block. On RZ/V2M, the functionality is
15*4a526957SPhil 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:
273733db1fSBiju Das      - renesas,r9a07g043-cpg # RZ/G2UL{Type-1,Type-2}
28678eb675SBiju Das      - renesas,r9a07g044-cpg # RZ/G2{L,LC}
29678eb675SBiju Das      - renesas,r9a07g054-cpg # RZ/V2L
30*4a526957SPhil 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
48*4a526957SPhil Edworthy        <dt-bindings/clock/r9a0*-cpg.h>
49f8ec8912SLad Prabhakar      - For module clocks, the two clock specifier cells must be "CPG_MOD" and
50*4a526957SPhil Edworthy        a module number, as defined in the <dt-bindings/clock/r9a07g0*-cpg.h> or
51*4a526957SPhil Edworthy        <dt-bindings/clock/r9a09g011-cpg.h>.
52f8ec8912SLad Prabhakar    const: 2
53f8ec8912SLad Prabhakar
54f8ec8912SLad Prabhakar  '#power-domain-cells':
55f8ec8912SLad Prabhakar    description:
56f8ec8912SLad Prabhakar      SoC devices that are part of the CPG/Module Standby Mode Clock Domain and
57f8ec8912SLad Prabhakar      can be power-managed through Module Standby should refer to the CPG device
58f8ec8912SLad Prabhakar      node in their "power-domains" property, as documented by the generic PM
59f8ec8912SLad Prabhakar      Domain bindings in Documentation/devicetree/bindings/power/power-domain.yaml.
60f8ec8912SLad Prabhakar    const: 0
61f8ec8912SLad Prabhakar
62f8ec8912SLad Prabhakar  '#reset-cells':
63f8ec8912SLad Prabhakar    description:
64f8ec8912SLad Prabhakar      The single reset specifier cell must be the module number, as defined in
65*4a526957SPhil Edworthy      the <dt-bindings/clock/r9a07g0*-cpg.h> or <dt-bindings/clock/r9a09g011-cpg.h>.
66f8ec8912SLad Prabhakar    const: 1
67f8ec8912SLad Prabhakar
68f8ec8912SLad Prabhakarrequired:
69f8ec8912SLad Prabhakar  - compatible
70f8ec8912SLad Prabhakar  - reg
71f8ec8912SLad Prabhakar  - clocks
72f8ec8912SLad Prabhakar  - clock-names
73f8ec8912SLad Prabhakar  - '#clock-cells'
74f8ec8912SLad Prabhakar  - '#power-domain-cells'
75f8ec8912SLad Prabhakar  - '#reset-cells'
76f8ec8912SLad Prabhakar
77f8ec8912SLad PrabhakaradditionalProperties: false
78f8ec8912SLad Prabhakar
79f8ec8912SLad Prabhakarexamples:
80f8ec8912SLad Prabhakar  - |
81f8ec8912SLad Prabhakar    cpg: clock-controller@11010000 {
82f8ec8912SLad Prabhakar            compatible = "renesas,r9a07g044-cpg";
83f8ec8912SLad Prabhakar            reg = <0x11010000 0x10000>;
84f8ec8912SLad Prabhakar            clocks = <&extal_clk>;
85f8ec8912SLad Prabhakar            clock-names = "extal";
86f8ec8912SLad Prabhakar            #clock-cells = <2>;
87f8ec8912SLad Prabhakar            #power-domain-cells = <0>;
88f8ec8912SLad Prabhakar            #reset-cells = <1>;
89f8ec8912SLad Prabhakar    };
90