diff options
author | Rafael J. Wysocki <rjw@sisk.pl> | 2011-11-30 18:02:05 -0500 |
---|---|---|
committer | Rafael J. Wysocki <rjw@sisk.pl> | 2011-12-01 15:47:40 -0500 |
commit | b02c999ac325e977585abeb4caf6e0a2ee21e30b (patch) | |
tree | 1ddec5f020a80b9df443b03ffb578ef7f882abb6 /arch/arm | |
parent | d23b9b00cdde5c93b914a172cecd57d5625fcd04 (diff) |
PM / Domains: Add device stop governor function (v4)
Add a function deciding whether or not devices should be stopped in
pm_genpd_runtime_suspend() depending on their PM QoS constraints
and stop/start timing values. Make it possible to add information
used by this function to device objects.
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Acked-by: Magnus Damm <damm@opensource.se>
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/mach-shmobile/pm-sh7372.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/arm/mach-shmobile/pm-sh7372.c b/arch/arm/mach-shmobile/pm-sh7372.c index 6777bb1be059..adf1765e69c6 100644 --- a/arch/arm/mach-shmobile/pm-sh7372.c +++ b/arch/arm/mach-shmobile/pm-sh7372.c | |||
@@ -169,6 +169,7 @@ static bool sh7372_power_down_forbidden(struct dev_pm_domain *domain) | |||
169 | 169 | ||
170 | struct dev_power_governor sh7372_always_on_gov = { | 170 | struct dev_power_governor sh7372_always_on_gov = { |
171 | .power_down_ok = sh7372_power_down_forbidden, | 171 | .power_down_ok = sh7372_power_down_forbidden, |
172 | .stop_ok = default_stop_ok, | ||
172 | }; | 173 | }; |
173 | 174 | ||
174 | static int sh7372_stop_dev(struct device *dev) | 175 | static int sh7372_stop_dev(struct device *dev) |
@@ -203,8 +204,9 @@ static int sh7372_start_dev(struct device *dev) | |||
203 | void sh7372_init_pm_domain(struct sh7372_pm_domain *sh7372_pd) | 204 | void sh7372_init_pm_domain(struct sh7372_pm_domain *sh7372_pd) |
204 | { | 205 | { |
205 | struct generic_pm_domain *genpd = &sh7372_pd->genpd; | 206 | struct generic_pm_domain *genpd = &sh7372_pd->genpd; |
207 | struct dev_power_governor *gov = sh7372_pd->gov; | ||
206 | 208 | ||
207 | pm_genpd_init(genpd, sh7372_pd->gov, false); | 209 | pm_genpd_init(genpd, gov ? : &simple_qos_governor, false); |
208 | genpd->dev_ops.stop = sh7372_stop_dev; | 210 | genpd->dev_ops.stop = sh7372_stop_dev; |
209 | genpd->dev_ops.start = sh7372_start_dev; | 211 | genpd->dev_ops.start = sh7372_start_dev; |
210 | genpd->dev_ops.active_wakeup = pd_active_wakeup; | 212 | genpd->dev_ops.active_wakeup = pd_active_wakeup; |