diff options
author | Eric Anholt <eric@anholt.net> | 2017-04-12 22:11:58 +0300 |
---|---|---|
committer | Rob Clark <robdclark@gmail.com> | 2017-05-27 20:48:26 +0300 |
commit | 43523eba79bda8f5b4c27f8ffe20ea078d20113a (patch) | |
tree | 2901b946f356d7bdd15a0036c826365eb405170a /drivers/gpu/drm/msm/msm_gem_prime.c | |
parent | 134ccada7ac59156761ce05afd1c0b1d02ebd928 (diff) | |
download | linux-43523eba79bda8f5b4c27f8ffe20ea078d20113a.tar.xz |
drm/msm: Expose our reservation object when exporting a dmabuf.
Without this, polling on the dma-buf (and presumably other devices
synchronizing against our rendering) would return immediately, even
while the BO was busy.
Signed-off-by: Eric Anholt <eric@anholt.net>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: stable@vger.kernel.org
Cc: Rob Clark <robdclark@gmail.com>
Cc: linux-arm-msm@vger.kernel.org
Cc: freedreno@lists.freedesktop.org
Reviewed-by: Rob Clark <robdclark@gmail.com>
Signed-off-by: Rob Clark <robdclark@gmail.com>
Diffstat (limited to 'drivers/gpu/drm/msm/msm_gem_prime.c')
-rw-r--r-- | drivers/gpu/drm/msm/msm_gem_prime.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/gpu/drm/msm/msm_gem_prime.c b/drivers/gpu/drm/msm/msm_gem_prime.c index 60bb290700ce..13403c6da6c7 100644 --- a/drivers/gpu/drm/msm/msm_gem_prime.c +++ b/drivers/gpu/drm/msm/msm_gem_prime.c @@ -70,3 +70,10 @@ void msm_gem_prime_unpin(struct drm_gem_object *obj) if (!obj->import_attach) msm_gem_put_pages(obj); } + +struct reservation_object *msm_gem_prime_res_obj(struct drm_gem_object *obj) +{ + struct msm_gem_object *msm_obj = to_msm_bo(obj); + + return msm_obj->resv; +} |