Commit 055d5689 authored by Shawn Guo's avatar Shawn Guo Committed by Shawn Guo

clk: hi3798cv200: fix unregister call sequence in error path

The unregister call sequence in error path of function
hi3798cv200_clk_register() should be opposite to the order of register
calls.  Let's reverse the call sequence to fix the problem.
Signed-off-by: default avatarShawn Guo <shawn.guo@linaro.org>
parent 7928b2cb
......@@ -202,18 +202,17 @@ static struct hisi_clock_data *hi3798cv200_clk_register(
return clk_data;
unregister_fixed_rate:
hisi_clk_unregister_fixed_rate(hi3798cv200_fixed_rate_clks,
ARRAY_SIZE(hi3798cv200_fixed_rate_clks),
unregister_gate:
hisi_clk_unregister_gate(hi3798cv200_gate_clks,
ARRAY_SIZE(hi3798cv200_gate_clks),
clk_data);
unregister_mux:
hisi_clk_unregister_mux(hi3798cv200_mux_clks,
ARRAY_SIZE(hi3798cv200_mux_clks),
clk_data);
unregister_gate:
hisi_clk_unregister_gate(hi3798cv200_gate_clks,
ARRAY_SIZE(hi3798cv200_gate_clks),
unregister_fixed_rate:
hisi_clk_unregister_fixed_rate(hi3798cv200_fixed_rate_clks,
ARRAY_SIZE(hi3798cv200_fixed_rate_clks),
clk_data);
return ERR_PTR(ret);
}
......
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