power_mgmt: Update Power Management device driver API
Have one function that can be used for all possible device purposes using a control code instead of the suspend resume functions, makes it generic for device control. Added device power states. The older replaced APIs will be deprecated in a future patch Jira: ZEP-954 Change-Id: I6dd3ebfd0fde3546b2d8397f19842f5758fda0c4 Signed-off-by: Amir Kaplan <amir.kaplan@intel.com>
This commit is contained in:
parent
035ec8249d
commit
d305da61e9
3 changed files with 152 additions and 10 deletions
|
@ -75,6 +75,10 @@ extern "C" {
|
|||
DEVICE_INIT(sys_init_##init_fn, "", init_fn, NULL, NULL, level, prio)
|
||||
#endif
|
||||
|
||||
#define SYS_DEVICE_DEFINE(drv_name, init_fn, control_fn, level, prio) \
|
||||
DEVICE_DEFINE(sys_init_##init_fn, drv_name, init_fn, control_fn, \
|
||||
NULL, NULL, level, prio, NULL)
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue