* [PATCH] thermal: da9062/61: fix platform_get_irq.cocci warnings
@ 2020-12-25 8:44 Tian Tao
0 siblings, 0 replies; 4+ messages in thread
From: Tian Tao @ 2020-12-25 8:44 UTC (permalink / raw)
To: support.opensource, rui.zhang, daniel.lezcano, amitk; +Cc: linux-pm
Remove dev_err() messages after platform_get_irq*() failures.
drivers/thermal/da9062-thermal.c:252:2-9: line 252 is redundant
because platform_get_irq() already prints an error.
Signed-off-by: Tian Tao <tiantao6@hisilicon.com>
---
drivers/thermal/da9062-thermal.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/thermal/da9062-thermal.c b/drivers/thermal/da9062-thermal.c
index 4d74994..3009e6a 100644
--- a/drivers/thermal/da9062-thermal.c
+++ b/drivers/thermal/da9062-thermal.c
@@ -248,10 +248,9 @@ static int da9062_thermal_probe(struct platform_device *pdev)
thermal->zone->passive_delay);
ret = platform_get_irq_byname(pdev, "THERMAL");
- if (ret < 0) {
- dev_err(&pdev->dev, "Failed to get platform IRQ.\n");
+ if (ret < 0)
goto err_zone;
- }
+
thermal->irq = ret;
ret = request_threaded_irq(thermal->irq, NULL,
--
2.7.4
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH] thermal: da9062/61: fix platform_get_irq.cocci warnings
@ 2020-12-23 6:57 Tian Tao
0 siblings, 0 replies; 4+ messages in thread
From: Tian Tao @ 2020-12-23 6:57 UTC (permalink / raw)
To: support.opensource, rui.zhang, daniel.lezcano, amitk; +Cc: linux-pm
Remove dev_err() messages after platform_get_irq*() failures.
drivers/thermal/da9062-thermal.c:252:2-9: line 252 is redundant
because platform_get_irq() already prints an error.
Signed-off-by: Tian Tao <tiantao6@hisilicon.com>
---
drivers/thermal/da9062-thermal.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/thermal/da9062-thermal.c b/drivers/thermal/da9062-thermal.c
index 4d74994..3009e6a 100644
--- a/drivers/thermal/da9062-thermal.c
+++ b/drivers/thermal/da9062-thermal.c
@@ -248,10 +248,9 @@ static int da9062_thermal_probe(struct platform_device *pdev)
thermal->zone->passive_delay);
ret = platform_get_irq_byname(pdev, "THERMAL");
- if (ret < 0) {
- dev_err(&pdev->dev, "Failed to get platform IRQ.\n");
+ if (ret < 0)
goto err_zone;
- }
+
thermal->irq = ret;
ret = request_threaded_irq(thermal->irq, NULL,
--
2.7.4
^ permalink raw reply related [flat|nested] 4+ messages in thread
* RE: [PATCH] thermal: da9062/61: fix platform_get_irq.cocci warnings
2020-12-14 2:27 Tian Tao
@ 2020-12-14 10:03 ` Adam Thomson
0 siblings, 0 replies; 4+ messages in thread
From: Adam Thomson @ 2020-12-14 10:03 UTC (permalink / raw)
To: Tian Tao, Support Opensource, rui.zhang, daniel.lezcano, amitk; +Cc: linux-pm
On 14 December 2020 02:27, Tian Tao wrote:
> Remove dev_err() messages after platform_get_irq*() failures.
> Line 248 redundant because platform_get_irq() already prints
> an error.
>
> Generated by: scripts/coccinelle/api/platform_get_irq.cocci
>
> Signed-off-by: Tian Tao <tiantao6@hisilicon.com>
I'm not sure stating line 248 is overly helpful in a commit message, especially
if this were to be cherry-picked (not that this is likely given the kind of
change being made).
That aside, the change itself is fine so:
Reviewed-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH] thermal: da9062/61: fix platform_get_irq.cocci warnings
@ 2020-12-14 2:27 Tian Tao
2020-12-14 10:03 ` Adam Thomson
0 siblings, 1 reply; 4+ messages in thread
From: Tian Tao @ 2020-12-14 2:27 UTC (permalink / raw)
To: support.opensource, rui.zhang, daniel.lezcano, amitk; +Cc: linux-pm
Remove dev_err() messages after platform_get_irq*() failures.
Line 248 redundant because platform_get_irq() already prints
an error.
Generated by: scripts/coccinelle/api/platform_get_irq.cocci
Signed-off-by: Tian Tao <tiantao6@hisilicon.com>
---
drivers/thermal/da9062-thermal.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/thermal/da9062-thermal.c b/drivers/thermal/da9062-thermal.c
index 4d74994..3009e6a 100644
--- a/drivers/thermal/da9062-thermal.c
+++ b/drivers/thermal/da9062-thermal.c
@@ -248,10 +248,9 @@ static int da9062_thermal_probe(struct platform_device *pdev)
thermal->zone->passive_delay);
ret = platform_get_irq_byname(pdev, "THERMAL");
- if (ret < 0) {
- dev_err(&pdev->dev, "Failed to get platform IRQ.\n");
+ if (ret < 0)
goto err_zone;
- }
+
thermal->irq = ret;
ret = request_threaded_irq(thermal->irq, NULL,
--
2.7.4
^ permalink raw reply related [flat|nested] 4+ messages in thread
end of thread, other threads:[~2020-12-25 8:45 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-25 8:44 [PATCH] thermal: da9062/61: fix platform_get_irq.cocci warnings Tian Tao
-- strict thread matches above, loose matches on Subject: below --
2020-12-23 6:57 Tian Tao
2020-12-14 2:27 Tian Tao
2020-12-14 10:03 ` Adam Thomson
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.