summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/msm/msm_atomic.c
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2019-06-25 23:42:03 +0300
committerDaniel Vetter <daniel.vetter@ffwll.ch>2019-06-28 01:27:59 +0300
commite78ad7654179f51e9ed99fe85358f4f3bbbda7bc (patch)
tree9759b935168c032ea16b746298e8571864ca9fdb /drivers/gpu/drm/msm/msm_atomic.c
parentbd630a86be381992fac99f9ab82c5c5b43a5ee3b (diff)
downloadlinux-e78ad7654179f51e9ed99fe85358f4f3bbbda7bc.tar.xz
drm/msm: Use drm_gem_fb_prepare_fb
msm has switched over to drm_fb->obj[] a while ago already, so we can just use the helper. v2: Make it compile ... oops. Cc: Eric Anholt <eric@anholt.net> Cc: Emil Velikov <emil.velikov@collabora.com> Reviewed-by: Eric Anholt <eric@anholt.net> Reviewed-by: Rob Clark <robdclark@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Cc: Rob Clark <robdclark@gmail.com> Cc: Sean Paul <sean@poorly.run> Cc: Jeykumar Sankaran <jsanka@codeaurora.org> Cc: Jordan Crouse <jcrouse@codeaurora.org> Cc: Bruce Wang <bzwang@chromium.org> Cc: Fritz Koenig <frkoenig@google.com> Cc: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: linux-arm-msm@vger.kernel.org Cc: freedreno@lists.freedesktop.org Link: https://patchwork.freedesktop.org/patch/msgid/20190625204208.5614-3-daniel.vetter@ffwll.ch
Diffstat (limited to 'drivers/gpu/drm/msm/msm_atomic.c')
-rw-r--r--drivers/gpu/drm/msm/msm_atomic.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/drivers/gpu/drm/msm/msm_atomic.c b/drivers/gpu/drm/msm/msm_atomic.c
index 131c23a267ee..3b13ea0ea92f 100644
--- a/drivers/gpu/drm/msm/msm_atomic.c
+++ b/drivers/gpu/drm/msm/msm_atomic.c
@@ -16,6 +16,7 @@
*/
#include <drm/drm_atomic_uapi.h>
+#include <drm/drm_gem_framebuffer_helper.h>
#include "msm_drv.h"
#include "msm_gem.h"
@@ -48,16 +49,11 @@ int msm_atomic_prepare_fb(struct drm_plane *plane,
{
struct msm_drm_private *priv = plane->dev->dev_private;
struct msm_kms *kms = priv->kms;
- struct drm_gem_object *obj;
- struct dma_fence *fence;
if (!new_state->fb)
return 0;
- obj = msm_framebuffer_bo(new_state->fb, 0);
- fence = reservation_object_get_excl_rcu(obj->resv);
-
- drm_atomic_set_fence_for_plane(new_state, fence);
+ drm_gem_fb_prepare_fb(plane, new_state);
return msm_framebuffer_prepare(new_state->fb, kms->aspace);
}