mirror of https://lore.kernel.org/linux-amlogic/
 help / color / mirror / Atom feed
* [PATCH 2/2] thermal/drivers/amlogic: Remove redundant msg in amlogic_thermal_probe()
       [not found] <20230711124513.47771-1-frank.li@vivo.com>
@ 2023-07-11 12:45 ` Yangtao Li
  0 siblings, 0 replies; only message in thread
From: Yangtao Li @ 2023-07-11 12:45 UTC (permalink / raw)
  To: Guillaume La Roque, Rafael J. Wysocki, Daniel Lezcano,
	Amit Kucheria, Zhang Rui
  Cc: Yangtao Li, linux-pm, linux-amlogic, linux-kernel

The upper-layer devm_thermal_of_zone_register() function can directly
print error information.

Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
 drivers/thermal/amlogic_thermal.c | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/drivers/thermal/amlogic_thermal.c b/drivers/thermal/amlogic_thermal.c
index 756b218880a7..134f5a8d1019 100644
--- a/drivers/thermal/amlogic_thermal.c
+++ b/drivers/thermal/amlogic_thermal.c
@@ -276,11 +276,8 @@ static int amlogic_thermal_probe(struct platform_device *pdev)
 						   0,
 						   pdata,
 						   &amlogic_thermal_ops);
-	if (IS_ERR(pdata->tzd)) {
-		ret = PTR_ERR(pdata->tzd);
-		dev_err(dev, "Failed to register tsensor: %d\n", ret);
-		return ret;
-	}
+	if (IS_ERR(pdata->tzd))
+		return PTR_ERR(pdata->tzd);
 
 	devm_thermal_add_hwmon_sysfs(&pdev->dev, pdata->tzd);
 
-- 
2.39.0


_______________________________________________
linux-amlogic mailing list
linux-amlogic@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-amlogic

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2023-07-11 12:46 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <20230711124513.47771-1-frank.li@vivo.com>
2023-07-11 12:45 ` [PATCH 2/2] thermal/drivers/amlogic: Remove redundant msg in amlogic_thermal_probe() Yangtao Li

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®