summaryrefslogtreecommitdiffstats
path: root/drivers/clk/st
diff options
context:
space:
mode:
authorGeert Uytterhoeven <geert+renesas@glider.be>2015-05-29 11:25:46 +0200
committerStephen Boyd <sboyd@codeaurora.org>2015-06-04 13:51:34 -0700
commit0a65239c280bb0d56d8d84c4a9cc78bc68144925 (patch)
tree14a9cd4a85d39911dbbaba93f10b16056561c9af /drivers/clk/st
parent51a43be9fa9016e02ef9c4214470c919223d138c (diff)
downloadop-kernel-dev-0a65239c280bb0d56d8d84c4a9cc78bc68144925.zip
op-kernel-dev-0a65239c280bb0d56d8d84c4a9cc78bc68144925.tar.gz
clk: st: Use of_clk_get_parent_count() instead of open coding
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
Diffstat (limited to 'drivers/clk/st')
-rw-r--r--drivers/clk/st/clk-flexgen.c2
-rw-r--r--drivers/clk/st/clkgen-mux.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/drivers/clk/st/clk-flexgen.c b/drivers/clk/st/clk-flexgen.c
index 409ed4b..657ca14 100644
--- a/drivers/clk/st/clk-flexgen.c
+++ b/drivers/clk/st/clk-flexgen.c
@@ -245,7 +245,7 @@ static const char ** __init flexgen_get_parents(struct device_node *np,
const char **parents;
int nparents, i;
- nparents = of_count_phandle_with_args(np, "clocks", "#clock-cells");
+ nparents = of_clk_get_parent_count(np);
if (WARN_ON(nparents <= 0))
return NULL;
diff --git a/drivers/clk/st/clkgen-mux.c b/drivers/clk/st/clkgen-mux.c
index 80aa77d..4fbe6e0 100644
--- a/drivers/clk/st/clkgen-mux.c
+++ b/drivers/clk/st/clkgen-mux.c
@@ -26,7 +26,7 @@ static const char ** __init clkgen_mux_get_parents(struct device_node *np,
const char **parents;
int nparents, i;
- nparents = of_count_phandle_with_args(np, "clocks", "#clock-cells");
+ nparents = of_clk_get_parent_count(np);
if (WARN_ON(nparents <= 0))
return ERR_PTR(-EINVAL);
OpenPOWER on IntegriCloud