1
0
Fork 0

MLK-17074-3 PM / Domains: use default state 0 to enter for multi states domains

If no valid state idx specified by governor, we use the default state_idx
0 to enter in case the domain has multi low power states.

Reviewed-by: Frank Li <frank.li@nxp.com>
Reviewed-by: Ranjani Vaidyanathan <Ranjani.Vaidyanathan@nxp.com>
Signed-off-by: Dong Aisheng <aisheng.dong@nxp.com>
pull/10/head
Dong Aisheng 2017-11-30 17:32:08 +08:00 committed by Jason Liu
parent 7063b2a554
commit e9b6caf0f4
1 changed files with 7 additions and 0 deletions

View File

@ -373,6 +373,13 @@ static int genpd_power_off(struct generic_pm_domain *genpd, bool one_dev_on,
if (genpd->gov && genpd->gov->power_down_ok) {
if (!genpd->gov->power_down_ok(&genpd->domain))
return -EAGAIN;
} else {
/*
* if no valid state idx specified by governor, we use
* the default state_idx 0 to enter in case the domain
* has multi low power states.
*/
genpd->state_idx = 0;
}
if (genpd->power_off) {