mbox series

[v2,00/18] clk: qcom: smd-rpm: drop platform names

Message ID 20221207001503.93790-1-dmitry.baryshkov@linaro.org
Headers show
Series clk: qcom: smd-rpm: drop platform names | expand

Message

Dmitry Baryshkov Dec. 7, 2022, 12:14 a.m. UTC
This series concludes the previous work on Qualcomm RPM and RPMH clock
drivers. It reworks the clk-smd-rpm driver to drop the SoC name from the
clock symbol name, as the clock definitions are shared between different
SoCs (platforms). Having an SoC name in the clock definition can lead to
all sources of confusion and/or errors.

Changes since v1:
 - Split the MMXI/MMAXI and sm6375 vs sm6125 changes into two different
   patches
 - Reworked macro definitions and usage to remove empty arguments
 - Dropped qcm2290_bimc_gpu_clk definition in the corresponding patch
 - Alignment fixes

Dmitry Baryshkov (18):
  clk: qcom: smd-rpm: remove duplication between MMXI and MMAXI defines
  clk: qcom: smd-rpm: enable pin-controlled ln_bb_clk clocks on qcs404
  clk: qcom: smd-rpm: remove duplication between qcs404 and qcm2290
    clocks
  clk: qcom: smd-rpm: add missing ln_bb_clkN clocks
  clk: qcom: smd-rpm: use msm8998_ln_bb_clk2 for qcm2290 SoC
  clk: qcom: smd-rpm: rename msm8992_ln_bb_* clocks to qcs404_ln_bb_*
  clk: qcom: smd-rpm: remove duplication between sm6375 and sm6125
    clocks
  clk: qcom: smd-rpm: add XO_BUFFER clock for each XO_BUFFER_PINCTRL
    clock
  clk: qcom: smd-rpm: drop the rpm_status_id field
  clk: qcom: smd-rpm: fix alignment of line breaking backslashes
  clk: qcom: smd-rpm: move clock definitions together
  clk: qcom: smd-rpm: rename some msm8974 active-only clocks
  clk: qcom: smd-rpm: simplify XO_BUFFER clocks definitions
  clk: qcom: smd-rpm: simplify SMD_RPM/_BRANCH/_QDSS clock definitions
  clk: qcom: smd-rpm: rename SMD_RPM_BRANCH clock symbols
  clk: qcom: smd-rpm: rename the qcm2290 rf_clk3 clocks
  clk: qcom: smd-rpm: rename SMD_RPM_BUS clocks
  clk: qcom: smd-rpm: remove usage of platform name

 drivers/clk/qcom/clk-smd-rpm.c         | 1441 ++++++++++++------------
 include/dt-bindings/clock/qcom,rpmcc.h |    2 +
 include/linux/soc/qcom/smd-rpm.h       |    1 -
 3 files changed, 723 insertions(+), 721 deletions(-)

Comments

Alex Elder Dec. 7, 2022, 1:48 p.m. UTC | #1
On 12/6/22 6:14 PM, Dmitry Baryshkov wrote:
> The commit 52a436e0b7fe ("clk: qcom: smd-rpm: Switch to parent_data")
> introduced ragged right alignment for the line breaking backslash. Fix
> it to make the code look consistently.
> 
> Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>

Very pretty.

Reviewed-by: Alex Elder <elder@linaro.org>

> ---
>   drivers/clk/qcom/clk-smd-rpm.c | 32 ++++++++++++++++----------------
>   1 file changed, 16 insertions(+), 16 deletions(-)
> 
> diff --git a/drivers/clk/qcom/clk-smd-rpm.c b/drivers/clk/qcom/clk-smd-rpm.c
> index 2075cfd34f99..7e43ecdda763 100644
> --- a/drivers/clk/qcom/clk-smd-rpm.c
> +++ b/drivers/clk/qcom/clk-smd-rpm.c
> @@ -36,10 +36,10 @@
>   		.hw.init = &(struct clk_init_data){			      \
>   			.ops = &clk_smd_rpm_ops,			      \
>   			.name = #_name,					      \
> -			.parent_data =  &(const struct clk_parent_data){ \
> -					.fw_name = "xo",		\
> -					.name = "xo_board",		\
> -			},						\
> +			.parent_data =  &(const struct clk_parent_data){      \
> +					.fw_name = "xo",		      \
> +					.name = "xo_board",		      \
> +			},						      \
>   			.num_parents = 1,				      \
>   		},							      \
>   	};								      \
> @@ -53,10 +53,10 @@
>   		.hw.init = &(struct clk_init_data){			      \
>   			.ops = &clk_smd_rpm_ops,			      \
>   			.name = #_active,				      \
> -			.parent_data =  &(const struct clk_parent_data){ \
> -					.fw_name = "xo",		\
> -					.name = "xo_board",		\
> -			},						\
> +			.parent_data =  &(const struct clk_parent_data){      \
> +					.fw_name = "xo",		      \
> +					.name = "xo_board",		      \
> +			},						      \
>   			.num_parents = 1,				      \
>   		},							      \
>   	}
> @@ -74,10 +74,10 @@
>   		.hw.init = &(struct clk_init_data){			      \
>   			.ops = &clk_smd_rpm_branch_ops,			      \
>   			.name = #_name,					      \
> -			.parent_data =  &(const struct clk_parent_data){ \
> -					.fw_name = "xo",		\
> -					.name = "xo_board",		\
> -			},						\
> +			.parent_data =  &(const struct clk_parent_data){      \
> +					.fw_name = "xo",		      \
> +					.name = "xo_board",		      \
> +			},						      \
>   			.num_parents = 1,				      \
>   		},							      \
>   	};								      \
> @@ -92,10 +92,10 @@
>   		.hw.init = &(struct clk_init_data){			      \
>   			.ops = &clk_smd_rpm_branch_ops,			      \
>   			.name = #_active,				      \
> -			.parent_data =  &(const struct clk_parent_data){ \
> -					.fw_name = "xo",		\
> -					.name = "xo_board",		\
> -			},						\
> +			.parent_data =  &(const struct clk_parent_data){      \
> +					.fw_name = "xo",		      \
> +					.name = "xo_board",		      \
> +			},						      \
>   			.num_parents = 1,				      \
>   		},							      \
>   	}
Krzysztof Kozlowski Dec. 9, 2022, 4:14 p.m. UTC | #2
On 07/12/2022 01:14, Dmitry Baryshkov wrote:
> The commit eaeee28db289 ("clk: qcom: smd: Add support for QCS404 rpm
> clocks") defined the pin-controlled ln_bb_clk clocks, but didn't add
> them to the qcs404_clks array. Add them to make these clocks usable to
> platform devices.
> 

Please use scripts/get_maintainers.pl to get a list of necessary people
and lists to CC.  It might happen, that command when run on an older
kernel, gives you outdated entries.  Therefore please be sure you base
your patches on recent Linux kernel.

> Fixes: eaeee28db289 ("clk: qcom: smd: Add support for QCS404 rpm clocks")
> Reviewed-by: Alex Elder <elder@linaro.org?

Wrong character at the end.

> Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
> Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
> ---
>  drivers/clk/qcom/clk-smd-rpm.c         | 2 ++
>  include/dt-bindings/clock/qcom,rpmcc.h | 2 ++
>  2 files changed, 4 insertions(+)
> 

No, bindings are separate.

Best regards,
Krzysztof
Krzysztof Kozlowski Dec. 9, 2022, 4:15 p.m. UTC | #3
On 07/12/2022 01:14, Dmitry Baryshkov wrote:
> This series concludes the previous work on Qualcomm RPM and RPMH clock
> drivers. It reworks the clk-smd-rpm driver to drop the SoC name from the
> clock symbol name, as the clock definitions are shared between different
> SoCs (platforms). Having an SoC name in the clock definition can lead to
> all sources of confusion and/or errors.
> 
> Changes since v1:
>  - Split the MMXI/MMAXI and sm6375 vs sm6125 changes into two different
>    patches
>  - Reworked macro definitions and usage to remove empty arguments
>  - Dropped qcm2290_bimc_gpu_clk definition in the corresponding patch
>  - Alignment fixes
> 
> Dmitry Baryshkov (18):
>   clk: qcom: smd-rpm: remove duplication between MMXI and MMAXI defines
>   clk: qcom: smd-rpm: enable pin-controlled ln_bb_clk clocks on qcs404
>   clk: qcom: smd-rpm: remove duplication between qcs404 and qcm2290
>     clocks
>   clk: qcom: smd-rpm: add missing ln_bb_clkN clocks
>   clk: qcom: smd-rpm: use msm8998_ln_bb_clk2 for qcm2290 SoC
>   clk: qcom: smd-rpm: rename msm8992_ln_bb_* clocks to qcs404_ln_bb_*
>   clk: qcom: smd-rpm: remove duplication between sm6375 and sm6125
>     clocks
>   clk: qcom: smd-rpm: add XO_BUFFER clock for each XO_BUFFER_PINCTRL
>     clock
>   clk: qcom: smd-rpm: drop the rpm_status_id field
>   clk: qcom: smd-rpm: fix alignment of line breaking backslashes
>   clk: qcom: smd-rpm: move clock definitions together
>   clk: qcom: smd-rpm: rename some msm8974 active-only clocks
>   clk: qcom: smd-rpm: simplify XO_BUFFER clocks definitions
>   clk: qcom: smd-rpm: simplify SMD_RPM/_BRANCH/_QDSS clock definitions
>   clk: qcom: smd-rpm: rename SMD_RPM_BRANCH clock symbols
>   clk: qcom: smd-rpm: rename the qcm2290 rf_clk3 clocks
>   clk: qcom: smd-rpm: rename SMD_RPM_BUS clocks
>   clk: qcom: smd-rpm: remove usage of platform name
> 
>  drivers/clk/qcom/clk-smd-rpm.c         | 1441 ++++++++++++------------
>  include/dt-bindings/clock/qcom,rpmcc.h |    2 +

Please automate getting email addresses for sending emails.

Best regards,
Krzysztof
Dmitry Baryshkov Dec. 9, 2022, 4:28 p.m. UTC | #4
On Fri, 9 Dec 2022 at 18:14, Krzysztof Kozlowski
<krzysztof.kozlowski@linaro.org> wrote:
>
> On 07/12/2022 01:14, Dmitry Baryshkov wrote:
> > The commit eaeee28db289 ("clk: qcom: smd: Add support for QCS404 rpm
> > clocks") defined the pin-controlled ln_bb_clk clocks, but didn't add
> > them to the qcs404_clks array. Add them to make these clocks usable to
> > platform devices.
> >
>
> Please use scripts/get_maintainers.pl to get a list of necessary people
> and lists to CC.  It might happen, that command when run on an older
> kernel, gives you outdated entries.  Therefore please be sure you base
> your patches on recent Linux kernel.
>
> > Fixes: eaeee28db289 ("clk: qcom: smd: Add support for QCS404 rpm clocks")
> > Reviewed-by: Alex Elder <elder@linaro.org?
>
> Wrong character at the end.
>
> > Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
> > Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
> > ---
> >  drivers/clk/qcom/clk-smd-rpm.c         | 2 ++
> >  include/dt-bindings/clock/qcom,rpmcc.h | 2 ++
> >  2 files changed, 4 insertions(+)
> >
>
> No, bindings are separate.

Argh, I didn't realise that this piece also goes into your realm.
Please excuse me.

I'll send v2.
Krzysztof Kozlowski Dec. 9, 2022, 5:05 p.m. UTC | #5
On Fri, 9 Dec 2022 at 17:28, Dmitry Baryshkov
<dmitry.baryshkov@linaro.org> wrote:
>
> On Fri, 9 Dec 2022 at 18:14, Krzysztof Kozlowski
> <krzysztof.kozlowski@linaro.org> wrote:
> >
> > On 07/12/2022 01:14, Dmitry Baryshkov wrote:
> > > The commit eaeee28db289 ("clk: qcom: smd: Add support for QCS404 rpm
> > > clocks") defined the pin-controlled ln_bb_clk clocks, but didn't add
> > > them to the qcs404_clks array. Add them to make these clocks usable to
> > > platform devices.
> > >
> >
> > Please use scripts/get_maintainers.pl to get a list of necessary people
> > and lists to CC.  It might happen, that command when run on an older
> > kernel, gives you outdated entries.  Therefore please be sure you base
> > your patches on recent Linux kernel.
> >
> > > Fixes: eaeee28db289 ("clk: qcom: smd: Add support for QCS404 rpm clocks")
> > > Reviewed-by: Alex Elder <elder@linaro.org?
> >
> > Wrong character at the end.
> >
> > > Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
> > > Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
> > > ---
> > >  drivers/clk/qcom/clk-smd-rpm.c         | 2 ++
> > >  include/dt-bindings/clock/qcom,rpmcc.h | 2 ++
> > >  2 files changed, 4 insertions(+)
> > >
> >
> > No, bindings are separate.
>
> Argh, I didn't realise that this piece also goes into your realm.
> Please excuse me.

That's we we have checkpatch:

WARNING: DT binding docs and includes should be a separate patch. See:
Documentation/devicetree/bindings/submitting-patches.rst

Such issues are solved with tools. You will not miss any maintainers
if you automate the sending command (e.g. with identity and
tocmd/cccmd). The same with mixing files - checkpatch tests for it.

Best regards,
Krzysztof