linux/drivers/accel/ivpu
Karol Wachowski 7dd57d7a63 accel/ivpu: Disallow re-exporting imported GEM objects
Prevent re-exporting of imported GEM buffers by adding a custom
prime_handle_to_fd callback that checks if the object is imported
and returns -EOPNOTSUPP if so.

Re-exporting imported GEM buffers causes loss of buffer flags settings,
leading to incorrect device access and data corruption.

Reported-by: Yametsu <yam3tsu@gmail.com>
Fixes: 57557964b5 ("accel/ivpu: Add support for userptr buffer objects")
Reviewed-by: Andrzej Kacprowski <andrzej.kacprowski@linux.intel.com>
Signed-off-by: Karol Wachowski <karol.wachowski@linux.intel.com>
Cc: <stable@vger.kernel.org> # v6.19+
2026-04-30 13:51:37 +02:00
..
ivpu_coredump.c accel/ivpu: Add coredump support 2024-10-11 12:44:38 +02:00
ivpu_coredump.h accel/ivpu: Add coredump support 2024-10-11 12:44:38 +02:00
ivpu_debugfs.c accel/ivpu: Perform engine reset instead of device recovery on TDR 2026-03-20 08:03:11 +01:00
ivpu_debugfs.h accel/ivpu: Compile ivpu_debugfs.c conditionally 2023-09-27 13:11:51 +02:00
ivpu_drv.c accel/ivpu: Disallow re-exporting imported GEM objects 2026-04-30 13:51:37 +02:00
ivpu_drv.h Merge drm/drm-fixes into drm-misc-next-fixes 2026-03-30 10:05:36 +02:00
ivpu_fw_log.c accel/ivpu: Fix fw log printing 2024-10-11 12:43:49 +02:00
ivpu_fw_log.h accel/ivpu: Add coredump support 2024-10-11 12:44:38 +02:00
ivpu_fw.c accel/ivpu: Implement warm boot flow for NPU6 and unify boot handling 2026-01-08 11:49:37 +01:00
ivpu_fw.h accel/ivpu: Implement warm boot flow for NPU6 and unify boot handling 2026-01-08 11:49:37 +01:00
ivpu_gem_userptr.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
ivpu_gem.c accel/ivpu: Apply minor code style cleanups to align with kernel style 2026-03-11 13:31:08 +01:00
ivpu_gem.h accel/ivpu: Add fdinfo support for memory statistics 2025-11-12 07:58:44 +01:00
ivpu_hw_37xx_reg.h accel/ivpu: Split IP and buttress headers 2024-05-17 08:30:23 +02:00
ivpu_hw_40xx_reg.h accel/ivpu: Remove boot params address setting via MMIO register 2026-03-10 13:34:31 +01:00
ivpu_hw_btrs_lnl_reg.h accel/ivpu: Wait for CDYN de-assertion during power down sequence 2025-10-30 16:58:20 +01:00
ivpu_hw_btrs_mtl_reg.h accel/ivpu: Split IP and buttress headers 2024-05-17 08:30:23 +02:00
ivpu_hw_btrs.c accel/ivpu: Wait for CDYN de-assertion during power down sequence 2025-10-30 16:58:20 +01:00
ivpu_hw_btrs.h accel/ivpu: Fix DCT active percent format 2025-10-02 07:44:53 +02:00
ivpu_hw_ip.c accel/ivpu: Remove boot params address setting via MMIO register 2026-03-10 13:34:31 +01:00
ivpu_hw_ip.h accel/ivpu: Implement warm boot flow for NPU6 and unify boot handling 2026-01-08 11:49:37 +01:00
ivpu_hw_reg_io.h accel/ivpu: Add support for hardware fault injection 2025-02-03 10:39:45 +01:00
ivpu_hw.c accel/ivpu: Add disable clock relinquish workaround for NVL-A0 2026-03-24 09:29:28 +01:00
ivpu_hw.h accel/ivpu: Enable MCA ECC signalling based on MSR 2025-10-01 09:58:14 +02:00
ivpu_ipc.c treewide: Replace kmalloc with kmalloc_obj for non-scalar types 2026-02-21 01:02:28 -08:00
ivpu_ipc.h accel/ivpu: Use workqueue for IRQ handling 2025-01-09 09:35:44 +01:00
ivpu_job.c accel/ivpu: Perform engine reset instead of device recovery on TDR 2026-03-20 08:03:11 +01:00
ivpu_job.h accel/ivpu: Return correct job error status 2025-10-08 18:32:39 +02:00
ivpu_jsm_msg.c accel/ivpu: Perform engine reset instead of device recovery on TDR 2026-03-20 08:03:11 +01:00
ivpu_jsm_msg.h accel/ivpu: Perform engine reset instead of device recovery on TDR 2026-03-20 08:03:11 +01:00
ivpu_mmu_context.c accel/ivpu: Validate scatter-gather size against buffer size 2025-12-16 08:10:19 +01:00
ivpu_mmu_context.h accel/ivpu: Validate scatter-gather size against buffer size 2025-12-16 08:10:19 +01:00
ivpu_mmu.c accel/ivpu: Perform engine reset instead of device recovery on TDR 2026-03-20 08:03:11 +01:00
ivpu_mmu.h accel/ivpu: Move parts of MMU event IRQ handling to thread handler 2025-01-09 09:35:44 +01:00
ivpu_ms.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
ivpu_ms.h accel/ivpu: Add NPU profiling support 2024-05-15 07:42:23 +02:00
ivpu_pm.c accel/ivpu: Trigger recovery on TDR with OS scheduling 2026-04-02 21:29:01 +02:00
ivpu_pm.h accel/ivpu: Perform engine reset instead of device recovery on TDR 2026-03-20 08:03:11 +01:00
ivpu_sysfs.c accel/ivpu: Count only resident buffers in memory utilization 2025-11-12 07:58:44 +01:00
ivpu_sysfs.h accel/ivpu: Share NPU busy time in sysfs 2024-05-15 07:42:29 +02:00
ivpu_trace_points.c accel/ivpu: Add tracing for IPC/PM/JOB 2024-10-11 12:44:39 +02:00
ivpu_trace.h accel/ivpu: Add tracing for IPC/PM/JOB 2024-10-11 12:44:39 +02:00
Kconfig accel/ivpu: Add debug Kconfig option 2024-10-30 10:23:49 +01:00
Makefile accel/ivpu: Add support for userptr buffer objects 2025-10-30 08:52:51 +01:00
vpu_boot_api.h accel/ivpu: Update FW Boot API to version 3.29.4 2026-02-26 17:01:39 +01:00
vpu_jsm_api.h accel/ivpu: Update JSM API header to 3.33.0 2025-10-08 18:32:39 +02:00