mirror-linux/drivers/gpu/drm/v3d
Maíra Canal 6eb6e5acaf
drm/v3d: Release indirect CSD GEM reference on CPU job free
v3d_get_cpu_indirect_csd_params() takes a reference to the indirect BO via
drm_gem_object_lookup() and stashes it in cpu_job->indirect_csd.indirect,
but nothing on the CPU job teardown path ever drops that reference.

Drop the extra reference in v3d_cpu_job_free(). The NULL check covers ioctl
errors before the lookup ran and CPU job types other than
V3D_CPU_JOB_TYPE_INDIRECT_CSD, which leave the field zero-initialised.

Cc: stable@vger.kernel.org
Fixes: 18b8413b25 ("drm/v3d: Create a CPU job extension for a indirect CSD job")
Assisted-by: Claude:claude-opus-4.7
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Link: https://patch.msgid.link/20260515-v3d-cpu-job-leaks-v1-2-7f147cbbf935@igalia.com
Signed-off-by: Maíra Canal <mcanal@igalia.com>
2026-05-18 19:59:51 -03:00
..
Kconfig
Makefile drm/v3d: Use huge tmpfs mountpoint helpers 2025-12-08 10:52:47 +01:00
v3d_bo.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
v3d_debugfs.c drm: include drm_print.h where needed 2025-10-31 10:34:52 +02:00
v3d_drv.c drm/v3d: Attach per-fd reset counters to v3d_stats 2026-03-13 18:02:32 -03:00
v3d_drv.h drm/v3d: Remove dedicated fence_lock 2026-03-13 18:02:32 -03:00
v3d_fence.c drm/v3d: Remove dedicated fence_lock 2026-03-13 18:02:32 -03:00
v3d_gem.c drm/v3d: Remove dedicated fence_lock 2026-03-13 18:02:32 -03:00
v3d_irq.c drm/v3d: Hold v3d_stats references in each job 2026-03-13 18:02:32 -03:00
v3d_mmu.c drm/v3d: Convert v3d logging to device-based DRM helpers 2026-01-19 07:12:25 -03:00
v3d_perfmon.c Merge drm/drm-next into drm-misc-next 2026-02-23 11:48:20 +01:00
v3d_performance_counters.h drm/v3d: Fix miscellaneous documentation errors 2024-12-11 10:06:14 -03:00
v3d_regs.h drm/v3d: Use V3D_SMS registers for power on/off and reset on V3D 7.x 2025-03-23 11:06:15 -03:00
v3d_sched.c drm/v3d: Fix use-after-free of CPU job query arrays on error path 2026-05-18 19:59:46 -03:00
v3d_submit.c drm/v3d: Release indirect CSD GEM reference on CPU job free 2026-05-18 19:59:51 -03:00
v3d_sysfs.c drm/v3d: Refcount v3d_stats 2026-03-13 18:02:32 -03:00
v3d_trace.h
v3d_trace_points.c