aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/saa7134/saa7134-empress.c
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil@xs4all.nl>2008-07-21 01:57:38 -0400
committerMauro Carvalho Chehab <mchehab@infradead.org>2008-07-26 11:54:58 -0400
commita399810ca69d9d4bd30ab8c1678c7439e567f90b (patch)
tree32939ef77bc75c3a224d37cf4e885d7f808741bf /drivers/media/video/saa7134/saa7134-empress.c
parentb654fcdc0ea3b6e5724c9873ae062bdfe7f28efe (diff)
V4L/DVB (8482): videodev: move all ioctl callbacks to a new v4l2_ioctl_ops struct
All ioctl callbacks are now stored in a new v4l2_ioctl_ops struct. Drivers fill in a const struct v4l2_ioctl_ops and video_device just contains a const pointer to it. This ensures a clean separation between the const ops struct and the non-const video_device struct. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/saa7134/saa7134-empress.c')
-rw-r--r--drivers/media/video/saa7134/saa7134-empress.c22
1 files changed, 12 insertions, 10 deletions
diff --git a/drivers/media/video/saa7134/saa7134-empress.c b/drivers/media/video/saa7134/saa7134-empress.c
index 3854cc29752d..8b3f95167781 100644
--- a/drivers/media/video/saa7134/saa7134-empress.c
+++ b/drivers/media/video/saa7134/saa7134-empress.c
@@ -400,16 +400,7 @@ static const struct file_operations ts_fops =
400 .llseek = no_llseek, 400 .llseek = no_llseek,
401}; 401};
402 402
403/* ----------------------------------------------------------- */ 403static const struct v4l2_ioctl_ops ts_ioctl_ops = {
404
405static struct video_device saa7134_empress_template =
406{
407 .name = "saa7134-empress",
408 .type = 0 /* FIXME */,
409 .type2 = 0 /* FIXME */,
410 .fops = &ts_fops,
411 .minor = -1,
412
413 .vidioc_querycap = empress_querycap, 404 .vidioc_querycap = empress_querycap,
414 .vidioc_enum_fmt_vid_cap = empress_enum_fmt_vid_cap, 405 .vidioc_enum_fmt_vid_cap = empress_enum_fmt_vid_cap,
415 .vidioc_s_fmt_vid_cap = empress_s_fmt_vid_cap, 406 .vidioc_s_fmt_vid_cap = empress_s_fmt_vid_cap,
@@ -430,6 +421,17 @@ static struct video_device saa7134_empress_template =
430 .vidioc_querymenu = empress_querymenu, 421 .vidioc_querymenu = empress_querymenu,
431 .vidioc_g_ctrl = saa7134_g_ctrl, 422 .vidioc_g_ctrl = saa7134_g_ctrl,
432 .vidioc_s_ctrl = saa7134_s_ctrl, 423 .vidioc_s_ctrl = saa7134_s_ctrl,
424};
425
426/* ----------------------------------------------------------- */
427
428static struct video_device saa7134_empress_template = {
429 .name = "saa7134-empress",
430 .type = 0 /* FIXME */,
431 .type2 = 0 /* FIXME */,
432 .fops = &ts_fops,
433 .minor = -1,
434 .ioctl_ops = &ts_ioctl_ops,
433 435
434 .tvnorms = SAA7134_NORMS, 436 .tvnorms = SAA7134_NORMS,
435 .current_norm = V4L2_STD_PAL, 437 .current_norm = V4L2_STD_PAL,