summaryrefslogtreecommitdiff
path: root/drivers/base/power/domain.c
diff options
context:
space:
mode:
authorUlf Hansson <ulf.hansson@linaro.org>2022-05-11 16:56:55 +0200
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2022-05-19 20:16:05 +0200
commitbcc19f69f72ab7e3db581b993d6a9fc1bad5ddf4 (patch)
treee4c6c341bae79176669a94da0e4f489c4fdac6b7 /drivers/base/power/domain.c
parent7a02444b8fc25ac16f90c1e498aeb672651d6f4b (diff)
PM: domains: Skip another warning in irq_safe_dev_in_sleep_domain()
In irq_safe_dev_in_sleep_domain() we correctly skip the dev_warn_once() if the corresponding genpd for the device, has the GENPD_FLAG_ALWAYS_ON flag being set. For the same reason (the genpd is always-on in runtime), let's also skip the warning if the GENPD_FLAG_RPM_ALWAYS_ON flag is set for the genpd. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/base/power/domain.c')
-rw-r--r--drivers/base/power/domain.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/base/power/domain.c b/drivers/base/power/domain.c
index 269bfa3d2303..a3e727c9a4fa 100644
--- a/drivers/base/power/domain.c
+++ b/drivers/base/power/domain.c
@@ -143,7 +143,10 @@ static inline bool irq_safe_dev_in_sleep_domain(struct device *dev,
* callbacks are allowed to sleep. This indicates a suboptimal
* configuration for PM, but it doesn't matter for an always on domain.
*/
- if (ret && !genpd_is_always_on(genpd))
+ if (genpd_is_always_on(genpd) || genpd_is_rpm_always_on(genpd))
+ return ret;
+
+ if (ret)
dev_warn_once(dev, "PM domain %s will not be powered off\n",
genpd->name);