drm/ttm: kill fence_lock
No users are left, kill it off! :D Conversion to the reservation api is next on the list, after that the functionality can be restored with rcu. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
This commit is contained in:
@@ -628,9 +628,7 @@ static int qxl_reap_surf(struct qxl_device *qdev, struct qxl_bo *surf, bool stal
|
||||
if (stall)
|
||||
mutex_unlock(&qdev->surf_evict_mutex);
|
||||
|
||||
spin_lock(&surf->tbo.bdev->fence_lock);
|
||||
ret = ttm_bo_wait(&surf->tbo, true, true, !stall);
|
||||
spin_unlock(&surf->tbo.bdev->fence_lock);
|
||||
|
||||
if (stall)
|
||||
mutex_lock(&qdev->surf_evict_mutex);
|
||||
|
@@ -60,9 +60,6 @@ int qxl_fence_remove_release(struct qxl_fence *qfence, uint32_t rel_id)
|
||||
{
|
||||
void *ret;
|
||||
int retval = 0;
|
||||
struct qxl_bo *bo = container_of(qfence, struct qxl_bo, fence);
|
||||
|
||||
spin_lock(&bo->tbo.bdev->fence_lock);
|
||||
|
||||
ret = radix_tree_delete(&qfence->tree, rel_id);
|
||||
if (ret == qfence)
|
||||
@@ -71,7 +68,6 @@ int qxl_fence_remove_release(struct qxl_fence *qfence, uint32_t rel_id)
|
||||
DRM_DEBUG("didn't find fence in radix tree for %d\n", rel_id);
|
||||
retval = -ENOENT;
|
||||
}
|
||||
spin_unlock(&bo->tbo.bdev->fence_lock);
|
||||
return retval;
|
||||
}
|
||||
|
||||
|
@@ -76,12 +76,10 @@ static inline int qxl_bo_wait(struct qxl_bo *bo, u32 *mem_type,
|
||||
}
|
||||
return r;
|
||||
}
|
||||
spin_lock(&bo->tbo.bdev->fence_lock);
|
||||
if (mem_type)
|
||||
*mem_type = bo->tbo.mem.mem_type;
|
||||
if (bo->tbo.sync_obj)
|
||||
r = ttm_bo_wait(&bo->tbo, true, true, no_wait);
|
||||
spin_unlock(&bo->tbo.bdev->fence_lock);
|
||||
ttm_bo_unreserve(&bo->tbo);
|
||||
return r;
|
||||
}
|
||||
|
@@ -337,7 +337,6 @@ void qxl_release_fence_buffer_objects(struct qxl_release *release)
|
||||
glob = bo->glob;
|
||||
|
||||
spin_lock(&glob->lru_lock);
|
||||
spin_lock(&bdev->fence_lock);
|
||||
|
||||
list_for_each_entry(entry, &release->bos, head) {
|
||||
bo = entry->bo;
|
||||
@@ -352,7 +351,6 @@ void qxl_release_fence_buffer_objects(struct qxl_release *release)
|
||||
__ttm_bo_unreserve(bo);
|
||||
entry->reserved = false;
|
||||
}
|
||||
spin_unlock(&bdev->fence_lock);
|
||||
spin_unlock(&glob->lru_lock);
|
||||
ww_acquire_fini(&release->ticket);
|
||||
}
|
||||
|
Reference in New Issue
Block a user