]> git.baikalelectronics.ru Git - kernel.git/commit
drm/msm: Track potentially evictable objects
authorRob Clark <robdclark@chromium.org>
Mon, 5 Apr 2021 17:45:29 +0000 (10:45 -0700)
committerRob Clark <robdclark@chromium.org>
Wed, 7 Apr 2021 18:05:47 +0000 (11:05 -0700)
commita7c30003b29f6c91dfac239c679e2c33c6825a85
tree187b7eca148b40daa4d8959c930ccd31b8c89f73
parenta35426088950c700f8bc567e2b4e306071ff93bb
drm/msm: Track potentially evictable objects

Objects that are potential for swapping out are (1) willneed (ie. if
they are purgable/MADV_WONTNEED we can just free the pages without them
having to land in swap), (2) not on an active list, (3) not dma-buf
imported or exported, and (4) not vmap'd.  This repurposes the purged
list for objects that do not have backing pages (either because they
have not been pinned for the first time yet, or in a later patch because
they have been unpinned/evicted.

Signed-off-by: Rob Clark <robdclark@chromium.org>
Link: https://lore.kernel.org/r/20210405174532.1441497-7-robdclark@gmail.com
Signed-off-by: Rob Clark <robdclark@chromium.org>
drivers/gpu/drm/msm/msm_drv.c
drivers/gpu/drm/msm/msm_drv.h
drivers/gpu/drm/msm/msm_gem.c
drivers/gpu/drm/msm/msm_gem.h