kernel_samsung_a53x/drivers/media/usb/cx231xx
Zhipeng Lu 87554a0220 media: cx231xx: fix a memleak in cx231xx_init_isoc
[ Upstream commit 5d3c8990e2bbf929cb211563dadd70708f42e4e6 ]

The dma_q->p_left_data alloced by kzalloc should be freed in all the
following error handling paths. However, it hasn't been freed in the
allocation error paths of dev->video_mode.isoc_ctl.urb and
dev->video_mode.isoc_ctl.transfer_buffer.

On the other hand, the dma_q->p_left_data did be freed in the
error-handling paths after that of dev->video_mode.isoc_ctl.urb and
dev->video_mode.isoc_ctl.transfer_buffer, by calling
cx231xx_uninit_isoc(dev). So the same free operation should be done in
error-handling paths of those two allocation.

Fixes: 64fbf4445526 ("[media] cx231xx: Added support for Carraera, Shelby, RDx_253S and VIDEO_GRABBER")
Signed-off-by: Zhipeng Lu <alexious@zju.edu.cn>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-11-18 12:12:40 +01:00
..
cx231xx-417.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cx231xx-audio.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cx231xx-avcore.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cx231xx-cards.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cx231xx-conf-reg.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cx231xx-core.c media: cx231xx: fix a memleak in cx231xx_init_isoc 2024-11-18 12:12:40 +01:00
cx231xx-dif.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cx231xx-dvb.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cx231xx-i2c.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cx231xx-input.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cx231xx-pcb-cfg.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cx231xx-pcb-cfg.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cx231xx-reg.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cx231xx-vbi.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cx231xx-vbi.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cx231xx-video.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
cx231xx.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Kconfig Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Makefile Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00