android_kernel_motorola_sm6375/drivers/media
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Mauro Carvalho Chehab 0bfc6e38ee media: v4l2-tpg: prevent the risk of a division by zero
commit e6a3ea83fbe15d4818d01804e904cbb0e64e543b upstream.

As reported by Coverity, the logic at tpg_precalculate_line()
blindly rescales the buffer even when scaled_witdh is equal to
zero. If this ever happens, this will cause a division by zero.

Instead, add a WARN_ON_ONCE() to trigger such cases and return
without doing any precalculation.

Fixes: 63881df94d ("[media] vivid: add the Test Pattern Generator")
Cc: [email protected]
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
2024-11-17 14:58:51 +01:00
..
cec media: cec: cec-api: add locking in cec_release() 2024-06-16 13:28:44 +02:00
common media: v4l2-tpg: prevent the risk of a division by zero 2024-11-17 14:58:51 +01:00
dvb-core media: dvb_frontend: don't play tricks with underflow values 2024-11-17 14:58:50 +01:00
dvb-frontends media: cx24116: prevent overflows on SNR calculus 2024-11-17 14:58:50 +01:00
firewire
i2c media: adv7604: prevent underflow condition when reporting colorspace 2024-11-17 14:58:50 +01:00
mc media: mc: mark the media devnode as registered from the, start 2024-06-16 13:28:50 +02:00
mmc
pci media: solo6x10: replace max(a, min(b, c)) by clamp(b, a, c) 2024-09-04 13:14:58 +02:00
platform media: s5p-jpeg: prevent buffer overflows 2024-11-17 14:58:50 +01:00
radio media: radio-isa: use dev_name to fill in bus_info 2024-09-04 13:14:53 +02:00
rc media: imon: Fix race getting ictx->lock 2024-08-19 05:33:31 +02:00
spi
tuners media: xc4000: Fix atomicity violation in xc4000_get_frequency 2024-04-13 12:51:22 +02:00
usb media: uvcvideo: Enforce alignment of frame and interval 2024-09-12 11:03:50 +02:00
v4l2-core media: v4l2-core: hold videodev_lock until dev reg, finishes 2024-06-16 13:28:50 +02:00
Kconfig
Makefile