summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/ttm/ttm_execbuf_util.c
diff options
context:
space:
mode:
authorChristian König <christian.koenig@amd.com>2017-11-08 16:38:34 +0300
committerAlex Deucher <alexander.deucher@amd.com>2017-12-06 20:47:19 +0300
commit36a0680aac137a9b956fb454d6bf642c9aae0be1 (patch)
tree8d430b9f437bf54bea090ab0908830e261746986 /drivers/gpu/drm/ttm/ttm_execbuf_util.c
parenta376b0cedbb39d1504941821e424ef834325a717 (diff)
downloadlinux-36a0680aac137a9b956fb454d6bf642c9aae0be1.tar.xz
drm/ttm: consistently use reservation_object_unlock
Instead of having a confusing wrapper or call the underlying ww_mutex function directly. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-and-Tested-by: Michel Dänzer <michel.daenzer@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/ttm/ttm_execbuf_util.c')
-rw-r--r--drivers/gpu/drm/ttm/ttm_execbuf_util.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/gpu/drm/ttm/ttm_execbuf_util.c b/drivers/gpu/drm/ttm/ttm_execbuf_util.c
index 5e1bcabffef5..373ced0b2fc2 100644
--- a/drivers/gpu/drm/ttm/ttm_execbuf_util.c
+++ b/drivers/gpu/drm/ttm/ttm_execbuf_util.c
@@ -38,7 +38,7 @@ static void ttm_eu_backoff_reservation_reverse(struct list_head *list,
list_for_each_entry_continue_reverse(entry, list, head) {
struct ttm_buffer_object *bo = entry->bo;
- __ttm_bo_unreserve(bo);
+ reservation_object_unlock(bo->resv);
}
}
@@ -69,7 +69,7 @@ void ttm_eu_backoff_reservation(struct ww_acquire_ctx *ticket,
struct ttm_buffer_object *bo = entry->bo;
ttm_bo_add_to_lru(bo);
- __ttm_bo_unreserve(bo);
+ reservation_object_unlock(bo->resv);
}
spin_unlock(&glob->lru_lock);
@@ -112,7 +112,7 @@ int ttm_eu_reserve_buffers(struct ww_acquire_ctx *ticket,
ret = __ttm_bo_reserve(bo, intr, (ticket == NULL), ticket);
if (!ret && unlikely(atomic_read(&bo->cpu_writers) > 0)) {
- __ttm_bo_unreserve(bo);
+ reservation_object_unlock(bo->resv);
ret = -EBUSY;
@@ -203,7 +203,7 @@ void ttm_eu_fence_buffer_objects(struct ww_acquire_ctx *ticket,
else
reservation_object_add_excl_fence(bo->resv, fence);
ttm_bo_add_to_lru(bo);
- __ttm_bo_unreserve(bo);
+ reservation_object_unlock(bo->resv);
}
spin_unlock(&glob->lru_lock);
if (ticket)