Associated clock is prepared in st_rproc_parse_dt function.
it should be unprepared in case of error during probing.
Signed-off-by: Loic Pallardy <loic.pallardy@st.com>
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
enabled = st_rproc_state(pdev);
if (enabled < 0) {
ret = enabled;
- goto free_rproc;
+ goto free_clk;
}
if (enabled) {
ret = rproc_add(rproc);
if (ret)
- goto free_rproc;
+ goto free_clk;
return 0;
+free_clk:
+ clk_unprepare(ddata->clk);
free_rproc:
rproc_free(rproc);
return ret;