Skip to content
Commit 84016c1c authored by Jordan Yates's avatar Jordan Yates Committed by Carles Cufí
Browse files

pm: device: add driver init helper



Adds a helper function for initializing devices into the expected power
state, through the devices `pm_device_action_cb_t`. This eliminates code
duplication between the init functions and the PM callback.

The expected device states in order of priority are:
 * No power applied to device, `OFF`
 * `zephyr,pm-device-runtime-auto` enabled, `SUSPEND`
 * Otherwise, `ACTIVE`

Signed-off-by: default avatarJordan Yates <jordan.yates@data61.csiro.au>
parent c72577d7
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment