Commit 47c5ee34 authored by Sudip Mukherjee's avatar Sudip Mukherjee Committed by Stephen Boyd

clk: versatile: fix memory leak

If of_clk_parent_fill() fails then we printed an error message and
returned. But we missed freeing sp810.
Signed-off-by: default avatarSudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: default avatarStephen Boyd <sboyd@codeaurora.org>
parent ed12dfc9
......@@ -102,6 +102,7 @@ static void __init clk_sp810_of_setup(struct device_node *node)
if (of_clk_parent_fill(node, parent_names, num) != num) {
pr_warn("Failed to obtain parent clocks for SP810!\n");
kfree(sp810);
return;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment