Skip to content

Fix purging buffers in the shmem helpers

Neil Roberts dri-devel stable 1 version Applied

Status from this message: Pushed to drm-misc-fixes

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest1 of 2 patches 2 repliesApplied

1 of 2 patches is in this archive. The cover letter announces 2.

Patches in v1 Applied

#Subject and filesSizeRepliesApplied
1/2drm/shmem-helper: Check for purged buffers in fault handlerdrivers/gpu/drm/drm_gem_shmem_helper.c+14 -41 reply

Reviews trailers per patch

The patch has a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchSteven Price
SeriesR-b
1/2R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/2] Fix purging buffers in the shmem helpers

These two patches fix a problem with the madvise purging code for the shmem helpers where the mmaping for a purged buffer wouldn't get invalidated correctly. This presumably ends up as a security hole where the mapping can be accessed from user-space to read and write random pages from other buffers. This is currently affecting Panfrost. The second patch is a v2 from a patch that was sent standalone.

There is a WIP IGT test for Panfrost which demonstrates the bug here:

https://gitlab.freedesktop.org/nroberts/igt-gpu-tools/-/commits/panfrost-purgemap/

Neil Roberts (2):
drm/shmem-helper: Check for purged buffers in fault handler drm/shmem-helper: Don't remove the offset in vm_area_struct pgoff

 drivers/gpu/drm/drm_gem_shmem_helper.c | 25 ++++++++++++++++++-------
 1 file changed, 18 insertions(+), 7 deletions(-)
Signature · 6 lines
2.29.2

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel