linux/include
Arnd Bergmann 8b39b430dc media: subdev: disallow ioctl for saa6588/davinci
commit 0a7790be18 upstream.

The saa6588_ioctl() function expects to get called from other kernel
functions with a 'saa6588_command' pointer, but I found nothing stops it
from getting called from user space instead, which seems rather dangerous.

The same thing happens in the davinci vpbe driver with its VENC_GET_FLD
command.

As a quick fix, add a separate .command() callback pointer for this
driver and change the two callers over to that.  This change can easily
get backported to stable kernels if necessary, but since there are only
two drivers, we may want to eventually replace this with a set of more
specialized callbacks in the long run.

Fixes: c3fda7f835 ("V4L/DVB (10537): saa6588: convert to v4l2_subdev.")
Cc: stable@vger.kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
History 2021-07-19 10:04:53 +02:00
..
acpi Merge branches 'acpi-cppc', 'acpi-video' and 'acpi-utils' 2021-04-26 17:04:27 +02:00
asm-generic mm: define default MAX_PTRS_PER_* in include/pgtable.h 2021-07-14 17:06:38 +02:00
clocksource clocksource/drivers/timer-ti-dm: Save and restore timer TIOCP_CFG 2021-07-14 17:06:51 +02:00
crypto crypto: shash - avoid comparing pointers to exported functions under CFI 2021-07-14 17:06:26 +02:00
drm Merge drm/drm-fixes into drm-next 2021-04-13 23:15:09 +02:00
dt-bindings clk: imx8mq: remove SYS PLL 1/2 clock gates 2021-07-14 17:07:04 +02:00
keys integrity-v5.13 2021-05-01 15:32:18 -07:00
kunit kunit: fix -Wunused-function warning for __kunit_fail_current_test 2021-04-06 15:22:39 -06:00
kvm Merge branch 'kvm-arm64/kill_oprofile_dependency' into kvmarm-master/next 2021-04-22 13:41:49 +01:00
linux rq-qos: fix missed wake-ups in rq_qos_throttle try two 2021-07-19 10:04:52 +02:00
math-emu treewide: Use fallthrough pseudo-keyword 2020-08-23 17:36:59 -05:00
media media: subdev: disallow ioctl for saa6588/davinci 2021-07-19 10:04:53 +02:00
memory memory: renesas-rpc-if: Make rpcif_enable/disable_rpm() as static inline 2020-11-28 12:37:18 +01:00
misc ocxl: Update the Process Element Entry 2020-12-04 01:01:30 +11:00
net sctp: validate from_addr_param return 2021-07-19 10:04:46 +02:00
pcmcia pcmcia: Replace zero-length array with flexible-array 2020-05-18 10:28:31 +02:00
ras mm,hwpoison: introduce MF_MSG_UNSPLIT_THP 2020-10-16 11:11:17 -07:00
rdma RDMA/restrack: Add support to get resource tracking for SRQ 2021-04-22 10:30:27 -03:00
scsi scsi: fc: Correct RHBA attributes length 2021-07-14 17:07:49 +02:00
soc Networking changes for 5.13. 2021-04-29 11:57:23 -07:00
sound ASoC: Fixes for v5.13 2021-05-25 08:58:01 +02:00
target scsi: target: core: Make completion affinity configurable 2021-03-04 17:37:03 -05:00
trace NFS client updates for Linux 5.13 2021-05-07 11:23:41 -07:00
uapi net: retrieve netns cookie via getsocketopt 2021-07-19 10:04:44 +02:00
vdso time64.h: Consolidated PSEC_PER_SEC definition 2021-04-06 16:32:17 -07:00
video video: fbdev: sstfb: Updated logging to fix set but not used warnings 2020-11-30 20:04:59 +01:00
xen xen/arm: move xen_swiotlb_detect to arm/swiotlb-xen.h 2021-05-14 15:52:05 +02:00