summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/ttm/ttm_bo.c
diff options
context:
space:
mode:
authorChristian König <christian.koenig@amd.com>2017-12-21 19:04:15 +0100
committerAlex Deucher <alexander.deucher@amd.com>2017-12-27 11:34:25 -0500
commit6a83a553033d6c3d8fb4683a9c87833ace44121b (patch)
treee92df341f1662e12011ea066fcf838784c4fdfdc /drivers/gpu/drm/ttm/ttm_bo.c
parent873a7ea3007b90fb8b507dc7d6eeb1ab705d4855 (diff)
drm/ttm: drop the spin in delayed delete if the trylock doesn't work
Thomas actually noticed that, but I didn't realized what he meant until now. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Roger He <Hongbo.He@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/ttm/ttm_bo.c')
-rw-r--r--drivers/gpu/drm/ttm/ttm_bo.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/ttm/ttm_bo.c
index 60bb5c12b568..84dfa2368a72 100644
--- a/drivers/gpu/drm/ttm/ttm_bo.c
+++ b/drivers/gpu/drm/ttm/ttm_bo.c
@@ -592,6 +592,8 @@ static bool ttm_bo_delayed_delete(struct ttm_bo_device *bdev, bool remove_all)
} else if (reservation_object_trylock(bo->resv)) {
ttm_bo_cleanup_refs(bo, false, !remove_all, true);
+ } else {
+ spin_unlock(&glob->lru_lock);
}
kref_put(&bo->list_kref, ttm_bo_release_list);