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: "Michel Dänzer" <michel.daenzer@amd.com>,
	"open list" <linux-kernel@vger.kernel.org>,
	"Alex Deucher" <alexander.deucher@amd.com>,
	"Gustavo Padovan" <gustavo.padovan@collabora.co.uk>,
	"Christian König" <christian.koenig@amd.com>
Subject: [PATCH 08/14] drm/amdgpu: use drm_crtc_vblank_{get,put}()
Date: Mon,  6 Jun 2016 11:41:39 -0300	[thread overview]
Message-ID: <1465224105-21485-8-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/amd/amdgpu/amdgpu_display.c | 4 ++--
 drivers/gpu/drm/amd/amdgpu/dce_v10_0.c      | 2 +-
 drivers/gpu/drm/amd/amdgpu/dce_v11_0.c      | 2 +-
 drivers/gpu/drm/amd/amdgpu/dce_v8_0.c       | 2 +-
 4 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c
index b0832da..0b5f3ac 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c
@@ -240,7 +240,7 @@ int amdgpu_crtc_page_flip(struct drm_crtc *crtc,
 
 	work->base = base;
 
-	r = drm_vblank_get(crtc->dev, amdgpu_crtc->crtc_id);
+	r = drm_crtc_vblank_get(crtc);
 	if (r) {
 		DRM_ERROR("failed to get vblank before flip\n");
 		goto pflip_cleanup;
@@ -268,7 +268,7 @@ int amdgpu_crtc_page_flip(struct drm_crtc *crtc,
 	return 0;
 
 vblank_cleanup:
-	drm_vblank_put(crtc->dev, amdgpu_crtc->crtc_id);
+	drm_crtc_vblank_put(&amdgpu_crtc->base);
 
 pflip_cleanup:
 	if (unlikely(amdgpu_bo_reserve(new_rbo, false) != 0)) {
diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c
index 8227344..7e57447 100644
--- a/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c
@@ -3372,7 +3372,7 @@ static int dce_v10_0_pageflip_irq(struct amdgpu_device *adev,
 
 	spin_unlock_irqrestore(&adev->ddev->event_lock, flags);
 
-	drm_vblank_put(adev->ddev, amdgpu_crtc->crtc_id);
+	drm_crtc_vblank_put(&amdgpu_crtc->base);
 	schedule_work(&works->unpin_work);
 
 	return 0;
diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c
index c11b600..6c51d9c 100644
--- a/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c
@@ -3433,7 +3433,7 @@ static int dce_v11_0_pageflip_irq(struct amdgpu_device *adev,
 
 	spin_unlock_irqrestore(&adev->ddev->event_lock, flags);
 
-	drm_vblank_put(adev->ddev, amdgpu_crtc->crtc_id);
+	drm_crtc_vblank_put(&amdgpu_crtc->base);
 	schedule_work(&works->unpin_work);
 
 	return 0;
diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c
index 3fb65e4..41d9bc5 100644
--- a/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c
@@ -3376,7 +3376,7 @@ static int dce_v8_0_pageflip_irq(struct amdgpu_device *adev,
 
 	spin_unlock_irqrestore(&adev->ddev->event_lock, flags);
 
-	drm_vblank_put(adev->ddev, amdgpu_crtc->crtc_id);
+	drm_crtc_vblank_put(&amdgpu_crtc->base);
 	schedule_work(&works->unpin_work);
 
 	return 0;
-- 
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 ` Gustavo Padovan [this message]
2016-06-06 15:26   ` [PATCH 08/14] drm/amdgpu: use drm_crtc_vblank_{get,put}() 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 ` [PATCH 09/14] drm/armada: " Gustavo Padovan
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-8-git-send-email-gustavo@padovan.org \
    --to=gustavo@padovan.org \
    --cc=alexander.deucher@amd.com \
    --cc=christian.koenig@amd.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gustavo.padovan@collabora.co.uk \
    --cc=linux-kernel@vger.kernel.org \
    --cc=michel.daenzer@amd.com \
    /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).