mirror of
https://github.com/apache/nuttx.git
synced 2026-05-20 20:44:39 +08:00
boardctl: added the option to change the pm state
This commit is contained in:
committed by
Xiang Xiao
parent
ed8fb9d96e
commit
dc31b4f1c1
@@ -258,6 +258,10 @@ static inline int boardctl_pmctrl(FAR struct boardioc_pm_ctrl_s *ctrl)
|
||||
ctrl->state = pm_querystate(ctrl->domain);
|
||||
break;
|
||||
|
||||
case BOARDIOC_PM_CHANGESTATE:
|
||||
ret = pm_changestate(ctrl->domain, ctrl->state);
|
||||
break;
|
||||
|
||||
default:
|
||||
ret = -EINVAL;
|
||||
}
|
||||
|
||||
@@ -225,7 +225,8 @@ enum boardioc_action_e
|
||||
BOARDIOC_PM_STAY,
|
||||
BOARDIOC_PM_RELAX,
|
||||
BOARDIOC_PM_STAYCOUNT,
|
||||
BOARDIOC_PM_QUERYSTATE
|
||||
BOARDIOC_PM_QUERYSTATE,
|
||||
BOARDIOC_PM_CHANGESTATE
|
||||
};
|
||||
|
||||
struct boardioc_pm_ctrl_s
|
||||
|
||||
Reference in New Issue
Block a user