aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/i915_gem_batch_pool.c
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2017-02-21 09:17:23 +0000
committerChris Wilson <chris@chris-wilson.co.uk>2017-02-21 12:48:51 +0000
commite2989f140e707f31afa5fa617512961b3f692aca (patch)
tree5c551985dfc00a63e263cc99cfde25298d8364fe /drivers/gpu/drm/i915/i915_gem_batch_pool.c
parentdrm/i915: Assert that the request->tail is always qword aligned (diff)
downloadlinux-dev-e2989f140e707f31afa5fa617512961b3f692aca.tar.xz
linux-dev-e2989f140e707f31afa5fa617512961b3f692aca.zip
drm/i915: Use reservation_object_lock()
Replace the calls to ww_mutex_lock(&resv->lock) with the helper reservation_object_lock(resv) and similarly for unlock. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Link: http://patchwork.freedesktop.org/patch/msgid/20170221091723.6219-1-chris@chris-wilson.co.uk Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Diffstat (limited to 'drivers/gpu/drm/i915/i915_gem_batch_pool.c')
-rw-r--r--drivers/gpu/drm/i915/i915_gem_batch_pool.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/i915/i915_gem_batch_pool.c b/drivers/gpu/drm/i915/i915_gem_batch_pool.c
index b3bc119ec1bb..99ceae7855f8 100644
--- a/drivers/gpu/drm/i915/i915_gem_batch_pool.c
+++ b/drivers/gpu/drm/i915/i915_gem_batch_pool.c
@@ -122,9 +122,9 @@ i915_gem_batch_pool_get(struct i915_gem_batch_pool *pool,
if (tmp->base.size >= size) {
/* Clear the set of shared fences early */
- ww_mutex_lock(&tmp->resv->lock, NULL);
+ reservation_object_lock(tmp->resv, NULL);
reservation_object_add_excl_fence(tmp->resv, NULL);
- ww_mutex_unlock(&tmp->resv->lock);
+ reservation_object_unlock(tmp->resv);
obj = tmp;
break;