Skip to content

Commit 7d1718f

Browse files
author
Desnes Nunes
committed
media: pvrusb2: Remove g/s_ctrl callbacks
JIRA: https://issues.redhat.com/browse/RHEL-78934 commit 731cfc6 Author: Ricardo Ribalda <ribalda@chromium.org> Date: Sun, 23 Feb 2025 18:58:06 +0000 The ioctl helpers can emulate g/s_ctrl with g/s_ext_ctrl. Simplify the code. Signed-off-by: Ricardo Ribalda <ribalda@chromium.org> Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org> Signed-off-by: Desnes Nunes <desnesn@redhat.com>
1 parent fddc714 commit 7d1718f

File tree

1 file changed

+0
-27
lines changed

1 file changed

+0
-27
lines changed

drivers/media/usb/pvrusb2/pvrusb2-v4l2.c

Lines changed: 0 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -574,31 +574,6 @@ static int pvr2_querymenu(struct file *file, void *priv, struct v4l2_querymenu *
574574
return ret;
575575
}
576576

577-
static int pvr2_g_ctrl(struct file *file, void *priv, struct v4l2_control *vc)
578-
{
579-
struct pvr2_v4l2_fh *fh = file->private_data;
580-
struct pvr2_hdw *hdw = fh->channel.mc_head->hdw;
581-
int val = 0;
582-
int ret;
583-
584-
ret = pvr2_ctrl_get_value(pvr2_hdw_get_ctrl_v4l(hdw, vc->id),
585-
&val);
586-
vc->value = val;
587-
return ret;
588-
}
589-
590-
static int pvr2_s_ctrl(struct file *file, void *priv, struct v4l2_control *vc)
591-
{
592-
struct pvr2_v4l2_fh *fh = file->private_data;
593-
struct pvr2_hdw *hdw = fh->channel.mc_head->hdw;
594-
int ret;
595-
596-
ret = pvr2_ctrl_set_value(pvr2_hdw_get_ctrl_v4l(hdw, vc->id),
597-
vc->value);
598-
pvr2_hdw_commit_ctl(hdw);
599-
return ret;
600-
}
601-
602577
static int pvr2_g_ext_ctrls(struct file *file, void *priv,
603578
struct v4l2_ext_controls *ctls)
604579
{
@@ -817,8 +792,6 @@ static const struct v4l2_ioctl_ops pvr2_ioctl_ops = {
817792
.vidioc_streamoff = pvr2_streamoff,
818793
.vidioc_query_ext_ctrl = pvr2_query_ext_ctrl,
819794
.vidioc_querymenu = pvr2_querymenu,
820-
.vidioc_g_ctrl = pvr2_g_ctrl,
821-
.vidioc_s_ctrl = pvr2_s_ctrl,
822795
.vidioc_g_ext_ctrls = pvr2_g_ext_ctrls,
823796
.vidioc_s_ext_ctrls = pvr2_s_ext_ctrls,
824797
.vidioc_try_ext_ctrls = pvr2_try_ext_ctrls,

0 commit comments

Comments
 (0)