Re: [PATCH 112/114] clk: scmi: remove round_rate() in favor of determine_rate()

Peng Fan <[email protected]>
Newsgroups dev.linux.lists.sophgo,dev.linux.lists.asahi,dev.linux.lists.imx,dev.linux.lists.soc,dev.linux.lists.spacemit,org.infradead.lists.linux-mediatek,org.infradead.lists.linux-riscv,org.infradead.lists.linux-rockchip,org.kernel.vger.arm-scmi,org.kernel.vger.linux-arm-msm,org.kernel.vger.linux-clk,org.kernel.vger.linux-kernel,org.kernel.vger.linux-mips,org.kernel.vger.linux-renesas-soc,org.kernel.vger.linux-samsung-soc
Message-ID <[email protected]>
Hi Brian, Sudeep, Cristian

On Mon, Aug 11, 2025 at 11:19:44AM -0400, Brian Masney via B4 Relay wrote:
>From: Brian Masney <[email protected]>
>
>This driver implements both the determine_rate() and round_rate() clk
>ops, and the round_rate() clk ops is deprecated. When both are defined,
>clk_core_determine_round_nolock() from the clk core will only use the
>determine_rate() clk ops, so let's remove the round_rate() clk ops since
>it's unused.
>
>Signed-off-by: Brian Masney <[email protected]>
>---
> drivers/clk/clk-scmi.c | 30 ------------------------------
> 1 file changed, 30 deletions(-)
>
>diff --git a/drivers/clk/clk-scmi.c b/drivers/clk/clk-scmi.c
>index d2408403283fc72f0cf902e65f4c08bcbc7b4b0b..6c6ddb92e7cf6a0cfac2c7e19c0f15f777bb8c51 100644
>--- a/drivers/clk/clk-scmi.c
>+++ b/drivers/clk/clk-scmi.c
>@@ -54,35 +54,6 @@ static unsigned long scmi_clk_recalc_rate(struct clk_hw *hw,
> 	return rate;
> }
> 
>-static long scmi_clk_round_rate(struct clk_hw *hw, unsigned long rate,
>-				unsigned long *parent_rate)
>-{

I see the point of round_rate is not used if determine_rate is there.
But reading the code of round_rate, It might be better to rename
scmi_clk_round_rate to scmi_clk_determine_rate.

Anyway, need Sudeep and Cristian to comment.

Thanks,
Peng
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.