* [PATCH] PM: domains: Simplify the calculation of variables
@ 2021-01-27 8:42 Abaci Team
2021-02-01 10:08 ` Ulf Hansson
0 siblings, 1 reply; 3+ messages in thread
From: Abaci Team @ 2021-01-27 8:42 UTC (permalink / raw)
To: rjw
Cc: khilman, ulf.hansson, len.brown, pavel, gregkh, linux-pm,
linux-kernel, Abaci Team
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@linux.alibaba.com>
Suggested-by: Jiapeng Zhong <oswb@linux.alibaba.com>
Signed-off-by: Abaci Team <abaci-bugfix@linux.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
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] PM: domains: Simplify the calculation of variables
2021-01-27 8:42 [PATCH] PM: domains: Simplify the calculation of variables Abaci Team
@ 2021-02-01 10:08 ` Ulf Hansson
2021-02-01 14:05 ` Rafael J. Wysocki
0 siblings, 1 reply; 3+ messages in thread
From: Ulf Hansson @ 2021-02-01 10:08 UTC (permalink / raw)
To: Abaci Team
Cc: Rafael J. Wysocki, Kevin Hilman, Len Brown, Pavel Machek,
Greg Kroah-Hartman, Linux PM, Linux Kernel Mailing List
On Wed, 27 Jan 2021 at 09:42, Abaci Team <abaci-bugfix@linux.alibaba.com> wrote:
>
> 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@linux.alibaba.com>
> Suggested-by: Jiapeng Zhong <oswb@linux.alibaba.com>
> Signed-off-by: Abaci Team <abaci-bugfix@linux.alibaba.com>
Acked-by: Ulf Hansson <ulf.hansson@linaro.org>
Kind regards
Uffe
> ---
> 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
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] PM: domains: Simplify the calculation of variables
2021-02-01 10:08 ` Ulf Hansson
@ 2021-02-01 14:05 ` Rafael J. Wysocki
0 siblings, 0 replies; 3+ messages in thread
From: Rafael J. Wysocki @ 2021-02-01 14:05 UTC (permalink / raw)
To: Ulf Hansson, Abaci Team
Cc: Rafael J. Wysocki, Kevin Hilman, Len Brown, Pavel Machek,
Greg Kroah-Hartman, Linux PM, Linux Kernel Mailing List
On Mon, Feb 1, 2021 at 11:11 AM Ulf Hansson <ulf.hansson@linaro.org> wrote:
>
> On Wed, 27 Jan 2021 at 09:42, Abaci Team <abaci-bugfix@linux.alibaba.com> wrote:
> >
> > 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@linux.alibaba.com>
> > Suggested-by: Jiapeng Zhong <oswb@linux.alibaba.com>
> > Signed-off-by: Abaci Team <abaci-bugfix@linux.alibaba.com>
>
> Acked-by: Ulf Hansson <ulf.hansson@linaro.org>
Applied as 5.12 material, thanks!
> > ---
> > 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
> >
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2021-02-01 14:07 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-01-27 8:42 [PATCH] PM: domains: Simplify the calculation of variables Abaci Team
2021-02-01 10:08 ` Ulf Hansson
2021-02-01 14:05 ` Rafael J. Wysocki
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox