Lines Matching +full:power +full:- +full:on
1 .. _pm-power-domain:
3 Power Domain
9 The Zephyr power domain abstraction is designed to support groupings of devices
10 powered by a common source to be notified of power source state changes in a
12 that device B is on the same power domain and should also be configured into a
13 low power state.
15 Power domains are optional on Zephyr, to enable this feature the
18 When a power domain turns itself on or off, it is the responsibility of the
19 power domain to notify all devices using it through their power management
25 .. _pm-domain-work-flow:
28 :caption: Power domain work flow
42 action -> devA [label="pm_device_get()"]
43 devA:se -> domain:n [label="pm_device_get()"]
45 domain -> devB [label="action_cb(PM_DEVICE_ACTION_TURN_ON)"]
46 domain:sw -> devA:sw [label="action_cb(PM_DEVICE_ACTION_TURN_ON)"]
49 Internal Power Domains
50 ----------------------
52 Most of the devices in an SoC have independent power control that can
53 be turned on or off to reduce power consumption. But there is a
55 only using device power management. To solve this problem, SoCs
59 called "power domains", can be present in a hierarchy and can be
62 External Power Domains
63 ----------------------
65 Devices external to a SoC can be powered from sources other than the main power
67 or a dedicated power IC. Multiple devices can be powered from the same source,
68 and this grouping of devices is typically called a "power domain".
70 Placing devices on power domains can be done for a variety of reasons,
71 including to enable devices with high power consumption in low power mode to be
77 In a first place, a device that acts as a power domain needs to
78 declare compatible with ``power-domain``. Taking
79 :ref:`pm-domain-work-flow` as example, the following code defines a
82 .. code-block:: devicetree
85 compatible = "power-domain";
89 A power domain needs to implement the PM action callback used by the
90 PM subsystem to turn devices on and off.
92 .. code-block:: c
111 /* turn on the domain (e.g. setup control pins to disabled) */
119 return -ENOTSUP;
126 ``power-domain`` node's property. The example below declares devices
129 .. code-block:: devicetree
132 compatible = "zephyr,gpio-emul";
133 gpio-controller;
134 power-domains = <&gpio_domain>;
138 compatible = "zephyr,gpio-emul";
139 gpio-controller;
140 power-domains = <&gpio_domain>;
148 .. code-block:: c
163 /* configure the device into low power mode */
167 /* prepare the device for power down */
171 return -ENOTSUP;
180 "wakeup" source if a device depending on it is used as "wakeup" source.
185 Some helpful examples showing power domain features: