aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNiklas Cassel <[email protected]>2020-01-03 12:14:29 +0100
committerStephen Boyd <[email protected]>2020-01-04 23:15:47 -0800
commitfbefb7cc8e5121d3db753a1c6a23b7f15f234b22 (patch)
tree150916ac00e9708d023dda6ac5a201817a1a39fb
parente7ce74bc0e97794d69330547aea4bbb0ff0be2bc (diff)
clk: qcom: apcs-msm8916: use clk_parent_data to specify the parent
Allow accessing the parent clock names required for the driver operation by using the device tree 'clock-names' property, while falling back to the previous method of using names in the global name space. This permits extending the driver to other platforms without having to modify its source code. Co-developed-by: Jorge Ramirez-Ortiz <[email protected]> Signed-off-by: Jorge Ramirez-Ortiz <[email protected]> Signed-off-by: Niklas Cassel <[email protected]> Link: https://lkml.kernel.org/r/[email protected] Tested-by: Bjorn Andersson <[email protected]> Reviewed-by: Bjorn Andersson <[email protected]> Signed-off-by: Stephen Boyd <[email protected]>
-rw-r--r--drivers/clk/qcom/apcs-msm8916.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/clk/qcom/apcs-msm8916.c b/drivers/clk/qcom/apcs-msm8916.c
index 46061b3d230e..cf69a97d0439 100644
--- a/drivers/clk/qcom/apcs-msm8916.c
+++ b/drivers/clk/qcom/apcs-msm8916.c
@@ -19,9 +19,9 @@
static const u32 gpll0_a53cc_map[] = { 4, 5 };
-static const char * const gpll0_a53cc[] = {
- "gpll0_vote",
- "a53pll",
+static const struct clk_parent_data pdata[] = {
+ { .fw_name = "aux", .name = "gpll0_vote", },
+ { .fw_name = "pll", .name = "a53pll", },
};
/*
@@ -62,8 +62,8 @@ static int qcom_apcs_msm8916_clk_probe(struct platform_device *pdev)
return -ENOMEM;
init.name = "a53mux";
- init.parent_names = gpll0_a53cc;
- init.num_parents = ARRAY_SIZE(gpll0_a53cc);
+ init.parent_data = pdata;
+ init.num_parents = ARRAY_SIZE(pdata);
init.ops = &clk_regmap_mux_div_ops;
init.flags = CLK_SET_RATE_PARENT;