power_mgmt: Enhances the DEVICE_INIT_PM macros
Enhances the DEVICE_INIT_PM and SYS_INIT_PM macros so the drivers can avoid #ifdef checks in C code. This also prepares for future merging of the different versions of these macros. Change-Id: I2cc50686a2e2c6bdf675bff8b208f741231c2537 Signed-off-by: Ramesh Thomas <ramesh.thomas@intel.com>
This commit is contained in:
parent
56dded4435
commit
02db5262b8
2 changed files with 62 additions and 20 deletions
|
@ -45,6 +45,9 @@ extern "C" {
|
|||
#define SYS_INIT_PM(drv_name, init_fn, device_pm_ops, level, prio) \
|
||||
DEVICE_INIT_PM(sys_init_##init_fn, drv_name, init_fn, device_pm_ops, \
|
||||
NULL, NULL, level, prio)
|
||||
#else
|
||||
#define SYS_INIT_PM(drv_name, init_fn, device_pm_ops, level, prio) \
|
||||
DEVICE_INIT(sys_init_##init_fn, "", init_fn, NULL, NULL, level, prio)
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue