diff options
author | Hans Verkuil <hans.verkuil@cisco.com> | 2013-06-03 04:36:44 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2013-06-17 08:35:27 -0400 |
commit | 804be2d4933a44ce76bce3d12b09c5db980523a4 (patch) | |
tree | 76baf3c58a29268dd9ed2efba4501c7ae204c4a4 /drivers/media/usb/tm6000 | |
parent | 28221f88efcf70814491a9695625d8257282d994 (diff) |
[media] tm6000: remove deprecated current_norm
Replace current_norm by g_std. Also initialize the standard to the more
common NTSC-M format (which is also what current_norm used).
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/usb/tm6000')
-rw-r--r-- | drivers/media/usb/tm6000/tm6000-cards.c | 2 | ||||
-rw-r--r-- | drivers/media/usb/tm6000/tm6000-video.c | 13 |
2 files changed, 12 insertions, 3 deletions
diff --git a/drivers/media/usb/tm6000/tm6000-cards.c b/drivers/media/usb/tm6000/tm6000-cards.c index 307d8c5fb7cd..1ccaaddaa307 100644 --- a/drivers/media/usb/tm6000/tm6000-cards.c +++ b/drivers/media/usb/tm6000/tm6000-cards.c | |||
@@ -1114,7 +1114,7 @@ static int tm6000_init_dev(struct tm6000_core *dev) | |||
1114 | /* Default values for STD and resolutions */ | 1114 | /* Default values for STD and resolutions */ |
1115 | dev->width = 720; | 1115 | dev->width = 720; |
1116 | dev->height = 480; | 1116 | dev->height = 480; |
1117 | dev->norm = V4L2_STD_PAL_M; | 1117 | dev->norm = V4L2_STD_NTSC_M; |
1118 | 1118 | ||
1119 | /* Configure tuner */ | 1119 | /* Configure tuner */ |
1120 | tm6000_config_tuner(dev); | 1120 | tm6000_config_tuner(dev); |
diff --git a/drivers/media/usb/tm6000/tm6000-video.c b/drivers/media/usb/tm6000/tm6000-video.c index a78de1d1bc9e..cc1aa14996ff 100644 --- a/drivers/media/usb/tm6000/tm6000-video.c +++ b/drivers/media/usb/tm6000/tm6000-video.c | |||
@@ -1076,6 +1076,15 @@ static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id norm) | |||
1076 | return 0; | 1076 | return 0; |
1077 | } | 1077 | } |
1078 | 1078 | ||
1079 | static int vidioc_g_std(struct file *file, void *priv, v4l2_std_id *norm) | ||
1080 | { | ||
1081 | struct tm6000_fh *fh = priv; | ||
1082 | struct tm6000_core *dev = fh->dev; | ||
1083 | |||
1084 | *norm = dev->norm; | ||
1085 | return 0; | ||
1086 | } | ||
1087 | |||
1079 | static const char *iname[] = { | 1088 | static const char *iname[] = { |
1080 | [TM6000_INPUT_TV] = "Television", | 1089 | [TM6000_INPUT_TV] = "Television", |
1081 | [TM6000_INPUT_COMPOSITE1] = "Composite 1", | 1090 | [TM6000_INPUT_COMPOSITE1] = "Composite 1", |
@@ -1134,7 +1143,7 @@ static int vidioc_s_input(struct file *file, void *priv, unsigned int i) | |||
1134 | 1143 | ||
1135 | dev->input = i; | 1144 | dev->input = i; |
1136 | 1145 | ||
1137 | rc = vidioc_s_std(file, priv, dev->vfd->current_norm); | 1146 | rc = vidioc_s_std(file, priv, dev->norm); |
1138 | 1147 | ||
1139 | return rc; | 1148 | return rc; |
1140 | } | 1149 | } |
@@ -1547,6 +1556,7 @@ static const struct v4l2_ioctl_ops video_ioctl_ops = { | |||
1547 | .vidioc_try_fmt_vid_cap = vidioc_try_fmt_vid_cap, | 1556 | .vidioc_try_fmt_vid_cap = vidioc_try_fmt_vid_cap, |
1548 | .vidioc_s_fmt_vid_cap = vidioc_s_fmt_vid_cap, | 1557 | .vidioc_s_fmt_vid_cap = vidioc_s_fmt_vid_cap, |
1549 | .vidioc_s_std = vidioc_s_std, | 1558 | .vidioc_s_std = vidioc_s_std, |
1559 | .vidioc_g_std = vidioc_g_std, | ||
1550 | .vidioc_enum_input = vidioc_enum_input, | 1560 | .vidioc_enum_input = vidioc_enum_input, |
1551 | .vidioc_g_input = vidioc_g_input, | 1561 | .vidioc_g_input = vidioc_g_input, |
1552 | .vidioc_s_input = vidioc_s_input, | 1562 | .vidioc_s_input = vidioc_s_input, |
@@ -1570,7 +1580,6 @@ static struct video_device tm6000_template = { | |||
1570 | .ioctl_ops = &video_ioctl_ops, | 1580 | .ioctl_ops = &video_ioctl_ops, |
1571 | .release = video_device_release, | 1581 | .release = video_device_release, |
1572 | .tvnorms = TM6000_STD, | 1582 | .tvnorms = TM6000_STD, |
1573 | .current_norm = V4L2_STD_NTSC_M, | ||
1574 | }; | 1583 | }; |
1575 | 1584 | ||
1576 | static const struct v4l2_file_operations radio_fops = { | 1585 | static const struct v4l2_file_operations radio_fops = { |