PM / Domains: Remove redundant system PM callbacks
authorUlf Hansson <ulf.hansson@linaro.org>
Wed, 21 Sep 2016 13:38:51 +0000 (15:38 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Fri, 23 Sep 2016 23:54:28 +0000 (01:54 +0200)
In cases when the PM domain haven't assigned a system PM callback, the PM
core fall-backs to check for the callback at the driver level instead.
This makes it redundant to assign a pm_generic_* helper function to a
corresponding system PM callback at a PM domain level.

Therefore, let's remove these assignments in pm_genpd_init().

Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/base/power/domain.c

index 63f0f8b3f324064afcc9682f83e854d180069a8e..661ac3a425716c68d12ce9c446ebf1910e04aea6 100644 (file)
@@ -1316,24 +1316,12 @@ int pm_genpd_init(struct generic_pm_domain *genpd,
        genpd->domain.ops.runtime_suspend = genpd_runtime_suspend;
        genpd->domain.ops.runtime_resume = genpd_runtime_resume;
        genpd->domain.ops.prepare = pm_genpd_prepare;
-       genpd->domain.ops.suspend = pm_generic_suspend;
-       genpd->domain.ops.suspend_late = pm_generic_suspend_late;
        genpd->domain.ops.suspend_noirq = pm_genpd_suspend_noirq;
        genpd->domain.ops.resume_noirq = pm_genpd_resume_noirq;
-       genpd->domain.ops.resume_early = pm_generic_resume_early;
-       genpd->domain.ops.resume = pm_generic_resume;
-       genpd->domain.ops.freeze = pm_generic_freeze;
-       genpd->domain.ops.freeze_late = pm_generic_freeze_late;
        genpd->domain.ops.freeze_noirq = pm_genpd_freeze_noirq;
        genpd->domain.ops.thaw_noirq = pm_genpd_thaw_noirq;
-       genpd->domain.ops.thaw_early = pm_generic_thaw_early;
-       genpd->domain.ops.thaw = pm_generic_thaw;
-       genpd->domain.ops.poweroff = pm_generic_poweroff;
-       genpd->domain.ops.poweroff_late = pm_generic_poweroff_late;
        genpd->domain.ops.poweroff_noirq = pm_genpd_suspend_noirq;
        genpd->domain.ops.restore_noirq = pm_genpd_restore_noirq;
-       genpd->domain.ops.restore_early = pm_generic_restore_early;
-       genpd->domain.ops.restore = pm_generic_restore;
        genpd->domain.ops.complete = pm_genpd_complete;
 
        if (genpd->flags & GENPD_FLAG_PM_CLK) {