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>
This commit is contained in:
Georgi Djakov 2015-11-19 15:57:56 +02:00 committed by Stephen Boyd
parent d687767a91
commit cf81a1cf71

View File

@ -3357,18 +3357,16 @@ MODULE_DEVICE_TABLE(of, gcc_msm8916_match_table);
static int gcc_msm8916_probe(struct platform_device *pdev) static int gcc_msm8916_probe(struct platform_device *pdev)
{ {
struct clk *clk; int ret;
struct device *dev = &pdev->dev; struct device *dev = &pdev->dev;
/* Temporary until RPM clocks supported */ ret = qcom_cc_register_board_clk(dev, "xo_board", "xo", 19200000);
clk = clk_register_fixed_rate(dev, "xo", NULL, CLK_IS_ROOT, 19200000); if (ret)
if (IS_ERR(clk)) return ret;
return PTR_ERR(clk);
clk = clk_register_fixed_rate(dev, "sleep_clk_src", NULL, ret = qcom_cc_register_sleep_clk(dev);
CLK_IS_ROOT, 32768); if (ret)
if (IS_ERR(clk)) return ret;
return PTR_ERR(clk);
return qcom_cc_probe(pdev, &gcc_msm8916_desc); return qcom_cc_probe(pdev, &gcc_msm8916_desc);
} }