summaryrefslogtreecommitdiff
path: root/drivers/thermal
diff options
context:
space:
mode:
authorChen Jiahao <chenjiahao16@huawei.com>2023-08-02 12:45:27 +0300
committerDaniel Lezcano <daniel.lezcano@linaro.org>2023-08-16 13:06:05 +0300
commite9b1de73b7ca31f487e4f4f063a5b70aeb707863 (patch)
tree78fb392b66a4313abe4f631f200190edc6d9e97f /drivers/thermal
parentc51592a95f360aabf2b8a5691c550e1749dc41eb (diff)
downloadlinux-e9b1de73b7ca31f487e4f4f063a5b70aeb707863.tar.xz
thermal/drivers/mediatek: Clean up redundant dev_err_probe()
Referring to platform_get_irq()'s definition, the return value has already been checked if ret < 0, and printed via dev_err_probe(). Calling dev_err_probe() one more time outside platform_get_irq() is obviously redundant. Removing dev_err_probe() outside platform_get_irq() to clean up above problem. Signed-off-by: Chen Jiahao <chenjiahao16@huawei.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> Link: https://lore.kernel.org/r/20230802094527.988842-1-chenjiahao16@huawei.com
Diffstat (limited to 'drivers/thermal')
-rw-r--r--drivers/thermal/mediatek/lvts_thermal.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/thermal/mediatek/lvts_thermal.c b/drivers/thermal/mediatek/lvts_thermal.c
index bc726ac0a672..f4709ae842a2 100644
--- a/drivers/thermal/mediatek/lvts_thermal.c
+++ b/drivers/thermal/mediatek/lvts_thermal.c
@@ -1216,7 +1216,7 @@ static int lvts_probe(struct platform_device *pdev)
irq = platform_get_irq(pdev, 0);
if (irq < 0)
- return dev_err_probe(dev, irq, "No irq resource\n");
+ return irq;
ret = lvts_domain_init(dev, lvts_td, lvts_data);
if (ret)