All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] clk: qcom: rpmh: add support for SM6350 rpmh IPA clock
@ 2022-11-29  0:00 Alex Elder
  2022-11-29  1:35 ` Dmitry Baryshkov
  0 siblings, 1 reply; 4+ messages in thread
From: Alex Elder @ 2022-11-29  0:00 UTC (permalink / raw)
  To: sboyd, mturquette, andersson, konrad.dybcio, agross
  Cc: Luca Weiss, linux-arm-msm, linux-clk, linux-kernel

From: Luca Weiss <luca.weiss@fairphone.com>

The IPA core clock is required for SM6350.  Define it.

Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
---
 drivers/clk/qcom/clk-rpmh.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/clk/qcom/clk-rpmh.c b/drivers/clk/qcom/clk-rpmh.c
index 0471bab824642..6a5887aae21a4 100644
--- a/drivers/clk/qcom/clk-rpmh.c
+++ b/drivers/clk/qcom/clk-rpmh.c
@@ -603,6 +603,7 @@ static const struct clk_rpmh_desc clk_rpmh_sc7280 = {
 DEFINE_CLK_RPMH_VRM(sm6350, ln_bb_clk2, ln_bb_clk2_ao, "lnbclkg2", 4);
 DEFINE_CLK_RPMH_VRM(sm6350, ln_bb_clk3, ln_bb_clk3_ao, "lnbclkg3", 4);
 DEFINE_CLK_RPMH_ARC(sm6350, qlink, qlink_ao, "qphy.lvl", 0x1, 4);
+DEFINE_CLK_RPMH_BCM(sm6350, ipa, "IP0");
 
 static struct clk_hw *sm6350_rpmh_clocks[] = {
 	[RPMH_CXO_CLK]		= &sc7280_bi_tcxo.hw,
@@ -613,6 +614,7 @@ static struct clk_hw *sm6350_rpmh_clocks[] = {
 	[RPMH_LN_BB_CLK3_A]	= &sm6350_ln_bb_clk3_ao.hw,
 	[RPMH_QLINK_CLK]	= &sm6350_qlink.hw,
 	[RPMH_QLINK_CLK_A]	= &sm6350_qlink_ao.hw,
+	[RPMH_IPA_CLK]		= &sm6350_ipa.hw,
 };
 
 static const struct clk_rpmh_desc clk_rpmh_sm6350 = {
-- 
2.34.1


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

* Re: [PATCH] clk: qcom: rpmh: add support for SM6350 rpmh IPA clock
  2022-11-29  0:00 [PATCH] clk: qcom: rpmh: add support for SM6350 rpmh IPA clock Alex Elder
@ 2022-11-29  1:35 ` Dmitry Baryshkov
  2022-11-29  1:54   ` Alex Elder
  0 siblings, 1 reply; 4+ messages in thread
From: Dmitry Baryshkov @ 2022-11-29  1:35 UTC (permalink / raw)
  To: Alex Elder
  Cc: sboyd, mturquette, andersson, konrad.dybcio, agross, Luca Weiss,
	linux-arm-msm, linux-clk, linux-kernel

On Tue, 29 Nov 2022 at 02:00, Alex Elder <elder@linaro.org> wrote:
>
> From: Luca Weiss <luca.weiss@fairphone.com>
>
> The IPA core clock is required for SM6350.  Define it.
>
> Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
> ---
>  drivers/clk/qcom/clk-rpmh.c | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/drivers/clk/qcom/clk-rpmh.c b/drivers/clk/qcom/clk-rpmh.c
> index 0471bab824642..6a5887aae21a4 100644
> --- a/drivers/clk/qcom/clk-rpmh.c
> +++ b/drivers/clk/qcom/clk-rpmh.c
> @@ -603,6 +603,7 @@ static const struct clk_rpmh_desc clk_rpmh_sc7280 = {
>  DEFINE_CLK_RPMH_VRM(sm6350, ln_bb_clk2, ln_bb_clk2_ao, "lnbclkg2", 4);
>  DEFINE_CLK_RPMH_VRM(sm6350, ln_bb_clk3, ln_bb_clk3_ao, "lnbclkg3", 4);
>  DEFINE_CLK_RPMH_ARC(sm6350, qlink, qlink_ao, "qphy.lvl", 0x1, 4);
> +DEFINE_CLK_RPMH_BCM(sm6350, ipa, "IP0");
>
>  static struct clk_hw *sm6350_rpmh_clocks[] = {
>         [RPMH_CXO_CLK]          = &sc7280_bi_tcxo.hw,
> @@ -613,6 +614,7 @@ static struct clk_hw *sm6350_rpmh_clocks[] = {
>         [RPMH_LN_BB_CLK3_A]     = &sm6350_ln_bb_clk3_ao.hw,
>         [RPMH_QLINK_CLK]        = &sm6350_qlink.hw,
>         [RPMH_QLINK_CLK_A]      = &sm6350_qlink_ao.hw,
> +       [RPMH_IPA_CLK]          = &sm6350_ipa.hw,

This can use sdm845_ipa.hw instead of defining new clocks.

>  };
>
>  static const struct clk_rpmh_desc clk_rpmh_sm6350 = {
> --
> 2.34.1
>


-- 
With best wishes
Dmitry

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

* Re: [PATCH] clk: qcom: rpmh: add support for SM6350 rpmh IPA clock
  2022-11-29  1:35 ` Dmitry Baryshkov
@ 2022-11-29  1:54   ` Alex Elder
  2022-11-29  9:28     ` Dmitry Baryshkov
  0 siblings, 1 reply; 4+ messages in thread
From: Alex Elder @ 2022-11-29  1:54 UTC (permalink / raw)
  To: Dmitry Baryshkov
  Cc: sboyd, mturquette, andersson, konrad.dybcio, agross, Luca Weiss,
	linux-arm-msm, linux-clk, linux-kernel

On 11/28/22 7:35 PM, Dmitry Baryshkov wrote:
> On Tue, 29 Nov 2022 at 02:00, Alex Elder <elder@linaro.org> wrote:
>>
>> From: Luca Weiss <luca.weiss@fairphone.com>
>>
>> The IPA core clock is required for SM6350.  Define it.
>>
>> Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
>> ---
>>   drivers/clk/qcom/clk-rpmh.c | 2 ++
>>   1 file changed, 2 insertions(+)
>>
>> diff --git a/drivers/clk/qcom/clk-rpmh.c b/drivers/clk/qcom/clk-rpmh.c
>> index 0471bab824642..6a5887aae21a4 100644
>> --- a/drivers/clk/qcom/clk-rpmh.c
>> +++ b/drivers/clk/qcom/clk-rpmh.c
>> @@ -603,6 +603,7 @@ static const struct clk_rpmh_desc clk_rpmh_sc7280 = {
>>   DEFINE_CLK_RPMH_VRM(sm6350, ln_bb_clk2, ln_bb_clk2_ao, "lnbclkg2", 4);
>>   DEFINE_CLK_RPMH_VRM(sm6350, ln_bb_clk3, ln_bb_clk3_ao, "lnbclkg3", 4);
>>   DEFINE_CLK_RPMH_ARC(sm6350, qlink, qlink_ao, "qphy.lvl", 0x1, 4);
>> +DEFINE_CLK_RPMH_BCM(sm6350, ipa, "IP0");

So you're saying that the above line is unnecessary...

>>   static struct clk_hw *sm6350_rpmh_clocks[] = {
>>          [RPMH_CXO_CLK]          = &sc7280_bi_tcxo.hw,
>> @@ -613,6 +614,7 @@ static struct clk_hw *sm6350_rpmh_clocks[] = {
>>          [RPMH_LN_BB_CLK3_A]     = &sm6350_ln_bb_clk3_ao.hw,
>>          [RPMH_QLINK_CLK]        = &sm6350_qlink.hw,
>>          [RPMH_QLINK_CLK_A]      = &sm6350_qlink_ao.hw,
>> +       [RPMH_IPA_CLK]          = &sm6350_ipa.hw,

...and that this line (above) can instead look like this:

	[RPMH_IPA_CLK]		= &sdm845_ipa.hw,

Correct?

> This can use sdm845_ipa.hw instead of defining new clocks.

Your statement seems to also be true for the [RPMH_IPA_CLK]
entry in sdx55_rpmh_clocks[].  (For the record, the commit
that added that one was authored by me, and I didn't realize
what you have stated here.)

Please confirm, and I'll update.

I'll also send another patch to remove the definition of
sdx55_ipa if Mani is willing to test it for me...

Thank you Dmitry.

					-Alex

>>   };
>>
>>   static const struct clk_rpmh_desc clk_rpmh_sm6350 = {
>> --
>> 2.34.1
>>
> 
> 


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

* Re: [PATCH] clk: qcom: rpmh: add support for SM6350 rpmh IPA clock
  2022-11-29  1:54   ` Alex Elder
@ 2022-11-29  9:28     ` Dmitry Baryshkov
  0 siblings, 0 replies; 4+ messages in thread
From: Dmitry Baryshkov @ 2022-11-29  9:28 UTC (permalink / raw)
  To: Alex Elder
  Cc: sboyd, mturquette, andersson, konrad.dybcio, agross, Luca Weiss,
	linux-arm-msm, linux-clk, linux-kernel

On Tue, 29 Nov 2022 at 03:54, Alex Elder <elder@linaro.org> wrote:
>
> On 11/28/22 7:35 PM, Dmitry Baryshkov wrote:
> > On Tue, 29 Nov 2022 at 02:00, Alex Elder <elder@linaro.org> wrote:
> >>
> >> From: Luca Weiss <luca.weiss@fairphone.com>
> >>
> >> The IPA core clock is required for SM6350.  Define it.
> >>
> >> Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
> >> ---
> >>   drivers/clk/qcom/clk-rpmh.c | 2 ++
> >>   1 file changed, 2 insertions(+)
> >>
> >> diff --git a/drivers/clk/qcom/clk-rpmh.c b/drivers/clk/qcom/clk-rpmh.c
> >> index 0471bab824642..6a5887aae21a4 100644
> >> --- a/drivers/clk/qcom/clk-rpmh.c
> >> +++ b/drivers/clk/qcom/clk-rpmh.c
> >> @@ -603,6 +603,7 @@ static const struct clk_rpmh_desc clk_rpmh_sc7280 = {
> >>   DEFINE_CLK_RPMH_VRM(sm6350, ln_bb_clk2, ln_bb_clk2_ao, "lnbclkg2", 4);
> >>   DEFINE_CLK_RPMH_VRM(sm6350, ln_bb_clk3, ln_bb_clk3_ao, "lnbclkg3", 4);
> >>   DEFINE_CLK_RPMH_ARC(sm6350, qlink, qlink_ao, "qphy.lvl", 0x1, 4);
> >> +DEFINE_CLK_RPMH_BCM(sm6350, ipa, "IP0");
>
> So you're saying that the above line is unnecessary...

Yes

>
> >>   static struct clk_hw *sm6350_rpmh_clocks[] = {
> >>          [RPMH_CXO_CLK]          = &sc7280_bi_tcxo.hw,
> >> @@ -613,6 +614,7 @@ static struct clk_hw *sm6350_rpmh_clocks[] = {
> >>          [RPMH_LN_BB_CLK3_A]     = &sm6350_ln_bb_clk3_ao.hw,
> >>          [RPMH_QLINK_CLK]        = &sm6350_qlink.hw,
> >>          [RPMH_QLINK_CLK_A]      = &sm6350_qlink_ao.hw,
> >> +       [RPMH_IPA_CLK]          = &sm6350_ipa.hw,
>
> ...and that this line (above) can instead look like this:
>
>         [RPMH_IPA_CLK]          = &sdm845_ipa.hw,
>
> Correct?

Yes

>
> > This can use sdm845_ipa.hw instead of defining new clocks.
>
> Your statement seems to also be true for the [RPMH_IPA_CLK]
> entry in sdx55_rpmh_clocks[].  (For the record, the commit
> that added that one was authored by me, and I didn't realize
> what you have stated here.)
>
> Please confirm, and I'll update.
>
> I'll also send another patch to remove the definition of
> sdx55_ipa if Mani is willing to test it for me...
>
> Thank you Dmitry.
>
>                                         -Alex
>
> >>   };
> >>
> >>   static const struct clk_rpmh_desc clk_rpmh_sm6350 = {
> >> --
> >> 2.34.1
> >>
> >
> >
>

--
With best wishes
Dmitry

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

end of thread, other threads:[~2022-11-29  9:28 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-29  0:00 [PATCH] clk: qcom: rpmh: add support for SM6350 rpmh IPA clock Alex Elder
2022-11-29  1:35 ` Dmitry Baryshkov
2022-11-29  1:54   ` Alex Elder
2022-11-29  9:28     ` Dmitry Baryshkov

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.