All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v1] drivers/clk/clk: check return value of clk_pm_runtime_get()
@ 2022-08-28 20:20 Li Zhong
  2022-08-28 23:26 ` kernel test robot
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Li Zhong @ 2022-08-28 20:20 UTC (permalink / raw)
  To: linux-clk, linux-kernel; +Cc: mturquette, sboyd, lily

From: lily <floridsleeves@gmail.com>

clk_pm_runtime_get() could fail. Check the return status.

Signed-off-by: Li Zhong <floridsleeves@gmail.com>
---
 drivers/clk/clk.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/drivers/clk/clk.c b/drivers/clk/clk.c
index 7fc191c15507..f22b86dfe2f2 100644
--- a/drivers/clk/clk.c
+++ b/drivers/clk/clk.c
@@ -2981,8 +2981,11 @@ static void clk_summary_show_subtree(struct seq_file *s, struct clk_core *c,
 				     int level)
 {
 	struct clk_core *child;
-
-	clk_pm_runtime_get(c);
+	int ret;
+	
+	ret = clk_pm_runtime_get(c);
+    if (ret)
+        return;
 	clk_summary_show_one(s, c, level);
 	clk_pm_runtime_put(c);
 
-- 
2.25.1


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

end of thread, other threads:[~2022-08-29  4:02 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-08-28 20:20 [PATCH v1] drivers/clk/clk: check return value of clk_pm_runtime_get() Li Zhong
2022-08-28 23:26 ` kernel test robot
2022-08-29  0:18 ` kernel test robot
2022-08-29  0:28 ` kernel test robot
2022-08-29  4:02 ` kernel test robot

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.