From: Gustavo Padovan <gustavo@padovan.org>
To: dri-devel@lists.freedesktop.org
Cc: linux-kernel@vger.kernel.org,
Daniel Stone <daniels@collabora.com>,
Daniel Vetter <daniel.vetter@ffwll.ch>,
Rob Clark <robdclark@gmail.com>,
Greg Hackmann <ghackmann@google.com>,
John Harrison <John.C.Harrison@Intel.com>,
laurent.pinchart@ideasonboard.com, seanpaul@google.com,
marcheu@google.com, m.chehab@samsung.com,
Sumit Semwal <sumit.semwal@linaro.org>,
Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
Brian Starkey <brian.starkey@arm.com>,
Gustavo Padovan <gustavo.padovan@collabora.co.uk>
Subject: [PATCH v6 3/6] drm/msm: use drm_atomic_set_fence_for_plane() to set the fence
Date: Thu, 27 Oct 2016 17:37:08 -0200 [thread overview]
Message-ID: <1477597031-5139-4-git-send-email-gustavo@padovan.org> (raw)
In-Reply-To: <1477597031-5139-1-git-send-email-gustavo@padovan.org>
From: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
drm_atomic_set_fence_for_plane() is smart and won't overwrite
plane_state->fence if the user already set an explicit fence there.
Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
---
drivers/gpu/drm/msm/msm_atomic.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/msm/msm_atomic.c b/drivers/gpu/drm/msm/msm_atomic.c
index db193f8..4e21e1d 100644
--- a/drivers/gpu/drm/msm/msm_atomic.c
+++ b/drivers/gpu/drm/msm/msm_atomic.c
@@ -217,8 +217,9 @@ int msm_atomic_commit(struct drm_device *dev,
if ((plane->state->fb != plane_state->fb) && plane_state->fb) {
struct drm_gem_object *obj = msm_framebuffer_bo(plane_state->fb, 0);
struct msm_gem_object *msm_obj = to_msm_bo(obj);
+ struct dma_fence *fence = reservation_object_get_excl_rcu(msm_obj->resv);
- plane_state->fence = reservation_object_get_excl_rcu(msm_obj->resv);
+ drm_atomic_set_fence_for_plane(plane_state, fence);
}
}
--
2.5.5
next prev parent reply other threads:[~2016-10-27 19:37 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-10-27 19:37 [PATCH v6 0/6] drm: add explict fencing Gustavo Padovan
2016-10-27 19:37 ` [PATCH v6 1/6] drm/atomic: add drm_atomic_set_fence_for_plane() Gustavo Padovan
2016-10-28 7:30 ` Daniel Vetter
2016-10-28 7:33 ` Daniel Vetter
2016-10-27 19:37 ` [PATCH v6 2/6] drm/imx: use drm_atomic_set_fence_for_plane() to set the fence Gustavo Padovan
2016-10-28 7:34 ` Daniel Vetter
2016-10-27 19:37 ` Gustavo Padovan [this message]
2016-10-28 7:34 ` [PATCH v6 3/6] drm/msm: " Daniel Vetter
2016-10-27 19:37 ` [PATCH v6 4/6] drm/fence: add in-fences support Gustavo Padovan
2016-10-28 7:39 ` Daniel Vetter
2016-10-28 12:32 ` Gustavo Padovan
2016-10-27 19:37 ` [PATCH v6 5/6] drm/fence: add fence timeline to drm_crtc Gustavo Padovan
2016-10-28 7:42 ` Daniel Vetter
2016-10-28 8:57 ` Brian Starkey
2016-10-27 19:37 ` [PATCH v6 6/6] drm/fence: add out-fences support Gustavo Padovan
2016-10-28 7:58 ` Daniel Vetter
2016-10-28 9:23 ` Brian Starkey
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=1477597031-5139-4-git-send-email-gustavo@padovan.org \
--to=gustavo@padovan.org \
--cc=John.C.Harrison@Intel.com \
--cc=brian.starkey@arm.com \
--cc=daniel.vetter@ffwll.ch \
--cc=daniels@collabora.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=ghackmann@google.com \
--cc=gustavo.padovan@collabora.co.uk \
--cc=laurent.pinchart@ideasonboard.com \
--cc=linux-kernel@vger.kernel.org \
--cc=m.chehab@samsung.com \
--cc=maarten.lankhorst@linux.intel.com \
--cc=marcheu@google.com \
--cc=robdclark@gmail.com \
--cc=seanpaul@google.com \
--cc=sumit.semwal@linaro.org \
/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
all inboxes | Powered by JetHome®