clk: imx: gate2: Resolve parent clock by name
Use clock-names property which is accessible via parent clock OF node to look up the parent clock by name instead of depending on unreliable global clock name to perform look up. Signed-off-by: Marek Vasut <marex@denx.de>
This commit is contained in:

committed by
Fabio Estevam

parent
2eafd7a28e
commit
5d82183d4a
@@ -111,7 +111,8 @@ struct clk *clk_register_gate2(struct udevice *dev, const char *name,
|
||||
|
||||
clk = &gate->clk;
|
||||
|
||||
ret = clk_register(clk, UBOOT_DM_CLK_IMX_GATE2, name, parent_name);
|
||||
ret = clk_register(clk, UBOOT_DM_CLK_IMX_GATE2, name,
|
||||
clk_resolve_parent_clk(dev, parent_name));
|
||||
if (ret) {
|
||||
kfree(gate);
|
||||
return ERR_PTR(ret);
|
||||
|
Reference in New Issue
Block a user