]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
drm/ttm, drm_xe, Implement ttm_lru_walk_for_evict() using the guarded LRU iteration
authorThomas Hellström <thomas.hellstrom@linux.intel.com>
Mon, 23 Jun 2025 15:53:13 +0000 (17:53 +0200)
committerThomas Hellström <thomas.hellstrom@linux.intel.com>
Thu, 26 Jun 2025 15:20:00 +0000 (17:20 +0200)
commitbb8aa27eff6f3376242da37c2d02b9dcc66934b1
treeb4f208dc05e9ba978be73fac01f39d9bcebe922c
parente1e85eb0a977f1eb1d17d4627aceaa8eeac37159
drm/ttm, drm_xe, Implement ttm_lru_walk_for_evict() using the guarded LRU iteration

To avoid duplicating the tricky bo locking implementation,
Implement ttm_lru_walk_for_evict() using the guarded bo LRU iteration.

To facilitate this, support ticketlocking from the guarded bo LRU
iteration.

v2:
- Clean up some static function interfaces (Christian König)
- Fix Handling -EALREADY from ticketlocking in the loop by
  skipping to the next item. (Intel CI)

Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Link: https://lore.kernel.org/r/20250623155313.4901-4-thomas.hellstrom@linux.intel.com
drivers/gpu/drm/ttm/ttm_bo_util.c
drivers/gpu/drm/xe/xe_shrinker.c
include/drm/ttm/ttm_bo.h