Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5f046bd2 authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "clk: qcom: smd-rpm: Add support for clock handoff"

parents 5f689b7e a03c45d4
Loading
Loading
Loading
Loading
+11 −11
Original line number Diff line number Diff line
@@ -831,8 +831,6 @@ DEFINE_CLK_SMD_RPM(holi, pka_clk, pka_a_clk, QCOM_SMD_RPM_PKA_CLK, 0);
/* SMD_XO_BUFFER */
DEFINE_CLK_SMD_RPM_XO_BUFFER(holi, ln_bb_clk2, ln_bb_clk2_a,
				QCOM_SMD_RPM_CLK_BUF_G, 8);
DEFINE_CLK_SMD_RPM_XO_BUFFER(holi, ln_bb_clk3, ln_bb_clk3_a,
				QCOM_SMD_RPM_CLK_BUF_G, 9);
DEFINE_CLK_SMD_RPM_XO_BUFFER(holi, rf_clk5, rf_clk5_a,
				QCOM_SMD_RPM_CLK_BUF_G, 6);

@@ -848,8 +846,6 @@ static struct clk_hw *holi_clks[] = {
	[RPM_SMD_QDSS_A_CLK] = &holi_qdss_a_clk.hw,
	[RPM_SMD_LN_BB_CLK2] = &holi_ln_bb_clk2.hw,
	[RPM_SMD_LN_BB_CLK2_A] = &holi_ln_bb_clk2_a.hw,
	[RPM_SMD_LN_BB_CLK3] = &holi_ln_bb_clk3.hw,
	[RPM_SMD_LN_BB_CLK3_A] = &holi_ln_bb_clk3_a.hw,
	[RPM_SMD_RF_CLK5] = &holi_rf_clk5.hw,
	[RPM_SMD_RF_CLK5_A] = &holi_rf_clk5_a.hw,
	[RPM_SMD_CNOC_CLK] = &holi_cnoc_clk.hw,
@@ -916,7 +912,7 @@ static int rpm_smd_clk_probe(struct platform_device *pdev)
{
	struct clk_hw **hw_clks;
	const struct rpm_smd_clk_desc *desc;
	int ret, i, is_holi;
	int ret, i, is_holi, hw_clk_handoff = false;

	desc = of_device_get_match_data(&pdev->dev);
	if (!desc)
@@ -932,6 +928,9 @@ static int rpm_smd_clk_probe(struct platform_device *pdev)

	hw_clks = desc->clks;

	hw_clk_handoff = of_property_read_bool(pdev->dev.of_node,
						"qcom,hw-clk-handoff");
	if (hw_clk_handoff) {
		for (i = 0; i < desc->num_clks; i++) {
			if (!hw_clks[i])
				continue;
@@ -940,6 +939,7 @@ static int rpm_smd_clk_probe(struct platform_device *pdev)
			if (ret)
				goto err;
		}
	}

	ret = clk_smd_rpm_enable_scaling();
	if (ret)