Linux clock framework development
 help / color / mirror / Atom feed
* [PATCH RFC] clk: versaclock7: propagate all xin lookup failures
@ 2026-09-11  6:09 Slavin Liu
  2026-09-11  6:21 ` sashiko-bot
  0 siblings, 1 reply; 2+ messages in thread
From: Slavin Liu @ 2026-09-11  6:09 UTC (permalink / raw)
  To: biju.das.jz, sboyd, bmasney+clk, jbrunet+clk
  Cc: linux-clk, linux-kernel, bolin.liu

The xin clock is used to obtain the APLL reference rate. Handle all
lookup errors, not only probe deferral, before clk_get_rate() can see
an error pointer.

Detected by static analysis and reviewed with AI-assisted source auditing.

Fixes: 48c5e98fedd9 ("clk: Renesas versaclock7 ccf device driver")
Assisted-by: LLM
Signed-off-by: Slavin Liu <bolin.liu@seu.edu.cn>
---
 drivers/clk/clk-versaclock7.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/clk/clk-versaclock7.c b/drivers/clk/clk-versaclock7.c
index 1340d2f512be..5f32d3fb807a 100644
--- a/drivers/clk/clk-versaclock7.c
+++ b/drivers/clk/clk-versaclock7.c
@@ -1117,8 +1117,8 @@ static int vc7_probe(struct i2c_client *client)
 	vc7->chip_info = i2c_get_match_data(client);
 
 	vc7->pin_xin = devm_clk_get(&client->dev, "xin");
-	if (PTR_ERR(vc7->pin_xin) == -EPROBE_DEFER) {
-		return dev_err_probe(&client->dev, -EPROBE_DEFER,
+	if (IS_ERR(vc7->pin_xin)) {
+		return dev_err_probe(&client->dev, PTR_ERR(vc7->pin_xin),
 				     "xin not specified\n");
 	}
 

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

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

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-11  6:09 [PATCH RFC] clk: versaclock7: propagate all xin lookup failures Slavin Liu
2026-09-11  6:21 ` sashiko-bot

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