]> git.baikalelectronics.ru Git - kernel.git/commit
media: dvb: move most compat_ioctl handling into drivers
authorArnd Bergmann <arnd@arndb.de>
Mon, 27 Aug 2018 19:56:24 +0000 (15:56 -0400)
committerMauro Carvalho Chehab <mchehab+samsung@kernel.org>
Wed, 12 Sep 2018 15:00:51 +0000 (11:00 -0400)
commitd91394a138ba5c2a99a4977ea6229ea5c1f15192
tree6924f7f66818be84881c686f59fa75c7f4f59f9d
parent508ee2eb1ea366295146c3a038023bae1e57106d
media: dvb: move most compat_ioctl handling into drivers

Most DVB audio and video ioctl commands are completely compatible,
and are implemented by just two drivers: ttpci and ivtv. In both
cases, we can use the same ioctl handler for both native and
compat ioctl handling, and remove the entries from the global
lookup table.

In case of ttpci, this directly hooks into the file_operations
structure, and for ivtv, we have to set the compat_ioctl32
method in v4l2_file_operations. For all I can tell, setting it
to video_ioctl2 will still do the right thing for all commands.

Note that for the VIDEO_STILLPICTURE and VIDEO_GET_EVENT commands,
a translation handler in fs/compat_ioctl.c is still used. This
works because the command numbers are different on 32-bit
systems.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
drivers/media/pci/ivtv/ivtv-streams.c
drivers/media/pci/ttpci/av7110_av.c
fs/compat_ioctl.c