summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab+huawei@kernel.org>2024-10-15 15:23:01 +0200
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>2024-10-18 10:43:03 +0200
commit972e63e895abbe8aa1ccbdbb4e6362abda7cd457 (patch)
tree42e2ca9dcddd8c93a1f5b30280ca6763df5ed13d /tools/perf/scripts/python
parente6a3ea83fbe15d4818d01804e904cbb0e64e543b (diff)
media: dvbdev: prevent the risk of out of memory access
The dvbdev contains a static variable used to store dvb minors. The behavior of it depends if CONFIG_DVB_DYNAMIC_MINORS is set or not. When not set, dvb_register_device() won't check for boundaries, as it will rely that a previous call to dvb_register_adapter() would already be enforcing it. On a similar way, dvb_device_open() uses the assumption that the register functions already did the needed checks. This can be fragile if some device ends using different calls. This also generate warnings on static check analysers like Coverity. So, add explicit guards to prevent potential risk of OOM issues. Fixes: 5dd3f3071070 ("V4L/DVB (9361): Dynamic DVB minor allocation") Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions