* [PATCH v2 1/7] drm/msm/dsi_phy_10nm: convert from round_rate() to determine_rate()
2025-08-10 22:57 [PATCH v2 0/7] drm/msm/dsi/phy: convert from clk round_rate() to determine_rate() Brian Masney
@ 2025-08-10 22:57 ` Brian Masney
2025-08-11 10:30 ` Dmitry Baryshkov
2025-08-11 10:33 ` Konrad Dybcio
2025-08-10 22:57 ` [PATCH v2 2/7] drm/msm/dsi_phy_14nm: " Brian Masney
` (6 subsequent siblings)
7 siblings, 2 replies; 24+ messages in thread
From: Brian Masney @ 2025-08-10 22:57 UTC (permalink / raw)
To: Rob Clark, Dmitry Baryshkov, Abhinav Kumar, Jessica Zhang,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maxime Ripard, Stephen Boyd
Cc: linux-clk, linux-arm-msm, dri-devel, freedreno, linux-kernel,
Brian Masney
The round_rate() clk ops is deprecated, so migrate this driver from
round_rate() to determine_rate() using the Coccinelle semantic patch
on the cover letter of this series. The change to use clamp_t() was
done manually.
Signed-off-by: Brian Masney <bmasney@redhat.com>
---
drivers/gpu/drm/msm/dsi/phy/dsi_phy_10nm.c | 16 +++++++---------
1 file changed, 7 insertions(+), 9 deletions(-)
diff --git a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_10nm.c b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_10nm.c
index af2e30f3f842a0157f161172bfe42059cabe6a8a..ec486ff02c9b5156cdf0902d05464cf57dc9605b 100644
--- a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_10nm.c
+++ b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_10nm.c
@@ -444,21 +444,19 @@ static unsigned long dsi_pll_10nm_vco_recalc_rate(struct clk_hw *hw,
return (unsigned long)vco_rate;
}
-static long dsi_pll_10nm_clk_round_rate(struct clk_hw *hw,
- unsigned long rate, unsigned long *parent_rate)
+static int dsi_pll_10nm_clk_determine_rate(struct clk_hw *hw,
+ struct clk_rate_request *req)
{
struct dsi_pll_10nm *pll_10nm = to_pll_10nm(hw);
- if (rate < pll_10nm->phy->cfg->min_pll_rate)
- return pll_10nm->phy->cfg->min_pll_rate;
- else if (rate > pll_10nm->phy->cfg->max_pll_rate)
- return pll_10nm->phy->cfg->max_pll_rate;
- else
- return rate;
+ req->rate = clamp_t(unsigned long, req->rate,
+ pll_10nm->phy->cfg->min_pll_rate, pll_10nm->phy->cfg->max_pll_rate);
+
+ return 0;
}
static const struct clk_ops clk_ops_dsi_pll_10nm_vco = {
- .round_rate = dsi_pll_10nm_clk_round_rate,
+ .determine_rate = dsi_pll_10nm_clk_determine_rate,
.set_rate = dsi_pll_10nm_vco_set_rate,
.recalc_rate = dsi_pll_10nm_vco_recalc_rate,
.prepare = dsi_pll_10nm_vco_prepare,
--
2.50.1
^ permalink raw reply related [flat|nested] 24+ messages in thread
* Re: [PATCH v2 1/7] drm/msm/dsi_phy_10nm: convert from round_rate() to determine_rate()
2025-08-10 22:57 ` [PATCH v2 1/7] drm/msm/dsi_phy_10nm: convert from " Brian Masney
@ 2025-08-11 10:30 ` Dmitry Baryshkov
2025-08-11 10:33 ` Konrad Dybcio
1 sibling, 0 replies; 24+ messages in thread
From: Dmitry Baryshkov @ 2025-08-11 10:30 UTC (permalink / raw)
To: Brian Masney
Cc: Rob Clark, Dmitry Baryshkov, Abhinav Kumar, Jessica Zhang,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maxime Ripard, Stephen Boyd, linux-clk, linux-arm-msm, dri-devel,
freedreno, linux-kernel
On Sun, Aug 10, 2025 at 06:57:25PM -0400, Brian Masney wrote:
> The round_rate() clk ops is deprecated, so migrate this driver from
> round_rate() to determine_rate() using the Coccinelle semantic patch
> on the cover letter of this series. The change to use clamp_t() was
> done manually.
>
> Signed-off-by: Brian Masney <bmasney@redhat.com>
> ---
> drivers/gpu/drm/msm/dsi/phy/dsi_phy_10nm.c | 16 +++++++---------
> 1 file changed, 7 insertions(+), 9 deletions(-)
>
> diff --git a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_10nm.c b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_10nm.c
> index af2e30f3f842a0157f161172bfe42059cabe6a8a..ec486ff02c9b5156cdf0902d05464cf57dc9605b 100644
> --- a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_10nm.c
> +++ b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_10nm.c
> @@ -444,21 +444,19 @@ static unsigned long dsi_pll_10nm_vco_recalc_rate(struct clk_hw *hw,
> return (unsigned long)vco_rate;
> }
>
> -static long dsi_pll_10nm_clk_round_rate(struct clk_hw *hw,
> - unsigned long rate, unsigned long *parent_rate)
> +static int dsi_pll_10nm_clk_determine_rate(struct clk_hw *hw,
> + struct clk_rate_request *req)
> {
> struct dsi_pll_10nm *pll_10nm = to_pll_10nm(hw);
>
> - if (rate < pll_10nm->phy->cfg->min_pll_rate)
> - return pll_10nm->phy->cfg->min_pll_rate;
> - else if (rate > pll_10nm->phy->cfg->max_pll_rate)
> - return pll_10nm->phy->cfg->max_pll_rate;
> - else
> - return rate;
> + req->rate = clamp_t(unsigned long, req->rate,
> + pll_10nm->phy->cfg->min_pll_rate, pll_10nm->phy->cfg->max_pll_rate);
Nit: I'd prefer if there was an EOL after min_pll_rate, but no need to
resend it just for the sake of it.
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
> +
> + return 0;
> }
>
> static const struct clk_ops clk_ops_dsi_pll_10nm_vco = {
> - .round_rate = dsi_pll_10nm_clk_round_rate,
> + .determine_rate = dsi_pll_10nm_clk_determine_rate,
> .set_rate = dsi_pll_10nm_vco_set_rate,
> .recalc_rate = dsi_pll_10nm_vco_recalc_rate,
> .prepare = dsi_pll_10nm_vco_prepare,
>
> --
> 2.50.1
>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 1/7] drm/msm/dsi_phy_10nm: convert from round_rate() to determine_rate()
2025-08-10 22:57 ` [PATCH v2 1/7] drm/msm/dsi_phy_10nm: convert from " Brian Masney
2025-08-11 10:30 ` Dmitry Baryshkov
@ 2025-08-11 10:33 ` Konrad Dybcio
1 sibling, 0 replies; 24+ messages in thread
From: Konrad Dybcio @ 2025-08-11 10:33 UTC (permalink / raw)
To: Brian Masney, Rob Clark, Dmitry Baryshkov, Abhinav Kumar,
Jessica Zhang, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maxime Ripard, Stephen Boyd
Cc: linux-clk, linux-arm-msm, dri-devel, freedreno, linux-kernel
On 8/11/25 12:57 AM, Brian Masney wrote:
> The round_rate() clk ops is deprecated, so migrate this driver from
> round_rate() to determine_rate() using the Coccinelle semantic patch
> on the cover letter of this series. The change to use clamp_t() was
> done manually.
>
> Signed-off-by: Brian Masney <bmasney@redhat.com>
> ---
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Konrad
^ permalink raw reply [flat|nested] 24+ messages in thread
* [PATCH v2 2/7] drm/msm/dsi_phy_14nm: convert from round_rate() to determine_rate()
2025-08-10 22:57 [PATCH v2 0/7] drm/msm/dsi/phy: convert from clk round_rate() to determine_rate() Brian Masney
2025-08-10 22:57 ` [PATCH v2 1/7] drm/msm/dsi_phy_10nm: convert from " Brian Masney
@ 2025-08-10 22:57 ` Brian Masney
2025-08-11 10:31 ` Dmitry Baryshkov
2025-08-11 10:33 ` Konrad Dybcio
2025-08-10 22:57 ` [PATCH v2 3/7] drm/msm/dsi_phy_28nm_8960: " Brian Masney
` (5 subsequent siblings)
7 siblings, 2 replies; 24+ messages in thread
From: Brian Masney @ 2025-08-10 22:57 UTC (permalink / raw)
To: Rob Clark, Dmitry Baryshkov, Abhinav Kumar, Jessica Zhang,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maxime Ripard, Stephen Boyd
Cc: linux-clk, linux-arm-msm, dri-devel, freedreno, linux-kernel,
Brian Masney
The round_rate() clk ops is deprecated, so migrate this driver from
round_rate() to determine_rate() using the Coccinelle semantic patch
on the cover letter of this series. The change to use clamp_t() was
done manually.
Signed-off-by: Brian Masney <bmasney@redhat.com>
---
drivers/gpu/drm/msm/dsi/phy/dsi_phy_14nm.c | 34 +++++++++++++++---------------
1 file changed, 17 insertions(+), 17 deletions(-)
diff --git a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_14nm.c b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_14nm.c
index 3a1c8ece6657c988cfb0c26af39b5d145bc576f8..fdefcbd9c2848a1c76414a41b811b29e5fed9ddc 100644
--- a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_14nm.c
+++ b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_14nm.c
@@ -578,21 +578,19 @@ static void dsi_pll_14nm_vco_unprepare(struct clk_hw *hw)
pll_14nm->phy->pll_on = false;
}
-static long dsi_pll_14nm_clk_round_rate(struct clk_hw *hw,
- unsigned long rate, unsigned long *parent_rate)
+static int dsi_pll_14nm_clk_determine_rate(struct clk_hw *hw,
+ struct clk_rate_request *req)
{
struct dsi_pll_14nm *pll_14nm = to_pll_14nm(hw);
- if (rate < pll_14nm->phy->cfg->min_pll_rate)
- return pll_14nm->phy->cfg->min_pll_rate;
- else if (rate > pll_14nm->phy->cfg->max_pll_rate)
- return pll_14nm->phy->cfg->max_pll_rate;
- else
- return rate;
+ req->rate = clamp_t(unsigned long, req->rate,
+ pll_14nm->phy->cfg->min_pll_rate, pll_14nm->phy->cfg->max_pll_rate);
+
+ return 0;
}
static const struct clk_ops clk_ops_dsi_pll_14nm_vco = {
- .round_rate = dsi_pll_14nm_clk_round_rate,
+ .determine_rate = dsi_pll_14nm_clk_determine_rate,
.set_rate = dsi_pll_14nm_vco_set_rate,
.recalc_rate = dsi_pll_14nm_vco_recalc_rate,
.prepare = dsi_pll_14nm_vco_prepare,
@@ -622,18 +620,20 @@ static unsigned long dsi_pll_14nm_postdiv_recalc_rate(struct clk_hw *hw,
postdiv->flags, width);
}
-static long dsi_pll_14nm_postdiv_round_rate(struct clk_hw *hw,
- unsigned long rate,
- unsigned long *prate)
+static int dsi_pll_14nm_postdiv_determine_rate(struct clk_hw *hw,
+ struct clk_rate_request *req)
{
struct dsi_pll_14nm_postdiv *postdiv = to_pll_14nm_postdiv(hw);
struct dsi_pll_14nm *pll_14nm = postdiv->pll;
- DBG("DSI%d PLL parent rate=%lu", pll_14nm->phy->id, rate);
+ DBG("DSI%d PLL parent rate=%lu", pll_14nm->phy->id, req->rate);
- return divider_round_rate(hw, rate, prate, NULL,
- postdiv->width,
- postdiv->flags);
+ req->rate = divider_round_rate(hw, req->rate, &req->best_parent_rate,
+ NULL,
+ postdiv->width,
+ postdiv->flags);
+
+ return 0;
}
static int dsi_pll_14nm_postdiv_set_rate(struct clk_hw *hw, unsigned long rate,
@@ -680,7 +680,7 @@ static int dsi_pll_14nm_postdiv_set_rate(struct clk_hw *hw, unsigned long rate,
static const struct clk_ops clk_ops_dsi_pll_14nm_postdiv = {
.recalc_rate = dsi_pll_14nm_postdiv_recalc_rate,
- .round_rate = dsi_pll_14nm_postdiv_round_rate,
+ .determine_rate = dsi_pll_14nm_postdiv_determine_rate,
.set_rate = dsi_pll_14nm_postdiv_set_rate,
};
--
2.50.1
^ permalink raw reply related [flat|nested] 24+ messages in thread
* Re: [PATCH v2 2/7] drm/msm/dsi_phy_14nm: convert from round_rate() to determine_rate()
2025-08-10 22:57 ` [PATCH v2 2/7] drm/msm/dsi_phy_14nm: " Brian Masney
@ 2025-08-11 10:31 ` Dmitry Baryshkov
2025-08-11 10:33 ` Konrad Dybcio
1 sibling, 0 replies; 24+ messages in thread
From: Dmitry Baryshkov @ 2025-08-11 10:31 UTC (permalink / raw)
To: Brian Masney
Cc: Rob Clark, Dmitry Baryshkov, Abhinav Kumar, Jessica Zhang,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maxime Ripard, Stephen Boyd, linux-clk, linux-arm-msm, dri-devel,
freedreno, linux-kernel
On Sun, Aug 10, 2025 at 06:57:26PM -0400, Brian Masney wrote:
> The round_rate() clk ops is deprecated, so migrate this driver from
> round_rate() to determine_rate() using the Coccinelle semantic patch
> on the cover letter of this series. The change to use clamp_t() was
> done manually.
>
> Signed-off-by: Brian Masney <bmasney@redhat.com>
> ---
> drivers/gpu/drm/msm/dsi/phy/dsi_phy_14nm.c | 34 +++++++++++++++---------------
> 1 file changed, 17 insertions(+), 17 deletions(-)
>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 2/7] drm/msm/dsi_phy_14nm: convert from round_rate() to determine_rate()
2025-08-10 22:57 ` [PATCH v2 2/7] drm/msm/dsi_phy_14nm: " Brian Masney
2025-08-11 10:31 ` Dmitry Baryshkov
@ 2025-08-11 10:33 ` Konrad Dybcio
1 sibling, 0 replies; 24+ messages in thread
From: Konrad Dybcio @ 2025-08-11 10:33 UTC (permalink / raw)
To: Brian Masney, Rob Clark, Dmitry Baryshkov, Abhinav Kumar,
Jessica Zhang, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maxime Ripard, Stephen Boyd
Cc: linux-clk, linux-arm-msm, dri-devel, freedreno, linux-kernel
On 8/11/25 12:57 AM, Brian Masney wrote:
> The round_rate() clk ops is deprecated, so migrate this driver from
> round_rate() to determine_rate() using the Coccinelle semantic patch
> on the cover letter of this series. The change to use clamp_t() was
> done manually.
>
> Signed-off-by: Brian Masney <bmasney@redhat.com>
> ---
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Konrad
^ permalink raw reply [flat|nested] 24+ messages in thread
* [PATCH v2 3/7] drm/msm/dsi_phy_28nm_8960: convert from round_rate() to determine_rate()
2025-08-10 22:57 [PATCH v2 0/7] drm/msm/dsi/phy: convert from clk round_rate() to determine_rate() Brian Masney
2025-08-10 22:57 ` [PATCH v2 1/7] drm/msm/dsi_phy_10nm: convert from " Brian Masney
2025-08-10 22:57 ` [PATCH v2 2/7] drm/msm/dsi_phy_14nm: " Brian Masney
@ 2025-08-10 22:57 ` Brian Masney
2025-08-11 10:33 ` Dmitry Baryshkov
2025-08-11 10:33 ` Konrad Dybcio
2025-08-10 22:57 ` [PATCH v2 4/7] drm/msm/dsi_phy_28nm: " Brian Masney
` (4 subsequent siblings)
7 siblings, 2 replies; 24+ messages in thread
From: Brian Masney @ 2025-08-10 22:57 UTC (permalink / raw)
To: Rob Clark, Dmitry Baryshkov, Abhinav Kumar, Jessica Zhang,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maxime Ripard, Stephen Boyd
Cc: linux-clk, linux-arm-msm, dri-devel, freedreno, linux-kernel,
Brian Masney
The round_rate() clk ops is deprecated, so migrate this driver from
round_rate() to determine_rate() using the Coccinelle semantic patch
on the cover letter of this series. The change to use clamp_t() was
done manually.
Signed-off-by: Brian Masney <bmasney@redhat.com>
---
drivers/gpu/drm/msm/dsi/phy/dsi_phy_28nm_8960.c | 32 ++++++++++++-------------
1 file changed, 16 insertions(+), 16 deletions(-)
diff --git a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_28nm_8960.c b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_28nm_8960.c
index f3643320ff2f2bae5301bb94f1fe19fa03db584c..8dcce9581dc38730ab725e0e435ab93a04c527ed 100644
--- a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_28nm_8960.c
+++ b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_28nm_8960.c
@@ -231,21 +231,19 @@ static void dsi_pll_28nm_vco_unprepare(struct clk_hw *hw)
pll_28nm->phy->pll_on = false;
}
-static long dsi_pll_28nm_clk_round_rate(struct clk_hw *hw,
- unsigned long rate, unsigned long *parent_rate)
+static int dsi_pll_28nm_clk_determine_rate(struct clk_hw *hw,
+ struct clk_rate_request *req)
{
struct dsi_pll_28nm *pll_28nm = to_pll_28nm(hw);
- if (rate < pll_28nm->phy->cfg->min_pll_rate)
- return pll_28nm->phy->cfg->min_pll_rate;
- else if (rate > pll_28nm->phy->cfg->max_pll_rate)
- return pll_28nm->phy->cfg->max_pll_rate;
- else
- return rate;
+ req->rate = clamp_t(unsigned long, req->rate,
+ pll_28nm->phy->cfg->min_pll_rate, pll_28nm->phy->cfg->max_pll_rate);
+
+ return 0;
}
static const struct clk_ops clk_ops_dsi_pll_28nm_vco = {
- .round_rate = dsi_pll_28nm_clk_round_rate,
+ .determine_rate = dsi_pll_28nm_clk_determine_rate,
.set_rate = dsi_pll_28nm_clk_set_rate,
.recalc_rate = dsi_pll_28nm_clk_recalc_rate,
.prepare = dsi_pll_28nm_vco_prepare,
@@ -296,18 +294,20 @@ static unsigned int get_vco_mul_factor(unsigned long byte_clk_rate)
return 8;
}
-static long clk_bytediv_round_rate(struct clk_hw *hw, unsigned long rate,
- unsigned long *prate)
+static int clk_bytediv_determine_rate(struct clk_hw *hw,
+ struct clk_rate_request *req)
{
unsigned long best_parent;
unsigned int factor;
- factor = get_vco_mul_factor(rate);
+ factor = get_vco_mul_factor(req->rate);
+
+ best_parent = req->rate * factor;
+ req->best_parent_rate = clk_hw_round_rate(clk_hw_get_parent(hw), best_parent);
- best_parent = rate * factor;
- *prate = clk_hw_round_rate(clk_hw_get_parent(hw), best_parent);
+ req->rate = req->best_parent_rate / factor;
- return *prate / factor;
+ return 0;
}
static int clk_bytediv_set_rate(struct clk_hw *hw, unsigned long rate,
@@ -328,7 +328,7 @@ static int clk_bytediv_set_rate(struct clk_hw *hw, unsigned long rate,
/* Our special byte clock divider ops */
static const struct clk_ops clk_bytediv_ops = {
- .round_rate = clk_bytediv_round_rate,
+ .determine_rate = clk_bytediv_determine_rate,
.set_rate = clk_bytediv_set_rate,
.recalc_rate = clk_bytediv_recalc_rate,
};
--
2.50.1
^ permalink raw reply related [flat|nested] 24+ messages in thread
* Re: [PATCH v2 3/7] drm/msm/dsi_phy_28nm_8960: convert from round_rate() to determine_rate()
2025-08-10 22:57 ` [PATCH v2 3/7] drm/msm/dsi_phy_28nm_8960: " Brian Masney
@ 2025-08-11 10:33 ` Dmitry Baryshkov
2025-08-11 10:33 ` Konrad Dybcio
1 sibling, 0 replies; 24+ messages in thread
From: Dmitry Baryshkov @ 2025-08-11 10:33 UTC (permalink / raw)
To: Konrad Dybcio
Cc: Rob Clark, Dmitry Baryshkov, Abhinav Kumar, Jessica Zhang,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maxime Ripard, Stephen Boyd, linux-clk, linux-arm-msm, dri-devel,
freedreno, linux-kernel
On Sun, Aug 10, 2025 at 06:57:27PM -0400, Brian Masney wrote:
> The round_rate() clk ops is deprecated, so migrate this driver from
> round_rate() to determine_rate() using the Coccinelle semantic patch
> on the cover letter of this series. The change to use clamp_t() was
> done manually.
>
> Signed-off-by: Brian Masney <bmasney@redhat.com>
> ---
> drivers/gpu/drm/msm/dsi/phy/dsi_phy_28nm_8960.c | 32 ++++++++++++-------------
> 1 file changed, 16 insertions(+), 16 deletions(-)
>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 3/7] drm/msm/dsi_phy_28nm_8960: convert from round_rate() to determine_rate()
2025-08-10 22:57 ` [PATCH v2 3/7] drm/msm/dsi_phy_28nm_8960: " Brian Masney
2025-08-11 10:33 ` Dmitry Baryshkov
@ 2025-08-11 10:33 ` Konrad Dybcio
1 sibling, 0 replies; 24+ messages in thread
From: Konrad Dybcio @ 2025-08-11 10:33 UTC (permalink / raw)
To: Brian Masney, Rob Clark, Dmitry Baryshkov, Abhinav Kumar,
Jessica Zhang, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maxime Ripard, Stephen Boyd
Cc: linux-clk, linux-arm-msm, dri-devel, freedreno, linux-kernel
On 8/11/25 12:57 AM, Brian Masney wrote:
> The round_rate() clk ops is deprecated, so migrate this driver from
> round_rate() to determine_rate() using the Coccinelle semantic patch
> on the cover letter of this series. The change to use clamp_t() was
> done manually.
>
> Signed-off-by: Brian Masney <bmasney@redhat.com>
> ---
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Konrad
^ permalink raw reply [flat|nested] 24+ messages in thread
* [PATCH v2 4/7] drm/msm/dsi_phy_28nm: convert from round_rate() to determine_rate()
2025-08-10 22:57 [PATCH v2 0/7] drm/msm/dsi/phy: convert from clk round_rate() to determine_rate() Brian Masney
` (2 preceding siblings ...)
2025-08-10 22:57 ` [PATCH v2 3/7] drm/msm/dsi_phy_28nm_8960: " Brian Masney
@ 2025-08-10 22:57 ` Brian Masney
2025-08-11 10:33 ` Konrad Dybcio
2025-08-11 10:35 ` Dmitry Baryshkov
2025-08-10 22:57 ` [PATCH v2 5/7] drm/msm/dsi_phy_7nm: " Brian Masney
` (3 subsequent siblings)
7 siblings, 2 replies; 24+ messages in thread
From: Brian Masney @ 2025-08-10 22:57 UTC (permalink / raw)
To: Rob Clark, Dmitry Baryshkov, Abhinav Kumar, Jessica Zhang,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maxime Ripard, Stephen Boyd
Cc: linux-clk, linux-arm-msm, dri-devel, freedreno, linux-kernel,
Brian Masney
The round_rate() clk ops is deprecated, so migrate this driver from
round_rate() to determine_rate() using the Coccinelle semantic patch
on the cover letter of this series. The change to use clamp_t() was
done manually.
Signed-off-by: Brian Masney <bmasney@redhat.com>
---
drivers/gpu/drm/msm/dsi/phy/dsi_phy_28nm.c | 21 ++++++++++-----------
1 file changed, 10 insertions(+), 11 deletions(-)
diff --git a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_28nm.c b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_28nm.c
index 90348a2af3e9dac72924561b23b169a268abc3b0..d00e415b9a991cd515e01d78a48ac6fe3e830b04 100644
--- a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_28nm.c
+++ b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_28nm.c
@@ -533,21 +533,20 @@ static void dsi_pll_28nm_vco_unprepare(struct clk_hw *hw)
pll_28nm->phy->pll_on = false;
}
-static long dsi_pll_28nm_clk_round_rate(struct clk_hw *hw,
- unsigned long rate, unsigned long *parent_rate)
+static int dsi_pll_28nm_clk_determine_rate(struct clk_hw *hw,
+ struct clk_rate_request *req)
{
struct dsi_pll_28nm *pll_28nm = to_pll_28nm(hw);
- if (rate < pll_28nm->phy->cfg->min_pll_rate)
- return pll_28nm->phy->cfg->min_pll_rate;
- else if (rate > pll_28nm->phy->cfg->max_pll_rate)
- return pll_28nm->phy->cfg->max_pll_rate;
- else
- return rate;
+ req->rate = clamp_t(unsigned long, req->rate,
+ pll_28nm->phy->cfg->min_pll_rate,
+ pll_28nm->phy->cfg->max_pll_rate);
+
+ return 0;
}
static const struct clk_ops clk_ops_dsi_pll_28nm_vco_hpm = {
- .round_rate = dsi_pll_28nm_clk_round_rate,
+ .determine_rate = dsi_pll_28nm_clk_determine_rate,
.set_rate = dsi_pll_28nm_clk_set_rate,
.recalc_rate = dsi_pll_28nm_clk_recalc_rate,
.prepare = dsi_pll_28nm_vco_prepare_hpm,
@@ -556,7 +555,7 @@ static const struct clk_ops clk_ops_dsi_pll_28nm_vco_hpm = {
};
static const struct clk_ops clk_ops_dsi_pll_28nm_vco_lp = {
- .round_rate = dsi_pll_28nm_clk_round_rate,
+ .determine_rate = dsi_pll_28nm_clk_determine_rate,
.set_rate = dsi_pll_28nm_clk_set_rate,
.recalc_rate = dsi_pll_28nm_clk_recalc_rate,
.prepare = dsi_pll_28nm_vco_prepare_lp,
@@ -565,7 +564,7 @@ static const struct clk_ops clk_ops_dsi_pll_28nm_vco_lp = {
};
static const struct clk_ops clk_ops_dsi_pll_28nm_vco_8226 = {
- .round_rate = dsi_pll_28nm_clk_round_rate,
+ .determine_rate = dsi_pll_28nm_clk_determine_rate,
.set_rate = dsi_pll_28nm_clk_set_rate,
.recalc_rate = dsi_pll_28nm_clk_recalc_rate,
.prepare = dsi_pll_28nm_vco_prepare_8226,
--
2.50.1
^ permalink raw reply related [flat|nested] 24+ messages in thread
* Re: [PATCH v2 4/7] drm/msm/dsi_phy_28nm: convert from round_rate() to determine_rate()
2025-08-10 22:57 ` [PATCH v2 4/7] drm/msm/dsi_phy_28nm: " Brian Masney
@ 2025-08-11 10:33 ` Konrad Dybcio
2025-08-11 10:35 ` Dmitry Baryshkov
1 sibling, 0 replies; 24+ messages in thread
From: Konrad Dybcio @ 2025-08-11 10:33 UTC (permalink / raw)
To: Brian Masney, Rob Clark, Dmitry Baryshkov, Abhinav Kumar,
Jessica Zhang, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maxime Ripard, Stephen Boyd
Cc: linux-clk, linux-arm-msm, dri-devel, freedreno, linux-kernel
On 8/11/25 12:57 AM, Brian Masney wrote:
> The round_rate() clk ops is deprecated, so migrate this driver from
> round_rate() to determine_rate() using the Coccinelle semantic patch
> on the cover letter of this series. The change to use clamp_t() was
> done manually.
>
> Signed-off-by: Brian Masney <bmasney@redhat.com>
> ---
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Konrad
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 4/7] drm/msm/dsi_phy_28nm: convert from round_rate() to determine_rate()
2025-08-10 22:57 ` [PATCH v2 4/7] drm/msm/dsi_phy_28nm: " Brian Masney
2025-08-11 10:33 ` Konrad Dybcio
@ 2025-08-11 10:35 ` Dmitry Baryshkov
1 sibling, 0 replies; 24+ messages in thread
From: Dmitry Baryshkov @ 2025-08-11 10:35 UTC (permalink / raw)
To: Brian Masney
Cc: Rob Clark, Dmitry Baryshkov, Abhinav Kumar, Jessica Zhang,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maxime Ripard, Stephen Boyd, linux-clk, linux-arm-msm, dri-devel,
freedreno, linux-kernel
On Sun, Aug 10, 2025 at 06:57:28PM -0400, Brian Masney wrote:
> The round_rate() clk ops is deprecated, so migrate this driver from
> round_rate() to determine_rate() using the Coccinelle semantic patch
> on the cover letter of this series. The change to use clamp_t() was
> done manually.
>
> Signed-off-by: Brian Masney <bmasney@redhat.com>
> ---
> drivers/gpu/drm/msm/dsi/phy/dsi_phy_28nm.c | 21 ++++++++++-----------
> 1 file changed, 10 insertions(+), 11 deletions(-)
>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 24+ messages in thread
* [PATCH v2 5/7] drm/msm/dsi_phy_7nm: convert from round_rate() to determine_rate()
2025-08-10 22:57 [PATCH v2 0/7] drm/msm/dsi/phy: convert from clk round_rate() to determine_rate() Brian Masney
` (3 preceding siblings ...)
2025-08-10 22:57 ` [PATCH v2 4/7] drm/msm/dsi_phy_28nm: " Brian Masney
@ 2025-08-10 22:57 ` Brian Masney
2025-08-11 10:33 ` Konrad Dybcio
2025-08-11 10:35 ` Dmitry Baryshkov
2025-08-10 22:57 ` [PATCH v2 6/7] drm/msm/hdmi_phy_8996: " Brian Masney
` (2 subsequent siblings)
7 siblings, 2 replies; 24+ messages in thread
From: Brian Masney @ 2025-08-10 22:57 UTC (permalink / raw)
To: Rob Clark, Dmitry Baryshkov, Abhinav Kumar, Jessica Zhang,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maxime Ripard, Stephen Boyd
Cc: linux-clk, linux-arm-msm, dri-devel, freedreno, linux-kernel,
Brian Masney
The round_rate() clk ops is deprecated, so migrate this driver from
round_rate() to determine_rate() using the Coccinelle semantic patch
on the cover letter of this series. The change to use clamp_t() was
done manually.
Signed-off-by: Brian Masney <bmasney@redhat.com>
---
drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c | 16 +++++++---------
1 file changed, 7 insertions(+), 9 deletions(-)
diff --git a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c
index 8c98f91a5930c9f2563a6b4824690ceef56987c0..c3bd3f89434eb7d3d0f3bb9455d22aa00915e797 100644
--- a/drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c
+++ b/drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c
@@ -561,21 +561,19 @@ static unsigned long dsi_pll_7nm_vco_recalc_rate(struct clk_hw *hw,
return (unsigned long)vco_rate;
}
-static long dsi_pll_7nm_clk_round_rate(struct clk_hw *hw,
- unsigned long rate, unsigned long *parent_rate)
+static int dsi_pll_7nm_clk_determine_rate(struct clk_hw *hw,
+ struct clk_rate_request *req)
{
struct dsi_pll_7nm *pll_7nm = to_pll_7nm(hw);
- if (rate < pll_7nm->phy->cfg->min_pll_rate)
- return pll_7nm->phy->cfg->min_pll_rate;
- else if (rate > pll_7nm->phy->cfg->max_pll_rate)
- return pll_7nm->phy->cfg->max_pll_rate;
- else
- return rate;
+ req->rate = clamp_t(unsigned long, req->rate,
+ pll_7nm->phy->cfg->min_pll_rate, pll_7nm->phy->cfg->max_pll_rate);
+
+ return 0;
}
static const struct clk_ops clk_ops_dsi_pll_7nm_vco = {
- .round_rate = dsi_pll_7nm_clk_round_rate,
+ .determine_rate = dsi_pll_7nm_clk_determine_rate,
.set_rate = dsi_pll_7nm_vco_set_rate,
.recalc_rate = dsi_pll_7nm_vco_recalc_rate,
.prepare = dsi_pll_7nm_vco_prepare,
--
2.50.1
^ permalink raw reply related [flat|nested] 24+ messages in thread
* Re: [PATCH v2 5/7] drm/msm/dsi_phy_7nm: convert from round_rate() to determine_rate()
2025-08-10 22:57 ` [PATCH v2 5/7] drm/msm/dsi_phy_7nm: " Brian Masney
@ 2025-08-11 10:33 ` Konrad Dybcio
2025-08-11 10:35 ` Dmitry Baryshkov
1 sibling, 0 replies; 24+ messages in thread
From: Konrad Dybcio @ 2025-08-11 10:33 UTC (permalink / raw)
To: Brian Masney, Rob Clark, Dmitry Baryshkov, Abhinav Kumar,
Jessica Zhang, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maxime Ripard, Stephen Boyd
Cc: linux-clk, linux-arm-msm, dri-devel, freedreno, linux-kernel
On 8/11/25 12:57 AM, Brian Masney wrote:
> The round_rate() clk ops is deprecated, so migrate this driver from
> round_rate() to determine_rate() using the Coccinelle semantic patch
> on the cover letter of this series. The change to use clamp_t() was
> done manually.
>
> Signed-off-by: Brian Masney <bmasney@redhat.com>
> ---
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Konrad
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 5/7] drm/msm/dsi_phy_7nm: convert from round_rate() to determine_rate()
2025-08-10 22:57 ` [PATCH v2 5/7] drm/msm/dsi_phy_7nm: " Brian Masney
2025-08-11 10:33 ` Konrad Dybcio
@ 2025-08-11 10:35 ` Dmitry Baryshkov
1 sibling, 0 replies; 24+ messages in thread
From: Dmitry Baryshkov @ 2025-08-11 10:35 UTC (permalink / raw)
To: Brian Masney
Cc: Rob Clark, Dmitry Baryshkov, Abhinav Kumar, Jessica Zhang,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maxime Ripard, Stephen Boyd, linux-clk, linux-arm-msm, dri-devel,
freedreno, linux-kernel
On Sun, Aug 10, 2025 at 06:57:29PM -0400, Brian Masney wrote:
> The round_rate() clk ops is deprecated, so migrate this driver from
> round_rate() to determine_rate() using the Coccinelle semantic patch
> on the cover letter of this series. The change to use clamp_t() was
> done manually.
>
> Signed-off-by: Brian Masney <bmasney@redhat.com>
> ---
> drivers/gpu/drm/msm/dsi/phy/dsi_phy_7nm.c | 16 +++++++---------
> 1 file changed, 7 insertions(+), 9 deletions(-)
>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 24+ messages in thread
* [PATCH v2 6/7] drm/msm/hdmi_phy_8996: convert from round_rate() to determine_rate()
2025-08-10 22:57 [PATCH v2 0/7] drm/msm/dsi/phy: convert from clk round_rate() to determine_rate() Brian Masney
` (4 preceding siblings ...)
2025-08-10 22:57 ` [PATCH v2 5/7] drm/msm/dsi_phy_7nm: " Brian Masney
@ 2025-08-10 22:57 ` Brian Masney
2025-08-11 10:33 ` Konrad Dybcio
2025-08-11 10:35 ` Dmitry Baryshkov
2025-08-10 22:57 ` [PATCH v2 7/7] drm/msm/hdmi_phy_8998: " Brian Masney
2025-08-11 9:02 ` [PATCH v2 0/7] drm/msm/dsi/phy: convert from clk " Konrad Dybcio
7 siblings, 2 replies; 24+ messages in thread
From: Brian Masney @ 2025-08-10 22:57 UTC (permalink / raw)
To: Rob Clark, Dmitry Baryshkov, Abhinav Kumar, Jessica Zhang,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maxime Ripard, Stephen Boyd
Cc: linux-clk, linux-arm-msm, dri-devel, freedreno, linux-kernel,
Brian Masney
The round_rate() clk ops is deprecated, so migrate this driver from
round_rate() to determine_rate() using the Coccinelle semantic patch
on the cover letter of this series. The change to use clamp_t() was
done manually.
Signed-off-by: Brian Masney <bmasney@redhat.com>
---
drivers/gpu/drm/msm/hdmi/hdmi_phy_8996.c | 16 ++++++----------
1 file changed, 6 insertions(+), 10 deletions(-)
diff --git a/drivers/gpu/drm/msm/hdmi/hdmi_phy_8996.c b/drivers/gpu/drm/msm/hdmi/hdmi_phy_8996.c
index 8c8d80b59573a37a4008752b16e094a218802508..36e928b0fd5a319b6a12b9be52705c067d51c20b 100644
--- a/drivers/gpu/drm/msm/hdmi/hdmi_phy_8996.c
+++ b/drivers/gpu/drm/msm/hdmi/hdmi_phy_8996.c
@@ -629,16 +629,12 @@ static int hdmi_8996_pll_prepare(struct clk_hw *hw)
return 0;
}
-static long hdmi_8996_pll_round_rate(struct clk_hw *hw,
- unsigned long rate,
- unsigned long *parent_rate)
+static int hdmi_8996_pll_determine_rate(struct clk_hw *hw,
+ struct clk_rate_request *req)
{
- if (rate < HDMI_PCLK_MIN_FREQ)
- return HDMI_PCLK_MIN_FREQ;
- else if (rate > HDMI_PCLK_MAX_FREQ)
- return HDMI_PCLK_MAX_FREQ;
- else
- return rate;
+ req->rate = clamp_t(unsigned long, req->rate, HDMI_PCLK_MIN_FREQ, HDMI_PCLK_MAX_FREQ);
+
+ return 0;
}
static unsigned long hdmi_8996_pll_recalc_rate(struct clk_hw *hw,
@@ -684,7 +680,7 @@ static int hdmi_8996_pll_is_enabled(struct clk_hw *hw)
static const struct clk_ops hdmi_8996_pll_ops = {
.set_rate = hdmi_8996_pll_set_clk_rate,
- .round_rate = hdmi_8996_pll_round_rate,
+ .determine_rate = hdmi_8996_pll_determine_rate,
.recalc_rate = hdmi_8996_pll_recalc_rate,
.prepare = hdmi_8996_pll_prepare,
.unprepare = hdmi_8996_pll_unprepare,
--
2.50.1
^ permalink raw reply related [flat|nested] 24+ messages in thread
* Re: [PATCH v2 6/7] drm/msm/hdmi_phy_8996: convert from round_rate() to determine_rate()
2025-08-10 22:57 ` [PATCH v2 6/7] drm/msm/hdmi_phy_8996: " Brian Masney
@ 2025-08-11 10:33 ` Konrad Dybcio
2025-08-11 10:35 ` Dmitry Baryshkov
1 sibling, 0 replies; 24+ messages in thread
From: Konrad Dybcio @ 2025-08-11 10:33 UTC (permalink / raw)
To: Brian Masney, Rob Clark, Dmitry Baryshkov, Abhinav Kumar,
Jessica Zhang, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maxime Ripard, Stephen Boyd
Cc: linux-clk, linux-arm-msm, dri-devel, freedreno, linux-kernel
On 8/11/25 12:57 AM, Brian Masney wrote:
> The round_rate() clk ops is deprecated, so migrate this driver from
> round_rate() to determine_rate() using the Coccinelle semantic patch
> on the cover letter of this series. The change to use clamp_t() was
> done manually.
>
> Signed-off-by: Brian Masney <bmasney@redhat.com>
> ---
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Konrad
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 6/7] drm/msm/hdmi_phy_8996: convert from round_rate() to determine_rate()
2025-08-10 22:57 ` [PATCH v2 6/7] drm/msm/hdmi_phy_8996: " Brian Masney
2025-08-11 10:33 ` Konrad Dybcio
@ 2025-08-11 10:35 ` Dmitry Baryshkov
1 sibling, 0 replies; 24+ messages in thread
From: Dmitry Baryshkov @ 2025-08-11 10:35 UTC (permalink / raw)
To: Brian Masney
Cc: Rob Clark, Dmitry Baryshkov, Abhinav Kumar, Jessica Zhang,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maxime Ripard, Stephen Boyd, linux-clk, linux-arm-msm, dri-devel,
freedreno, linux-kernel
On Sun, Aug 10, 2025 at 06:57:30PM -0400, Brian Masney wrote:
> The round_rate() clk ops is deprecated, so migrate this driver from
> round_rate() to determine_rate() using the Coccinelle semantic patch
> on the cover letter of this series. The change to use clamp_t() was
> done manually.
>
> Signed-off-by: Brian Masney <bmasney@redhat.com>
> ---
> drivers/gpu/drm/msm/hdmi/hdmi_phy_8996.c | 16 ++++++----------
> 1 file changed, 6 insertions(+), 10 deletions(-)
>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 24+ messages in thread
* [PATCH v2 7/7] drm/msm/hdmi_phy_8998: convert from round_rate() to determine_rate()
2025-08-10 22:57 [PATCH v2 0/7] drm/msm/dsi/phy: convert from clk round_rate() to determine_rate() Brian Masney
` (5 preceding siblings ...)
2025-08-10 22:57 ` [PATCH v2 6/7] drm/msm/hdmi_phy_8996: " Brian Masney
@ 2025-08-10 22:57 ` Brian Masney
2025-08-11 10:33 ` Konrad Dybcio
2025-08-11 10:36 ` Dmitry Baryshkov
2025-08-11 9:02 ` [PATCH v2 0/7] drm/msm/dsi/phy: convert from clk " Konrad Dybcio
7 siblings, 2 replies; 24+ messages in thread
From: Brian Masney @ 2025-08-10 22:57 UTC (permalink / raw)
To: Rob Clark, Dmitry Baryshkov, Abhinav Kumar, Jessica Zhang,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maxime Ripard, Stephen Boyd
Cc: linux-clk, linux-arm-msm, dri-devel, freedreno, linux-kernel,
Brian Masney
The round_rate() clk ops is deprecated, so migrate this driver from
round_rate() to determine_rate() using the Coccinelle semantic patch
on the cover letter of this series. The change to use clamp_t() was
done manually.
Signed-off-by: Brian Masney <bmasney@redhat.com>
---
drivers/gpu/drm/msm/hdmi/hdmi_phy_8998.c | 16 ++++++----------
1 file changed, 6 insertions(+), 10 deletions(-)
diff --git a/drivers/gpu/drm/msm/hdmi/hdmi_phy_8998.c b/drivers/gpu/drm/msm/hdmi/hdmi_phy_8998.c
index 33bb48ae58a2da13b7e90ff419c6e05fec1466af..a86ff370636972168124da19e114f0acab2249d2 100644
--- a/drivers/gpu/drm/msm/hdmi/hdmi_phy_8998.c
+++ b/drivers/gpu/drm/msm/hdmi/hdmi_phy_8998.c
@@ -646,16 +646,12 @@ static int hdmi_8998_pll_prepare(struct clk_hw *hw)
return 0;
}
-static long hdmi_8998_pll_round_rate(struct clk_hw *hw,
- unsigned long rate,
- unsigned long *parent_rate)
+static int hdmi_8998_pll_determine_rate(struct clk_hw *hw,
+ struct clk_rate_request *req)
{
- if (rate < HDMI_PCLK_MIN_FREQ)
- return HDMI_PCLK_MIN_FREQ;
- else if (rate > HDMI_PCLK_MAX_FREQ)
- return HDMI_PCLK_MAX_FREQ;
- else
- return rate;
+ req->rate = clamp_t(unsigned long, req->rate, HDMI_PCLK_MIN_FREQ, HDMI_PCLK_MAX_FREQ);
+
+ return 0;
}
static unsigned long hdmi_8998_pll_recalc_rate(struct clk_hw *hw,
@@ -688,7 +684,7 @@ static int hdmi_8998_pll_is_enabled(struct clk_hw *hw)
static const struct clk_ops hdmi_8998_pll_ops = {
.set_rate = hdmi_8998_pll_set_clk_rate,
- .round_rate = hdmi_8998_pll_round_rate,
+ .determine_rate = hdmi_8998_pll_determine_rate,
.recalc_rate = hdmi_8998_pll_recalc_rate,
.prepare = hdmi_8998_pll_prepare,
.unprepare = hdmi_8998_pll_unprepare,
--
2.50.1
^ permalink raw reply related [flat|nested] 24+ messages in thread
* Re: [PATCH v2 7/7] drm/msm/hdmi_phy_8998: convert from round_rate() to determine_rate()
2025-08-10 22:57 ` [PATCH v2 7/7] drm/msm/hdmi_phy_8998: " Brian Masney
@ 2025-08-11 10:33 ` Konrad Dybcio
2025-08-11 10:36 ` Dmitry Baryshkov
1 sibling, 0 replies; 24+ messages in thread
From: Konrad Dybcio @ 2025-08-11 10:33 UTC (permalink / raw)
To: Brian Masney, Rob Clark, Dmitry Baryshkov, Abhinav Kumar,
Jessica Zhang, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maxime Ripard, Stephen Boyd
Cc: linux-clk, linux-arm-msm, dri-devel, freedreno, linux-kernel
On 8/11/25 12:57 AM, Brian Masney wrote:
> The round_rate() clk ops is deprecated, so migrate this driver from
> round_rate() to determine_rate() using the Coccinelle semantic patch
> on the cover letter of this series. The change to use clamp_t() was
> done manually.
>
> Signed-off-by: Brian Masney <bmasney@redhat.com>
> ---
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Konrad
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 7/7] drm/msm/hdmi_phy_8998: convert from round_rate() to determine_rate()
2025-08-10 22:57 ` [PATCH v2 7/7] drm/msm/hdmi_phy_8998: " Brian Masney
2025-08-11 10:33 ` Konrad Dybcio
@ 2025-08-11 10:36 ` Dmitry Baryshkov
1 sibling, 0 replies; 24+ messages in thread
From: Dmitry Baryshkov @ 2025-08-11 10:36 UTC (permalink / raw)
To: Brian Masney
Cc: Rob Clark, Dmitry Baryshkov, Abhinav Kumar, Jessica Zhang,
Sean Paul, Marijn Suijten, David Airlie, Simona Vetter,
Maxime Ripard, Stephen Boyd, linux-clk, linux-arm-msm, dri-devel,
freedreno, linux-kernel
On Sun, Aug 10, 2025 at 06:57:31PM -0400, Brian Masney wrote:
> The round_rate() clk ops is deprecated, so migrate this driver from
> round_rate() to determine_rate() using the Coccinelle semantic patch
> on the cover letter of this series. The change to use clamp_t() was
> done manually.
>
> Signed-off-by: Brian Masney <bmasney@redhat.com>
> ---
> drivers/gpu/drm/msm/hdmi/hdmi_phy_8998.c | 16 ++++++----------
> 1 file changed, 6 insertions(+), 10 deletions(-)
>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 0/7] drm/msm/dsi/phy: convert from clk round_rate() to determine_rate()
2025-08-10 22:57 [PATCH v2 0/7] drm/msm/dsi/phy: convert from clk round_rate() to determine_rate() Brian Masney
` (6 preceding siblings ...)
2025-08-10 22:57 ` [PATCH v2 7/7] drm/msm/hdmi_phy_8998: " Brian Masney
@ 2025-08-11 9:02 ` Konrad Dybcio
2025-08-11 10:32 ` Dmitry Baryshkov
7 siblings, 1 reply; 24+ messages in thread
From: Konrad Dybcio @ 2025-08-11 9:02 UTC (permalink / raw)
To: Brian Masney, Rob Clark, Dmitry Baryshkov, Abhinav Kumar,
Jessica Zhang, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maxime Ripard, Stephen Boyd
Cc: linux-clk, linux-arm-msm, dri-devel, freedreno, linux-kernel
On 8/11/25 12:57 AM, Brian Masney wrote:
> The round_rate() clk ops is deprecated in the clk framework in favor
> of the determine_rate() clk ops, so let's go ahead and convert the
> drivers in the drm/msm/dsi/phy subsystem using the Coccinelle semantic
> patch posted below. I did a few minor cosmetic cleanups of the code in a
> few cases.
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Konrad
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 0/7] drm/msm/dsi/phy: convert from clk round_rate() to determine_rate()
2025-08-11 9:02 ` [PATCH v2 0/7] drm/msm/dsi/phy: convert from clk " Konrad Dybcio
@ 2025-08-11 10:32 ` Dmitry Baryshkov
0 siblings, 0 replies; 24+ messages in thread
From: Dmitry Baryshkov @ 2025-08-11 10:32 UTC (permalink / raw)
To: Konrad Dybcio
Cc: Brian Masney, Rob Clark, Dmitry Baryshkov, Abhinav Kumar,
Jessica Zhang, Sean Paul, Marijn Suijten, David Airlie,
Simona Vetter, Maxime Ripard, Stephen Boyd, linux-clk,
linux-arm-msm, dri-devel, freedreno, linux-kernel
On Mon, Aug 11, 2025 at 11:02:46AM +0200, Konrad Dybcio wrote:
> On 8/11/25 12:57 AM, Brian Masney wrote:
> > The round_rate() clk ops is deprecated in the clk framework in favor
> > of the determine_rate() clk ops, so let's go ahead and convert the
> > drivers in the drm/msm/dsi/phy subsystem using the Coccinelle semantic
> > patch posted below. I did a few minor cosmetic cleanups of the code in a
> > few cases.
>
>
> Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Unfortunately pw-fdo doesn't track series replies. Could you please r-b
patches individually (sorry for the troubles).
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 24+ messages in thread