lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20220828202025.1948848-1-floridsleeves@gmail.com>
Date:   Sun, 28 Aug 2022 13:20:25 -0700
From:   Li Zhong <floridsleeves@...il.com>
To:     linux-clk@...r.kernel.org, linux-kernel@...r.kernel.org
Cc:     mturquette@...libre.com, sboyd@...nel.org,
        lily <floridsleeves@...il.com>
Subject: [PATCH v1] drivers/clk/clk: check return value of clk_pm_runtime_get()

From: lily <floridsleeves@...il.com>

clk_pm_runtime_get() could fail. Check the return status.

Signed-off-by: Li Zhong <floridsleeves@...il.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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ