Commit 078ace6f authored by Gustavo Padovan's avatar Gustavo Padovan Committed by Daniel Vetter

drm/qxl: use drm_crtc_vblank_{get,put}()

Replace the legacy drm_vblank_{get,put}() with the new helper functions.
Signed-off-by: default avatarGustavo Padovan <gustavo.padovan@collabora.co.uk>
Reviewed-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
Link: http://patchwork.freedesktop.org/patch/msgid/1465224105-21485-12-git-send-email-gustavo@padovan.org
parent 23a25ed3
...@@ -221,7 +221,6 @@ static int qxl_crtc_page_flip(struct drm_crtc *crtc, ...@@ -221,7 +221,6 @@ static int qxl_crtc_page_flip(struct drm_crtc *crtc,
{ {
struct drm_device *dev = crtc->dev; struct drm_device *dev = crtc->dev;
struct qxl_device *qdev = dev->dev_private; struct qxl_device *qdev = dev->dev_private;
struct qxl_crtc *qcrtc = to_qxl_crtc(crtc);
struct qxl_framebuffer *qfb_src = to_qxl_framebuffer(fb); struct qxl_framebuffer *qfb_src = to_qxl_framebuffer(fb);
struct qxl_framebuffer *qfb_old = to_qxl_framebuffer(crtc->primary->fb); struct qxl_framebuffer *qfb_old = to_qxl_framebuffer(crtc->primary->fb);
struct qxl_bo *bo_old = gem_to_qxl_bo(qfb_old->obj); struct qxl_bo *bo_old = gem_to_qxl_bo(qfb_old->obj);
...@@ -252,14 +251,14 @@ static int qxl_crtc_page_flip(struct drm_crtc *crtc, ...@@ -252,14 +251,14 @@ static int qxl_crtc_page_flip(struct drm_crtc *crtc,
qxl_draw_dirty_fb(qdev, qfb_src, bo, 0, 0, qxl_draw_dirty_fb(qdev, qfb_src, bo, 0, 0,
&norect, one_clip_rect, inc); &norect, one_clip_rect, inc);
drm_vblank_get(dev, qcrtc->index); drm_crtc_vblank_get(crtc);
if (event) { if (event) {
spin_lock_irqsave(&dev->event_lock, flags); spin_lock_irqsave(&dev->event_lock, flags);
drm_crtc_send_vblank_event(crtc, event); drm_crtc_send_vblank_event(crtc, event);
spin_unlock_irqrestore(&dev->event_lock, flags); spin_unlock_irqrestore(&dev->event_lock, flags);
} }
drm_vblank_put(dev, qcrtc->index); drm_crtc_vblank_put(crtc);
ret = qxl_bo_reserve(bo, false); ret = qxl_bo_reserve(bo, false);
if (!ret) { if (!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