Commit c284a0bd authored by Arvind Yadav's avatar Arvind Yadav Committed by Benjamin Gaignard

drm: sti: sti_hqvdp: undo preparation of a clock source.

Undo preparation of a clock source, if sti_hqvdp_start_xp70 and
sti_hqvdp_atomic_check are not successful.
Signed-off-by: default avatarArvind Yadav <arvind.yadav.cs@gmail.com>
Signed-off-by: default avatarBenjamin Gaignard <benjamin.gaignard@linaro.org>
Link: http://patchwork.freedesktop.org/patch/msgid/7afad3012fb6e40f43a1eb5a64dc6364c38bd052.1498039961.git.arvind.yadav.cs@gmail.com
parent 5a1535b1
...@@ -958,6 +958,7 @@ static void sti_hqvdp_start_xp70(struct sti_hqvdp *hqvdp) ...@@ -958,6 +958,7 @@ static void sti_hqvdp_start_xp70(struct sti_hqvdp *hqvdp)
} }
if (i == POLL_MAX_ATTEMPT) { if (i == POLL_MAX_ATTEMPT) {
DRM_ERROR("Could not reset\n"); DRM_ERROR("Could not reset\n");
clk_disable_unprepare(hqvdp->clk);
goto out; goto out;
} }
...@@ -994,6 +995,7 @@ static void sti_hqvdp_start_xp70(struct sti_hqvdp *hqvdp) ...@@ -994,6 +995,7 @@ static void sti_hqvdp_start_xp70(struct sti_hqvdp *hqvdp)
} }
if (i == POLL_MAX_ATTEMPT) { if (i == POLL_MAX_ATTEMPT) {
DRM_ERROR("Could not boot\n"); DRM_ERROR("Could not boot\n");
clk_disable_unprepare(hqvdp->clk);
goto out; goto out;
} }
...@@ -1081,6 +1083,7 @@ static int sti_hqvdp_atomic_check(struct drm_plane *drm_plane, ...@@ -1081,6 +1083,7 @@ static int sti_hqvdp_atomic_check(struct drm_plane *drm_plane,
&hqvdp->vtg_nb, &hqvdp->vtg_nb,
crtc)) { crtc)) {
DRM_ERROR("Cannot register VTG notifier\n"); DRM_ERROR("Cannot register VTG notifier\n");
clk_disable_unprepare(hqvdp->clk_pix_main);
return -EINVAL; return -EINVAL;
} }
hqvdp->vtg_registered = true; hqvdp->vtg_registered = true;
......
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