[PATCH v2 0/3] drm/xe: Userptr invalid page access fixes

Thomas Hellström thomas.hellstrom at linux.intel.com
Tue Mar 4 11:37:55 UTC 2025


Fix a number of potential invalid page-accesses by the userptr code.

Patch 1:
- Some coding style fixes.
Patch 2:
- Avoids invalid struct page accesses during userptr pinning.
Patch 3:
- Block xe device accesses on mmu_invalidation on the iommu level.

v2:
- Address review comments by Matt Auld

Cc: Matthew Auld <matthew.auld at intel.com>
Cc: Oak Zeng <oak.zeng at intel.com>

Thomas Hellström (3):
  drm/xe/hmm: Style- and include fixes
  drm/xe/hmm: Don't dereference struct page pointers without notifier
    lock
  drm/xe/userptr: Unmap userptrs in the mmu notifier

 drivers/gpu/drm/xe/xe_hmm.c      | 175 ++++++++++++++++++++++++-------
 drivers/gpu/drm/xe/xe_hmm.h      |   7 ++
 drivers/gpu/drm/xe/xe_vm.c       |   4 +
 drivers/gpu/drm/xe/xe_vm_types.h |   4 +
 4 files changed, 150 insertions(+), 40 deletions(-)

-- 
2.48.1



More information about the Intel-xe mailing list