xref: /freebsd/sys/contrib/device-tree/Bindings/clock/renesas,emev2-smu.yaml (revision 5956d97f4b3204318ceb6aa9c77bd0bc6ea87a41)
1*5956d97fSEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2*5956d97fSEmmanuel Vadot%YAML 1.2
3*5956d97fSEmmanuel Vadot---
4*5956d97fSEmmanuel Vadot$id: http://devicetree.org/schemas/clock/renesas,emev2-smu.yaml#
5*5956d97fSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
6*5956d97fSEmmanuel Vadot
7*5956d97fSEmmanuel Vadottitle: Renesas EMMA Mobile EV2 System Management Unit
8*5956d97fSEmmanuel Vadot
9*5956d97fSEmmanuel Vadotmaintainers:
10*5956d97fSEmmanuel Vadot  - Geert Uytterhoeven <geert+renesas@glider.be>
11*5956d97fSEmmanuel Vadot  - Magnus Damm <magnus.damm@gmail.com>
12*5956d97fSEmmanuel Vadot
13*5956d97fSEmmanuel Vadotdescription: |
14*5956d97fSEmmanuel Vadot  The System Management Unit is described in user's manual R19UH0037EJ1000_SMU.
15*5956d97fSEmmanuel Vadot  This is not a clock provider, but clocks under SMU depend on it.
16*5956d97fSEmmanuel Vadot
17*5956d97fSEmmanuel Vadotproperties:
18*5956d97fSEmmanuel Vadot  compatible:
19*5956d97fSEmmanuel Vadot    const: renesas,emev2-smu
20*5956d97fSEmmanuel Vadot
21*5956d97fSEmmanuel Vadot  reg:
22*5956d97fSEmmanuel Vadot    maxItems: 1
23*5956d97fSEmmanuel Vadot
24*5956d97fSEmmanuel Vadot  '#address-cells':
25*5956d97fSEmmanuel Vadot    const: 2
26*5956d97fSEmmanuel Vadot
27*5956d97fSEmmanuel Vadot  '#size-cells':
28*5956d97fSEmmanuel Vadot    const: 0
29*5956d97fSEmmanuel Vadot
30*5956d97fSEmmanuel Vadotrequired:
31*5956d97fSEmmanuel Vadot  - compatible
32*5956d97fSEmmanuel Vadot  - reg
33*5956d97fSEmmanuel Vadot  - '#address-cells'
34*5956d97fSEmmanuel Vadot  - '#size-cells'
35*5956d97fSEmmanuel Vadot
36*5956d97fSEmmanuel VadotpatternProperties:
37*5956d97fSEmmanuel Vadot  ".*sclkdiv@.*":
38*5956d97fSEmmanuel Vadot    type: object
39*5956d97fSEmmanuel Vadot
40*5956d97fSEmmanuel Vadot    description: |
41*5956d97fSEmmanuel Vadot      Function block with an input mux and a divider, which corresponds to
42*5956d97fSEmmanuel Vadot      "Serial clock generator" in fig. "Clock System Overview" of the manual,
43*5956d97fSEmmanuel Vadot      and "xxx frequency division setting register" (XXXCLKDIV) registers.
44*5956d97fSEmmanuel Vadot      This makes internal (neither input nor output) clock that is provided
45*5956d97fSEmmanuel Vadot      to input of xxxGCLK block.
46*5956d97fSEmmanuel Vadot
47*5956d97fSEmmanuel Vadot    properties:
48*5956d97fSEmmanuel Vadot      compatible:
49*5956d97fSEmmanuel Vadot        const: renesas,emev2-smu-clkdiv
50*5956d97fSEmmanuel Vadot
51*5956d97fSEmmanuel Vadot      reg:
52*5956d97fSEmmanuel Vadot        maxItems: 1
53*5956d97fSEmmanuel Vadot        description:
54*5956d97fSEmmanuel Vadot          Byte offset from SMU base and Bit position in the register.
55*5956d97fSEmmanuel Vadot
56*5956d97fSEmmanuel Vadot      clocks:
57*5956d97fSEmmanuel Vadot        minItems: 1
58*5956d97fSEmmanuel Vadot        maxItems: 4
59*5956d97fSEmmanuel Vadot
60*5956d97fSEmmanuel Vadot      '#clock-cells':
61*5956d97fSEmmanuel Vadot        const: 0
62*5956d97fSEmmanuel Vadot
63*5956d97fSEmmanuel Vadot    required:
64*5956d97fSEmmanuel Vadot      - compatible
65*5956d97fSEmmanuel Vadot      - reg
66*5956d97fSEmmanuel Vadot      - clocks
67*5956d97fSEmmanuel Vadot      - '#clock-cells'
68*5956d97fSEmmanuel Vadot
69*5956d97fSEmmanuel Vadot    additionalProperties: false
70*5956d97fSEmmanuel Vadot
71*5956d97fSEmmanuel Vadot  ".*sclk@.*":
72*5956d97fSEmmanuel Vadot    type: object
73*5956d97fSEmmanuel Vadot
74*5956d97fSEmmanuel Vadot    description: |
75*5956d97fSEmmanuel Vadot      Clock gating node shown as "Clock stop processing block" in the
76*5956d97fSEmmanuel Vadot      fig. "Clock System Overview" of the manual.
77*5956d97fSEmmanuel Vadot      Registers are "xxx clock gate control register" (XXXGCLKCTRL).
78*5956d97fSEmmanuel Vadot
79*5956d97fSEmmanuel Vadot    properties:
80*5956d97fSEmmanuel Vadot      compatible:
81*5956d97fSEmmanuel Vadot        const: renesas,emev2-smu-gclk
82*5956d97fSEmmanuel Vadot
83*5956d97fSEmmanuel Vadot      reg:
84*5956d97fSEmmanuel Vadot        maxItems: 1
85*5956d97fSEmmanuel Vadot        description:
86*5956d97fSEmmanuel Vadot          Byte offset from SMU base and Bit position in the register.
87*5956d97fSEmmanuel Vadot
88*5956d97fSEmmanuel Vadot      clocks:
89*5956d97fSEmmanuel Vadot        maxItems: 1
90*5956d97fSEmmanuel Vadot
91*5956d97fSEmmanuel Vadot      '#clock-cells':
92*5956d97fSEmmanuel Vadot        const: 0
93*5956d97fSEmmanuel Vadot
94*5956d97fSEmmanuel Vadot    required:
95*5956d97fSEmmanuel Vadot      - compatible
96*5956d97fSEmmanuel Vadot      - reg
97*5956d97fSEmmanuel Vadot      - clocks
98*5956d97fSEmmanuel Vadot      - '#clock-cells'
99*5956d97fSEmmanuel Vadot
100*5956d97fSEmmanuel Vadot    additionalProperties: false
101*5956d97fSEmmanuel Vadot
102*5956d97fSEmmanuel VadotadditionalProperties: true
103*5956d97fSEmmanuel Vadot
104*5956d97fSEmmanuel Vadotexamples:
105*5956d97fSEmmanuel Vadot  - |
106*5956d97fSEmmanuel Vadot    // Example of clock-tree description:
107*5956d97fSEmmanuel Vadot    //
108*5956d97fSEmmanuel Vadot    //  This describes a clock path in the clock tree
109*5956d97fSEmmanuel Vadot    //   c32ki -> pll3_fo -> usia_u0_sclkdiv -> usia_u0_sclk
110*5956d97fSEmmanuel Vadot    clocks@e0110000 {
111*5956d97fSEmmanuel Vadot            compatible = "renesas,emev2-smu";
112*5956d97fSEmmanuel Vadot            reg = <0xe0110000 0x10000>;
113*5956d97fSEmmanuel Vadot            #address-cells = <2>;
114*5956d97fSEmmanuel Vadot            #size-cells = <0>;
115*5956d97fSEmmanuel Vadot
116*5956d97fSEmmanuel Vadot            c32ki: c32ki {
117*5956d97fSEmmanuel Vadot                    compatible = "fixed-clock";
118*5956d97fSEmmanuel Vadot                    clock-frequency = <32768>;
119*5956d97fSEmmanuel Vadot                    #clock-cells = <0>;
120*5956d97fSEmmanuel Vadot            };
121*5956d97fSEmmanuel Vadot            pll3_fo: pll3_fo {
122*5956d97fSEmmanuel Vadot                    compatible = "fixed-factor-clock";
123*5956d97fSEmmanuel Vadot                    clocks = <&c32ki>;
124*5956d97fSEmmanuel Vadot                    clock-div = <1>;
125*5956d97fSEmmanuel Vadot                    clock-mult = <7000>;
126*5956d97fSEmmanuel Vadot                    #clock-cells = <0>;
127*5956d97fSEmmanuel Vadot            };
128*5956d97fSEmmanuel Vadot            usia_u0_sclkdiv: usia_u0_sclkdiv@610,0 {
129*5956d97fSEmmanuel Vadot                    compatible = "renesas,emev2-smu-clkdiv";
130*5956d97fSEmmanuel Vadot                    reg = <0x610 0>;
131*5956d97fSEmmanuel Vadot                    clocks = <&pll3_fo>;
132*5956d97fSEmmanuel Vadot                    #clock-cells = <0>;
133*5956d97fSEmmanuel Vadot            };
134*5956d97fSEmmanuel Vadot            usia_u0_sclk: usia_u0_sclk@4a0,1 {
135*5956d97fSEmmanuel Vadot                    compatible = "renesas,emev2-smu-gclk";
136*5956d97fSEmmanuel Vadot                    reg = <0x4a0 1>;
137*5956d97fSEmmanuel Vadot                    clocks = <&usia_u0_sclkdiv>;
138*5956d97fSEmmanuel Vadot                    #clock-cells = <0>;
139*5956d97fSEmmanuel Vadot            };
140*5956d97fSEmmanuel Vadot    };
141