device_pm: Update control function name and doc to indicate PM specific

PM control function is used only by the PM subsystem. Update
documentations to make it clear and name the relevant structures and
functions with _pm_ in the name.

Jira: ZEP-1044
Change-Id: I29e5b7690db34a228ed30a24a2e912e1360a0090
Signed-off-by: Ramesh Thomas <ramesh.thomas@intel.com>
This commit is contained in:
Ramesh Thomas 2016-10-07 17:07:04 -07:00 committed by Anas Nashif
commit 6249c567f5
4 changed files with 34 additions and 19 deletions

View file

@ -63,6 +63,9 @@ extern "C" {
/**
* @def SYS_INIT_PM
*
* @warning This macro is deprecated and will be removed in
* a future version, superseded by SYS_DEVICE_DEFINE.
*
* @brief Run an initialization function at boot at specified priority,
* and define functions to run at suspend/resume.
*
@ -80,8 +83,19 @@ extern "C" {
DEVICE_INIT(_SYS_NAME(init_fn), "", init_fn, NULL, NULL, level, prio)
#endif
#define SYS_DEVICE_DEFINE(drv_name, init_fn, control_fn, level, prio) \
DEVICE_DEFINE(_SYS_NAME(init_fn), drv_name, init_fn, control_fn, \
/**
* @def SYS_DEVICE_DEFINE
*
* @brief Run an initialization function at boot at specified priority,
* and define device PM control function.
*
* @copydetails SYS_INIT
* @param pm_control_fn Pointer to device_pm_control function.
* Can be empty function (device_pm_control_nop) if not implemented.
* @param drv_name Name of this system device
*/
#define SYS_DEVICE_DEFINE(drv_name, init_fn, pm_control_fn, level, prio) \
DEVICE_DEFINE(_SYS_NAME(init_fn), drv_name, init_fn, pm_control_fn, \
NULL, NULL, level, prio, NULL)
#ifdef __cplusplus