Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

clk: qcom: rpmhcc: add sdm670 clocks

The Snapdragon 670 uses the RPMh mailbox for most of the clocks used in
SDM845 but omits two. Add clock data for SDM670 so the driver doesn't fail
to resolve a clock.

Link: https://android.googlesource.com/kernel/msm/+/443bd8d6e2cf54698234c752e6de97b4b8a528bd%5E%21/#F7
Signed-off-by: Richard Acayan <mailingradian@gmail.com>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
Link: https://lore.kernel.org/r/20220920223734.151135-3-mailingradian@gmail.com

authored by

Richard Acayan and committed by
Bjorn Andersson
2ded040c c6648a40

+21
+21
drivers/clk/qcom/clk-rpmh.c
··· 378 378 .num_clks = ARRAY_SIZE(sdm845_rpmh_clocks), 379 379 }; 380 380 381 + static struct clk_hw *sdm670_rpmh_clocks[] = { 382 + [RPMH_CXO_CLK] = &sdm845_bi_tcxo.hw, 383 + [RPMH_CXO_CLK_A] = &sdm845_bi_tcxo_ao.hw, 384 + [RPMH_LN_BB_CLK2] = &sdm845_ln_bb_clk2.hw, 385 + [RPMH_LN_BB_CLK2_A] = &sdm845_ln_bb_clk2_ao.hw, 386 + [RPMH_LN_BB_CLK3] = &sdm845_ln_bb_clk3.hw, 387 + [RPMH_LN_BB_CLK3_A] = &sdm845_ln_bb_clk3_ao.hw, 388 + [RPMH_RF_CLK1] = &sdm845_rf_clk1.hw, 389 + [RPMH_RF_CLK1_A] = &sdm845_rf_clk1_ao.hw, 390 + [RPMH_RF_CLK2] = &sdm845_rf_clk2.hw, 391 + [RPMH_RF_CLK2_A] = &sdm845_rf_clk2_ao.hw, 392 + [RPMH_IPA_CLK] = &sdm845_ipa.hw, 393 + [RPMH_CE_CLK] = &sdm845_ce.hw, 394 + }; 395 + 396 + static const struct clk_rpmh_desc clk_rpmh_sdm670 = { 397 + .clks = sdm670_rpmh_clocks, 398 + .num_clks = ARRAY_SIZE(sdm670_rpmh_clocks), 399 + }; 400 + 381 401 DEFINE_CLK_RPMH_VRM(sdx55, rf_clk1, rf_clk1_ao, "rfclkd1", 1); 382 402 DEFINE_CLK_RPMH_VRM(sdx55, rf_clk2, rf_clk2_ao, "rfclkd2", 1); 383 403 DEFINE_CLK_RPMH_BCM(sdx55, qpic_clk, "QP0"); ··· 731 711 { .compatible = "qcom,sc8180x-rpmh-clk", .data = &clk_rpmh_sc8180x}, 732 712 { .compatible = "qcom,sc8280xp-rpmh-clk", .data = &clk_rpmh_sc8280xp}, 733 713 { .compatible = "qcom,sdm845-rpmh-clk", .data = &clk_rpmh_sdm845}, 714 + { .compatible = "qcom,sdm670-rpmh-clk", .data = &clk_rpmh_sdm670}, 734 715 { .compatible = "qcom,sdx55-rpmh-clk", .data = &clk_rpmh_sdx55}, 735 716 { .compatible = "qcom,sdx65-rpmh-clk", .data = &clk_rpmh_sdx65}, 736 717 { .compatible = "qcom,sm6350-rpmh-clk", .data = &clk_rpmh_sm6350},