]> git.kernelconcepts.de Git - karo-tx-linux.git/blob - Documentation/devicetree/bindings/regulator/pwm-regulator.txt
Merge branch 'cpuidle' into release
[karo-tx-linux.git] / Documentation / devicetree / bindings / regulator / pwm-regulator.txt
1 Bindings for the Generic PWM Regulator
2 ======================================
3
4 Currently supports 2 modes of operation:
5
6 Voltage Table:          When in this mode, a voltage table (See below) of
7                         predefined voltage <=> duty-cycle values must be
8                         provided via DT. Limitations are that the regulator can
9                         only operate at the voltages supplied in the table.
10                         Intermediary duty-cycle values which would normally
11                         allow finer grained voltage selection are ignored and
12                         rendered useless.  Although more control is given to
13                         the user if the assumptions made in continuous-voltage
14                         mode do not reign true.
15
16 Continuous Voltage:     This mode uses the regulator's maximum and minimum
17                         supplied voltages specified in the
18                         regulator-{min,max}-microvolt properties to calculate
19                         appropriate duty-cycle values.  This allows for a much
20                         more fine grained solution when compared with
21                         voltage-table mode above.  This solution does make an
22                         assumption that a %50 duty-cycle value will cause the
23                         regulator voltage to run at half way between the
24                         supplied max_uV and min_uV values.
25
26 Required properties:
27 --------------------
28 - compatible:           Should be "pwm-regulator"
29
30 - pwms:                 PWM specification (See: ../pwm/pwm.txt)
31
32 Only required for Voltage Table Mode:
33 - voltage-table:        Voltage and Duty-Cycle table consisting of 2 cells
34                             First cell is voltage in microvolts (uV)
35                             Second cell is duty-cycle in percent (%)
36
37 NB: To be clear, if voltage-table is provided, then the device will be used
38 in Voltage Table Mode.  If no voltage-table is provided, then the device will
39 be used in Continuous Voltage Mode.
40
41 Any property defined as part of the core regulator binding can also be used.
42 (See: ../regulator/regulator.txt)
43
44 Continuous Voltage Example:
45         pwm_regulator {
46                 compatible = "pwm-regulator;
47                 pwms = <&pwm1 0 8448 0>;
48                 regulator-min-microvolt = <1016000>;
49                 regulator-max-microvolt = <1114000>;
50                 regulator-name = "vdd_logic";
51         };
52
53 Voltage Table Example:
54         pwm_regulator {
55                 compatible = "pwm-regulator;
56                 pwms = <&pwm1 0 8448 0>;
57                 regulator-min-microvolt = <1016000>;
58                 regulator-max-microvolt = <1114000>;
59                 regulator-name = "vdd_logic";
60
61                               /* Voltage Duty-Cycle */
62                 voltage-table = <1114000 0>,
63                                 <1095000 10>,
64                                 <1076000 20>,
65                                 <1056000 30>,
66                                 <1036000 40>,
67                                 <1016000 50>;
68         };