summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/exynos/exynos_drm_vidi.c
diff options
context:
space:
mode:
authorImre Deak <imre.deak@intel.com>2012-11-02 13:30:48 +0200
committerInki Dae <daeinki@gmail.com>2012-11-29 03:30:33 -0800
commite1f48ee58a90ddf84f514334b5d395a358596492 (patch)
treefe122bc62387c70c075a8a7e53a384878edfe4a6 /drivers/gpu/drm/exynos/exynos_drm_vidi.c
parent85473328bac6170aabb5e13d2542d11d1fc4cc76 (diff)
drm/exynos: call drm_vblank_put for each queued flip event
It's guaranteed that for each event on pageflip_event_list we have called drm_vblank_get() - see exynos_drm_crtc_page_flip() - so checking for this is redundant. Also we need to call drm_vblank_put() for each event on the list, not only once, otherwise we'd leak vblank references if there are multiple events on the list. Signed-off-by: Imre Deak <imre.deak@intel.com> Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Diffstat (limited to 'drivers/gpu/drm/exynos/exynos_drm_vidi.c')
-rw-r--r--drivers/gpu/drm/exynos/exynos_drm_vidi.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/gpu/drm/exynos/exynos_drm_vidi.c b/drivers/gpu/drm/exynos/exynos_drm_vidi.c
index e4b8a8f741f7..e26d45577551 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_vidi.c
+++ b/drivers/gpu/drm/exynos/exynos_drm_vidi.c
@@ -401,17 +401,11 @@ static void vidi_finish_pageflip(struct drm_device *drm_dev, int crtc)
list_move_tail(&e->base.link, &e->base.file_priv->event_list);
wake_up_interruptible(&e->base.file_priv->event_wait);
+ drm_vblank_put(drm_dev, crtc);
}
if (is_checked) {
/*
- * call drm_vblank_put only in case that drm_vblank_get was
- * called.
- */
- if (atomic_read(&drm_dev->vblank_refcount[crtc]) > 0)
- drm_vblank_put(drm_dev, crtc);
-
- /*
* don't off vblank if vblank_disable_allowed is 1,
* because vblank would be off by timer handler.
*/