1
0
Fork 0
alistair23-linux/drivers/gpu/drm/v3d
Navid Emamdoost 29cd13cfd7 drm/v3d: Fix memory leak in v3d_submit_cl_ioctl
In the impelementation of v3d_submit_cl_ioctl() there are two memory
leaks. One is when allocation for bin fails, and the other is when bin
initialization fails. If kcalloc fails to allocate memory for bin then
render->base should be put. Also, if v3d_job_init() fails to initialize
bin->base then allocated memory for bin should be released.

Fixes: a783a09ee7 ("drm/v3d: Refactor job management.")
Signed-off-by: Navid Emamdoost <navid.emamdoost@gmail.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: https://patchwork.freedesktop.org/patch/msgid/20191021185250.26130-1-navid.emamdoost@gmail.com
2019-10-23 20:57:05 +02:00
..
Kconfig treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
Makefile treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
v3d_bo.c drm/v3d: fix a NULL vs error pointer mixup 2019-04-01 09:33:38 -07:00
v3d_debugfs.c drm/v3d: drop use of drmP.h 2019-07-17 12:52:20 +02:00
v3d_drv.c drm/v3d: drop use of drmP.h 2019-07-17 12:52:20 +02:00
v3d_drv.h drm/v3d: drop use of drmP.h 2019-07-17 12:52:20 +02:00
v3d_fence.c drm/v3d: Add support for compute shader dispatch. 2019-04-18 09:54:10 -07:00
v3d_gem.c drm/v3d: Fix memory leak in v3d_submit_cl_ioctl 2019-10-23 20:57:05 +02:00
v3d_irq.c drm/v3d: drop use of drmP.h 2019-07-17 12:52:20 +02:00
v3d_mmu.c drm/v3d: Fix and extend MMU error handling. 2019-05-16 09:24:52 -07:00
v3d_regs.h drm/v3d: Fix and extend MMU error handling. 2019-05-16 09:24:52 -07:00
v3d_sched.c drm/scheduler: rework job destruction 2019-05-02 15:45:48 -05:00
v3d_trace.h drm/v3d: Add support for compute shader dispatch. 2019-04-18 09:54:10 -07:00
v3d_trace_points.c