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

Commit 0a65239c authored by Geert Uytterhoeven's avatar Geert Uytterhoeven Committed by Stephen Boyd
Browse files

clk: st: Use of_clk_get_parent_count() instead of open coding

parent 51a43be9
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -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;

+1 −1
Original line number Diff line number Diff line
@@ -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);