Shmem-allocated memory uses the system's default caching flags, usually involving cached mappings. By default, SHMEM GEM helpers map pages using writecombine. Only a few drivers require this setting. Others revert it to default mappings flags. Some could benefit from caching, but don't care. Unify the behaviour by switching the SHMEM GEM code to use cached mappings (i.e., PAGE_KERNEL actually); just like regular shmem memory does. The 3 drivers that require write combining explicitly select it during GEM object creation. The exception is dma-buf imported pages, which are always mapped using writecombine mode. v2: * recreate patches on top of latest SHMEM helpers * update lima, panfrost, v3d (Daniel, Rob) * udl has been updated before separately. Thomas Zimmermann (2): drm/shmem-helper: Use cached mappings by default drm/shmem-helper: Removed drm_gem_shmem_create_object_cached() drivers/gpu/drm/drm_gem_shmem_helper.c | 37 ++++--------------------- drivers/gpu/drm/lima/lima_gem.c | 2 +- drivers/gpu/drm/mgag200/mgag200_drv.c | 1 - drivers/gpu/drm/panfrost/panfrost_gem.c | 2 +- drivers/gpu/drm/udl/udl_drv.c | 2 -- drivers/gpu/drm/v3d/v3d_bo.c | 2 +- drivers/gpu/drm/virtio/virtgpu_object.c | 1 - drivers/gpu/drm/vkms/vkms_drv.c | 1 - include/drm/drm_gem_shmem_helper.h | 7 ++--- 9 files changed, 11 insertions(+), 44 deletions(-) -- 2.29.0 _______________________________________________ Virtualization mailing list Virtualization@xxxxxxxxxxxxxxxxxxxxxxxxxx https://lists.linuxfoundation.org/mailman/listinfo/virtualization