regulator: Document binding for regulator suspend voltage
[cascardo/linux.git] / Documentation / devicetree / bindings / regulator / regulator.txt
1 Voltage/Current Regulators
2
3 Optional properties:
4 - regulator-name: A string used as a descriptive name for regulator outputs
5 - regulator-min-microvolt: smallest voltage consumers may set
6 - regulator-max-microvolt: largest voltage consumers may set
7 - regulator-microvolt-offset: Offset applied to voltages to compensate for voltage drops
8 - regulator-min-microamp: smallest current consumers may set
9 - regulator-max-microamp: largest current consumers may set
10 - regulator-always-on: boolean, regulator should never be disabled
11 - regulator-boot-on: bootloader/firmware enabled regulator
12 - regulator-allow-bypass: allow the regulator to go into bypass mode
13 - <name>-supply: phandle to the parent supply/regulator node
14 - regulator-ramp-delay: ramp delay for regulator(in uV/uS)
15   For hardware which supports disabling ramp rate, it should be explicitly
16   intialised to zero (regulator-ramp-delay = <0>) for disabling ramp delay.
17 - regulator-enable-ramp-delay: The time taken, in microseconds, for the supply
18   rail to reach the target voltage, plus/minus whatever tolerance the board
19   design requires. This property describes the total system ramp time
20   required due to the combination of internal ramping of the regulator itself,
21   and board design issues such as trace capacitance and load on the supply.
22 - regulator-state-mem sub-root node for Suspend-to-RAM mode
23   : suspend to memory, the device goes to sleep, but all data stored in memory,
24   only some external interrupt can wake the device.
25 - regulator-state-disk sub-root node for Suspend-to-DISK mode
26   : suspend to disk, this state operates similarly to Suspend-to-RAM,
27   but includes a final step of writing memory contents to disk.
28 - regulator-state-[mem/disk] node has following common properties:
29         - regulator-on-in-suspend: regulator should be on in suspend state.
30         - regulator-off-in-suspend: regulator should be off in suspend state.
31         - regulator-suspend-microvolt: regulator should be set to this voltage
32           in suspend.
33
34 Deprecated properties:
35 - regulator-compatible: If a regulator chip contains multiple
36   regulators, and if the chip's binding contains a child node that
37   describes each regulator, then this property indicates which regulator
38   this child node is intended to configure. If this property is missing,
39   the node's name will be used instead.
40
41 Example:
42
43         xyzreg: regulator@0 {
44                 regulator-min-microvolt = <1000000>;
45                 regulator-max-microvolt = <2500000>;
46                 regulator-always-on;
47                 vin-supply = <&vin>;
48
49                 regulator-state-mem {
50                         regulator-on-in-suspend;
51                 };
52         };
53
54 Regulator Consumers:
55 Consumer nodes can reference one or more of its supplies/
56 regulators using the below bindings.
57
58 - <name>-supply: phandle to the regulator node
59
60 These are the same bindings that a regulator in the above
61 example used to reference its own supply, in which case
62 its just seen as a special case of a regulator being a
63 consumer itself.
64
65 Example of a consumer device node (mmc) referencing two
66 regulators (twl_reg1 and twl_reg2),
67
68         twl_reg1: regulator@0 {
69                 ...
70                 ...
71                 ...
72         };
73
74         twl_reg2: regulator@1 {
75                 ...
76                 ...
77                 ...
78         };
79
80         mmc: mmc@0x0 {
81                 ...
82                 ...
83                 vmmc-supply = <&twl_reg1>;
84                 vmmcaux-supply = <&twl_reg2>;
85         };