power: policy: only bring devices to low-power when in sleep mode 2
Sleep mode 1 is supposed to be a low-latency sleep mode where devices are left in active mode. Thus we should only bring devices to low-power when in sleep mode 2 in sys_pm_policy_low_power_devices(). Signed-off-by: Vincent Wan <vincent.wan@linaro.org>
This commit is contained in:
parent
c806947d87
commit
61625366c9
1 changed files with 5 additions and 0 deletions
|
@ -140,3 +140,8 @@ enum power_states sys_pm_policy_next_state(s32_t ticks)
|
|||
LOG_DBG("No suitable power state found!");
|
||||
return SYS_POWER_STATE_ACTIVE;
|
||||
}
|
||||
|
||||
__weak bool sys_pm_policy_low_power_devices(enum power_states pm_state)
|
||||
{
|
||||
return (pm_state == SYS_POWER_STATE_SLEEP_2);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue