-
- Downloads
drm/shmem-helper: Add common memory shrinker
Introduce common drm-shmem shrinker for DRM drivers. To start using drm-shmem shrinker drivers should do the following: 1. Implement evict() callback of GEM object where driver should check whether object is purgeable or evictable using drm-shmem helpers and perform the shrinking action 2. Initialize drm-shmem internals using drmm_gem_shmem_init(drm_device), which will register drm-shmem shrinker 3. Implement madvise IOCTL that will use drm_gem_shmem_madvise() Reviewed-by:Boris Brezillon <boris.brezillon@collabora.com> Signed-off-by:
Daniel Almeida <daniel.almeida@collabora.com> Signed-off-by:
Dmitry Osipenko <dmitry.osipenko@collabora.com>
Showing
- drivers/gpu/drm/drm_gem_shmem_helper.c 352 additions, 16 deletionsdrivers/gpu/drm/drm_gem_shmem_helper.c
- drivers/gpu/drm/panfrost/panfrost_gem.c 1 addition, 2 deletionsdrivers/gpu/drm/panfrost/panfrost_gem.c
- drivers/gpu/drm/panfrost/panfrost_gem_shrinker.c 10 additions, 3 deletionsdrivers/gpu/drm/panfrost/panfrost_gem_shrinker.c
- include/drm/drm_device.h 8 additions, 2 deletionsinclude/drm/drm_device.h
- include/drm/drm_gem_shmem_helper.h 65 additions, 3 deletionsinclude/drm/drm_gem_shmem_helper.h
Loading
Please register or sign in to comment