dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
From: Gustavo Padovan <gustavo@padovan.org>
To: dri-devel@lists.freedesktop.org
Cc: Russell King <rmk+kernel@armlinux.org.uk>,
	Gustavo Padovan <gustavo.padovan@collabora.co.uk>,
	open list <linux-kernel@vger.kernel.org>
Subject: [PATCH 09/14] drm/armada: use drm_crtc_vblank_{get,put}()
Date: Mon,  6 Jun 2016 11:41:40 -0300	[thread overview]
Message-ID: <1465224105-21485-9-git-send-email-gustavo@padovan.org> (raw)
In-Reply-To: <1465224105-21485-1-git-send-email-gustavo@padovan.org>

From: Gustavo Padovan <gustavo.padovan@collabora.co.uk>

Replace the legacy drm_vblank_{get,put}() with the new helper functions.

Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
---
 drivers/gpu/drm/armada/armada_crtc.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/gpu/drm/armada/armada_crtc.c b/drivers/gpu/drm/armada/armada_crtc.c
index cdc4117..34405e4 100644
--- a/drivers/gpu/drm/armada/armada_crtc.c
+++ b/drivers/gpu/drm/armada/armada_crtc.c
@@ -199,7 +199,7 @@ static void armada_drm_plane_work_run(struct armada_crtc *dcrtc,
 	/* Handle any pending frame work. */
 	if (work) {
 		work->fn(dcrtc, plane, work);
-		drm_vblank_put(dcrtc->crtc.dev, dcrtc->num);
+		drm_crtc_vblank_put(&dcrtc->crtc);
 	}
 
 	wake_up(&plane->frame_wait);
@@ -210,7 +210,7 @@ int armada_drm_plane_work_queue(struct armada_crtc *dcrtc,
 {
 	int ret;
 
-	ret = drm_vblank_get(dcrtc->crtc.dev, dcrtc->num);
+	ret = drm_crtc_vblank_get(&dcrtc->crtc);
 	if (ret) {
 		DRM_ERROR("failed to acquire vblank counter\n");
 		return ret;
@@ -218,7 +218,7 @@ int armada_drm_plane_work_queue(struct armada_crtc *dcrtc,
 
 	ret = cmpxchg(&plane->work, NULL, work) ? -EBUSY : 0;
 	if (ret)
-		drm_vblank_put(dcrtc->crtc.dev, dcrtc->num);
+		drm_crtc_vblank_put(&dcrtc->crtc);
 
 	return ret;
 }
@@ -234,7 +234,7 @@ struct armada_plane_work *armada_drm_plane_work_cancel(
 	struct armada_plane_work *work = xchg(&plane->work, NULL);
 
 	if (work)
-		drm_vblank_put(dcrtc->crtc.dev, dcrtc->num);
+		drm_crtc_vblank_put(&dcrtc->crtc);
 
 	return work;
 }
@@ -592,9 +592,9 @@ static int armada_drm_crtc_mode_set(struct drm_crtc *crtc,
 
 	if (interlaced ^ dcrtc->interlaced) {
 		if (adj->flags & DRM_MODE_FLAG_INTERLACE)
-			drm_vblank_get(dcrtc->crtc.dev, dcrtc->num);
+			drm_crtc_vblank_get(&dcrtc->crtc);
 		else
-			drm_vblank_put(dcrtc->crtc.dev, dcrtc->num);
+			drm_crtc_vblank_put(&dcrtc->crtc);
 		dcrtc->interlaced = interlaced;
 	}
 
-- 
2.5.5

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

  parent reply	other threads:[~2016-06-06 14:42 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-06 14:41 [PATCH 01/14] drm/nouveau: use drm_crtc_send_vblank_event() v2 Gustavo Padovan
2016-06-06 14:41 ` [PATCH RESEND 02/14] drm/armada: use drm_crtc_send_vblank_event() Gustavo Padovan
2016-06-06 14:41 ` [PATCH RESEND 03/14] drm/atmel: " Gustavo Padovan
2016-06-07 11:08   ` Boris Brezillon
2016-06-06 14:41 ` [PATCH RESEND 04/14] drm/qxl: " Gustavo Padovan
2016-06-06 14:41 ` [PATCH RESEND 05/14] drm/udl: " Gustavo Padovan
2016-06-06 14:41 ` [PATCH RESEND 06/14] drm/virtio: " Gustavo Padovan
2016-06-07  8:39   ` Gerd Hoffmann
2016-06-06 14:41 ` [PATCH 07/14] drm: remove legacy drm_send_vblank_event() Gustavo Padovan
2016-06-06 14:41 ` [PATCH 08/14] drm/amdgpu: use drm_crtc_vblank_{get,put}() Gustavo Padovan
2016-06-06 15:26   ` Alex Deucher
2016-06-06 15:35     ` Gustavo Padovan
2016-06-06 16:06       ` Daniel Vetter
2016-06-07  3:43   ` Michel Dänzer
2016-06-06 14:41 ` Gustavo Padovan [this message]
2016-06-06 14:41 ` [PATCH 10/14] drm/atmel: " Gustavo Padovan
2016-06-07 11:07   ` Boris Brezillon
2016-06-06 14:41 ` [PATCH 11/14] drm/nouveau: " Gustavo Padovan
2016-06-06 14:41 ` [PATCH 12/14] drm/qxl: " Gustavo Padovan
2016-06-06 14:41 ` [PATCH 13/14] drm/radeon: " Gustavo Padovan
2016-06-06 14:41 ` [PATCH 14/14] drm/shmobile: " Gustavo Padovan
2016-06-06 18:25   ` Laurent Pinchart
2016-06-06 16:02 ` [PATCH 01/14] drm/nouveau: use drm_crtc_send_vblank_event() v2 Daniel Vetter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1465224105-21485-9-git-send-email-gustavo@padovan.org \
    --to=gustavo@padovan.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gustavo.padovan@collabora.co.uk \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rmk+kernel@armlinux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).