Skip to content

Commit cf81a1c

Browse files
Georgi Djakovbebarino
authored andcommitted
clk: qcom: msm8916: Move xo and sleep clocks into DT
Move the xo and sleep clocks to device-tree, instead of hard-coding them in the driver. This allows us to insert the RPM clocks (if they are enabled) in between the on-board oscillators and the actual clock. Signed-off-by: Georgi Djakov <georgi.djakov@linaro.org> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
1 parent d687767 commit cf81a1c

1 file changed

Lines changed: 7 additions & 9 deletions

File tree

‎drivers/clk/qcom/gcc-msm8916.c‎

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3357,18 +3357,16 @@ MODULE_DEVICE_TABLE(of, gcc_msm8916_match_table);
33573357

33583358
static int gcc_msm8916_probe(struct platform_device *pdev)
33593359
{
3360-
struct clk *clk;
3360+
int ret;
33613361
struct device *dev = &pdev->dev;
33623362

3363-
/* Temporary until RPM clocks supported */
3364-
clk = clk_register_fixed_rate(dev, "xo", NULL, CLK_IS_ROOT, 19200000);
3365-
if (IS_ERR(clk))
3366-
return PTR_ERR(clk);
3363+
ret = qcom_cc_register_board_clk(dev, "xo_board", "xo", 19200000);
3364+
if (ret)
3365+
return ret;
33673366

3368-
clk = clk_register_fixed_rate(dev, "sleep_clk_src", NULL,
3369-
CLK_IS_ROOT, 32768);
3370-
if (IS_ERR(clk))
3371-
return PTR_ERR(clk);
3367+
ret = qcom_cc_register_sleep_clk(dev);
3368+
if (ret)
3369+
return ret;
33723370

33733371
return qcom_cc_probe(pdev, &gcc_msm8916_desc);
33743372
}

0 commit comments

Comments
 (0)