android_kernel_xiaomi_sm8450/drivers/media
Dikshita Agarwal 4c9d235630 media: venus: fix use after free in vdec_close
commit a0157b5aa34eb43ec4c5510f9c260bbb03be937e upstream.

There appears to be a possible use after free with vdec_close().
The firmware will add buffer release work to the work queue through
HFI callbacks as a normal part of decoding. Randomly closing the
decoder device from userspace during normal decoding can incur
a read after free for inst.

Fix it by cancelling the work in vdec_close.

Cc: stable@vger.kernel.org
Fixes: af2c3834c8 ("[media] media: venus: adding core part and helper functions")
Signed-off-by: Dikshita Agarwal <quic_dikshita@quicinc.com>
Acked-by: Vikash Garodia <quic_vgarodia@quicinc.com>
Signed-off-by: Stanimir Varbanov <stanimir.k.varbanov@gmail.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-08-19 05:40:55 +02:00
..
cec media: cec: core: add adap_nb_transmit_canceled() callback 2024-06-16 13:32:30 +02:00
common media: v4l2-tpg: fix some memleaks in tpg_alloc 2024-03-26 18:21:55 -04:00
dvb-core media: dvbdev: Initialize sbuf 2024-07-05 09:12:50 +02:00
dvb-frontends media: dvb-frontends: tda10048: Fix integer overflow 2024-07-18 13:05:40 +02:00
firewire media: firewire: firedtv-avc: fix a buffer overflow in avc_ca_pmt() 2021-11-06 14:10:09 +01:00
i2c media: tc358743: register v4l2 async device only after successful setup 2024-03-26 18:21:55 -04:00
mc media: mc: mark the media devnode as registered from the, start 2024-06-16 13:32:33 +02:00
mmc media updates for v5.8-rc1 2020-06-03 20:59:38 -07:00
pci saa7134: Unchecked i2c_transfer function result fixed 2024-08-19 05:40:48 +02:00
platform media: venus: fix use after free in vdec_close 2024-08-19 05:40:55 +02:00
radio media: radio-shark2: Avoid led_names truncations 2024-06-16 13:32:11 +02:00
rc media: imon: Fix race getting ictx->lock 2024-08-19 05:40:48 +02:00
spi media: cxd2880-spi: Fix a null pointer dereference on error handling path 2021-11-18 14:04:04 +01:00
test-drivers media: vivid: avoid integer overflow 2023-11-28 16:54:52 +00:00
tuners media: xc4000: Fix atomicity violation in xc4000_get_frequency 2024-04-13 12:58:03 +02:00
usb media: uvcvideo: Override default flags 2024-08-19 05:40:49 +02:00
v4l2-core media: v4l2-core: hold videodev_lock until dev reg, finishes 2024-06-16 13:32:33 +02:00
Kconfig media: correct MEDIA_TEST_SUPPORT help text 2022-01-27 10:54:29 +01:00
Makefile media: media/test_drivers: rename to test-drivers 2020-04-16 10:38:31 +02:00