Message ID | 1412081033-8136-3-git-send-email-ulf.hansson@linaro.org |
---|---|
State | New |
Headers | show |
Ulf Hansson <ulf.hansson@linaro.org> writes: > At ->probe() it's common practice for drivers/subsystems to bring their > devices to full power and without depending on CONFIG_PM_RUNTIME. > > We could also expect that drivers/subsystems requires their device's > corresponding PM domains to be powered, to successfully complete a > ->probe() sequence. > > Align to the behavior above, by ensuring all PM domains are powered > prior initialization of a generic PM domain. > > Do note, since the generic PM domain will try to power off unused PM > domains at late_init, there are no increased power consumption over > time. IMO "no increased power consumption" is a bit misleading because boot-time power consumption may have a major increase when all power domains are powered on. Sure, they will eventually (hopefully) be turned off in after late_initcall, but there will still be an impact. I guess the Samsung folks should comment here on whether that is significant. Kevin -- To unsubscribe from this list: send the line "unsubscribe linux-pm" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On 30.09.2014 20:33, Kevin Hilman wrote: > Ulf Hansson <ulf.hansson@linaro.org> writes: > >> At ->probe() it's common practice for drivers/subsystems to bring their >> devices to full power and without depending on CONFIG_PM_RUNTIME. >> >> We could also expect that drivers/subsystems requires their device's >> corresponding PM domains to be powered, to successfully complete a >> ->probe() sequence. >> >> Align to the behavior above, by ensuring all PM domains are powered >> prior initialization of a generic PM domain. >> >> Do note, since the generic PM domain will try to power off unused PM >> domains at late_init, there are no increased power consumption over >> time. > > IMO "no increased power consumption" is a bit misleading because > boot-time power consumption may have a major increase when all power > domains are powered on. Sure, they will eventually (hopefully) be > turned off in after late_initcall, but there will still be an impact. > > I guess the Samsung folks should comment here on whether that is > significant. Unfortunately this series has not been posted to linux-samsung-soc mailing list and I'm a formerly-Samsung folk now, so it hasn't really reached there. Best regards, Tomasz -- To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On 1 October 2014 13:23, Tomasz Figa <tomasz.figa@gmail.com> wrote: > On 30.09.2014 20:33, Kevin Hilman wrote: >> Ulf Hansson <ulf.hansson@linaro.org> writes: >> >>> At ->probe() it's common practice for drivers/subsystems to bring their >>> devices to full power and without depending on CONFIG_PM_RUNTIME. >>> >>> We could also expect that drivers/subsystems requires their device's >>> corresponding PM domains to be powered, to successfully complete a >>> ->probe() sequence. >>> >>> Align to the behavior above, by ensuring all PM domains are powered >>> prior initialization of a generic PM domain. >>> >>> Do note, since the generic PM domain will try to power off unused PM >>> domains at late_init, there are no increased power consumption over >>> time. >> >> IMO "no increased power consumption" is a bit misleading because >> boot-time power consumption may have a major increase when all power >> domains are powered on. Sure, they will eventually (hopefully) be >> turned off in after late_initcall, but there will still be an impact. >> >> I guess the Samsung folks should comment here on whether that is >> significant. > > Unfortunately this series has not been posted to linux-samsung-soc > mailing list and I'm a formerly-Samsung folk now, so it hasn't really > reached there. > Ohh, thanks for pointing this out. I will resend it. Kind regards Uffe -- To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/arch/arm/mach-exynos/pm_domains.c b/arch/arm/mach-exynos/pm_domains.c index 20f2671..58e18e9 100644 --- a/arch/arm/mach-exynos/pm_domains.c +++ b/arch/arm/mach-exynos/pm_domains.c @@ -112,7 +112,7 @@ static __init int exynos4_pm_init_power_domain(void) for_each_compatible_node(np, NULL, "samsung,exynos4210-pd") { struct exynos_pm_domain *pd; - int on, i; + int i; struct device *dev; pdev = of_find_device_by_node(np); @@ -155,9 +155,10 @@ static __init int exynos4_pm_init_power_domain(void) clk_put(pd->oscclk); no_clk: - on = __raw_readl(pd->base + 0x4) & INT_LOCAL_PWR_EN; + if (!(__raw_readl(pd->base + 0x4) & INT_LOCAL_PWR_EN)) + exynos_pd_power_on(&pd->pd); - pm_genpd_init(&pd->pd, NULL, !on); + pm_genpd_init(&pd->pd, NULL, false); of_genpd_add_provider_simple(np, &pd->pd); }
At ->probe() it's common practice for drivers/subsystems to bring their devices to full power and without depending on CONFIG_PM_RUNTIME. We could also expect that drivers/subsystems requires their device's corresponding PM domains to be powered, to successfully complete a ->probe() sequence. Align to the behavior above, by ensuring all PM domains are powered prior initialization of a generic PM domain. Do note, since the generic PM domain will try to power off unused PM domains at late_init, there are no increased power consumption over time. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> --- arch/arm/mach-exynos/pm_domains.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-)