mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v1] thermal/drivers/mediatek/lvts_thermal: remove extra error check in lvts_debugfs_init()
@ 2023-09-21  7:55 Minjie Du
  2023-09-21  7:59 ` AngeloGioacchino Del Regno
  0 siblings, 1 reply; 2+ messages in thread
From: Minjie Du @ 2023-09-21  7:55 UTC (permalink / raw)
  To: Rafael J. Wysocki, Daniel Lezcano, Amit Kucheria, Zhang Rui,
	Philipp Zabel, Matthias Brugger, AngeloGioacchino Del Regno,
	Nícolas F. R. A. Prado, Alexandre Mergnat, Chen-Yu Tsai,
	Minjie Du, Balsam CHIHI, open list:THERMAL, open list,
	moderated list:ARM/Mediatek SoC support,
	moderated list:ARM/Mediatek SoC support
  Cc: opensource.kernel

As per the comment above debugfs_create_dir(), it is not expected to
return an error, so an extra error check is not needed.
Drop the return check of debugfs_create_dir() in
lvts_debugfs_init()

Signed-off-by: Minjie Du <duminjie@vivo.com>
---
 drivers/thermal/mediatek/lvts_thermal.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/thermal/mediatek/lvts_thermal.c b/drivers/thermal/mediatek/lvts_thermal.c
index effd9b00a424..171ce25fddf5 100644
--- a/drivers/thermal/mediatek/lvts_thermal.c
+++ b/drivers/thermal/mediatek/lvts_thermal.c
@@ -213,8 +213,6 @@ static int lvts_debugfs_init(struct device *dev, struct lvts_domain *lvts_td)
 
 		sprintf(name, "controller%d", i);
 		dentry = debugfs_create_dir(name, lvts_td->dom_dentry);
-		if (!dentry)
-			continue;
 
 		regset = devm_kzalloc(dev, sizeof(*regset), GFP_KERNEL);
 		if (!regset)
-- 
2.39.0


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-09-21 18:11 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-09-21  7:55 [PATCH v1] thermal/drivers/mediatek/lvts_thermal: remove extra error check in lvts_debugfs_init() Minjie Du
2023-09-21  7:59 ` AngeloGioacchino Del Regno

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®