]> git.baikalelectronics.ru Git - kernel.git/commit
drm/ttm: rework BO delayed delete. v2
authorChristian König <christian.koenig@amd.com>
Mon, 11 Nov 2019 13:42:13 +0000 (14:42 +0100)
committerChristian König <christian.koenig@amd.com>
Wed, 12 Feb 2020 12:03:27 +0000 (13:03 +0100)
commit6dddf9f225e88e0f01d75487ae6fbcb394c455d8
treedb1e8f34b59de4896c52a252fd785cdef0510907
parent17c768517b351d718a5eaa796e113cbd5bf58178
drm/ttm: rework BO delayed delete. v2

This patch reworks the whole delayed deletion of BOs which aren't idle.

Instead of having two counters for the BO structure we resurrect the BO
when we find that a deleted BO is not idle yet.

This has many advantages, especially that we don't need to
increment/decrement the BOs reference counter any more when it
moves on the LRUs.

v2: remove duplicate ttm_tt_destroy, fix holde lock for LRU move

Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: xinhui pan <xinhui.pan@amd.com>
Link: https://patchwork.freedesktop.org/patch/352912/
drivers/gpu/drm/ttm/ttm_bo.c
drivers/gpu/drm/ttm/ttm_bo_util.c
include/drm/ttm/ttm_bo_api.h