[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1611736925-32547-1-git-send-email-abaci-bugfix@linux.alibaba.com>
Date: Wed, 27 Jan 2021 16:42:05 +0800
From: Abaci Team <abaci-bugfix@...ux.alibaba.com>
To: rjw@...ysocki.net
Cc: khilman@...nel.org, ulf.hansson@...aro.org, len.brown@...el.com,
pavel@....cz, gregkh@...uxfoundation.org, linux-pm@...r.kernel.org,
linux-kernel@...r.kernel.org,
Abaci Team <abaci-bugfix@...ux.alibaba.com>
Subject: [PATCH] PM: domains: Simplify the calculation of variables
Fix the following coccicheck warnings:
./drivers/base/power/domain.c:938:31-33: WARNING !A || A && B is
equivalent to !A || B.
Reported-by: Abaci Robot <abaci@...ux.alibaba.com>
Suggested-by: Jiapeng Zhong <oswb@...ux.alibaba.com>
Signed-off-by: Abaci Team <abaci-bugfix@...ux.alibaba.com>
---
drivers/base/power/domain.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/base/power/domain.c b/drivers/base/power/domain.c
index 9a14eed..e689710 100644
--- a/drivers/base/power/domain.c
+++ b/drivers/base/power/domain.c
@@ -934,8 +934,7 @@ static int genpd_runtime_resume(struct device *dev)
err_stop:
genpd_stop_dev(genpd, dev);
err_poweroff:
- if (!pm_runtime_is_irq_safe(dev) ||
- (pm_runtime_is_irq_safe(dev) && genpd_is_irq_safe(genpd))) {
+ if (!pm_runtime_is_irq_safe(dev) || genpd_is_irq_safe(genpd)) {
genpd_lock(genpd);
genpd_power_off(genpd, true, 0);
genpd_unlock(genpd);
--
1.8.3.1
Powered by blists - more mailing lists