diff options
author | Rafael J. Wysocki <rjw@sisk.pl> | 2011-08-25 09:34:12 -0400 |
---|---|---|
committer | Rafael J. Wysocki <rjw@sisk.pl> | 2011-08-25 09:34:12 -0400 |
commit | 4605ab653c1f9d7cc2dda8033de215c9cee325f4 (patch) | |
tree | 8f55aa3137973ce2a3ef0ed49c44304e148d50fe /arch/arm | |
parent | ef27bed1870dbd5fd363ff5ec51eebd5a695e277 (diff) |
PM / Domains: Use power.sybsys_data to reduce overhead
Currently pm_genpd_runtime_resume() has to walk the list of devices
from the device's PM domain to find the corresponding device list
object containing the need_restore field to check if the driver's
.runtime_resume() callback should be executed for the device.
This is suboptimal and can be simplified by using power.sybsys_data
to store device information used by the generic PM domains code.
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/mach-shmobile/pm-sh7372.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/arch/arm/mach-shmobile/pm-sh7372.c b/arch/arm/mach-shmobile/pm-sh7372.c index 54d4d86883c9..4aeca0adae56 100644 --- a/arch/arm/mach-shmobile/pm-sh7372.c +++ b/arch/arm/mach-shmobile/pm-sh7372.c | |||
@@ -114,11 +114,9 @@ void sh7372_add_device_to_domain(struct sh7372_pm_domain *sh7372_pd, | |||
114 | { | 114 | { |
115 | struct device *dev = &pdev->dev; | 115 | struct device *dev = &pdev->dev; |
116 | 116 | ||
117 | if (!dev->power.subsys_data) { | ||
118 | pm_clk_create(dev); | ||
119 | pm_clk_add(dev, NULL); | ||
120 | } | ||
121 | pm_genpd_add_device(&sh7372_pd->genpd, dev); | 117 | pm_genpd_add_device(&sh7372_pd->genpd, dev); |
118 | if (pm_clk_no_clocks(dev)) | ||
119 | pm_clk_add(dev, NULL); | ||
122 | } | 120 | } |
123 | 121 | ||
124 | void sh7372_pm_add_subdomain(struct sh7372_pm_domain *sh7372_pd, | 122 | void sh7372_pm_add_subdomain(struct sh7372_pm_domain *sh7372_pd, |