Instead use the new dma_resv_get_singleton function.

Signed-off-by: Christian König <christian.koe...@amd.com>
---
 drivers/gpu/drm/radeon/radeon_display.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/radeon/radeon_display.c 
b/drivers/gpu/drm/radeon/radeon_display.c
index 573154268d43..a6f875118f01 100644
--- a/drivers/gpu/drm/radeon/radeon_display.c
+++ b/drivers/gpu/drm/radeon/radeon_display.c
@@ -533,7 +533,12 @@ static int radeon_crtc_page_flip_target(struct drm_crtc 
*crtc,
                DRM_ERROR("failed to pin new rbo buffer before flip\n");
                goto cleanup;
        }
-       work->fence = 
dma_fence_get(dma_resv_excl_fence(new_rbo->tbo.base.resv));
+       r = dma_resv_get_singleton(new_rbo->tbo.base.resv, false, &work->fence);
+       if (r) {
+               radeon_bo_unreserve(new_rbo);
+               DRM_ERROR("failed to get new rbo buffer fences\n");
+               goto cleanup;
+       }
        radeon_bo_get_tiling_flags(new_rbo, &tiling_flags, NULL);
        radeon_bo_unreserve(new_rbo);
 
-- 
2.25.1

Reply via email to