aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHans Verkuil <hans.verkuil@cisco.com>2015-03-17 08:34:10 +0100
committerHans Verkuil <hans.verkuil@cisco.com>2015-03-17 08:34:10 +0100
commit5bba53ae24008f79f008c4b3a543ce2b5b8cf6f8 (patch)
treedbc345a69169635c3f8b7325e7bd357d5059d9f6
parent3d945be05ac1e806af075e9315bc1b3409adae2b (diff)
v4l2-ioctl: drop 'fh' argument from vidioc_default
That argument is rarely used and can always be obtained from file->private_data anyway, so drop it for vidioc_default. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
-rw-r--r--drivers/media/pci/cx18/cx18-ioctl.c4
-rw-r--r--drivers/media/pci/ivtv/ivtv-ioctl.c4
-rw-r--r--drivers/media/pci/meye/meye.c6
-rw-r--r--drivers/media/platform/am437x/am437x-vpfe.c2
-rw-r--r--drivers/media/platform/davinci/vpfe_capture.c2
-rw-r--r--drivers/media/radio/si4713/radio-platform-si4713.c2
-rw-r--r--drivers/media/usb/uvc/uvc_v4l2.c4
-rw-r--r--drivers/media/v4l2-core/v4l2-ioctl.c2
-rw-r--r--drivers/usb/gadget/function/uvc_v4l2.c2
-rw-r--r--include/media/v4l2-ioctl.h2
10 files changed, 15 insertions, 15 deletions
diff --git a/drivers/media/pci/cx18/cx18-ioctl.c b/drivers/media/pci/cx18/cx18-ioctl.c
index c2e0093a5f6a..8b410bfaafe9 100644
--- a/drivers/media/pci/cx18/cx18-ioctl.c
+++ b/drivers/media/pci/cx18/cx18-ioctl.c
@@ -1053,10 +1053,10 @@ static int cx18_log_status(struct file *file, void *fh)
return 0;
}
-static long cx18_default(struct file *file, void *fh, bool valid_prio,
+static long cx18_default(struct file *file, bool valid_prio,
unsigned int cmd, void *arg)
{
- struct cx18 *cx = fh2id(fh)->cx;
+ struct cx18 *cx = fh2id(file->private_data)->cx;
switch (cmd) {
case VIDIOC_INT_RESET: {
diff --git a/drivers/media/pci/ivtv/ivtv-ioctl.c b/drivers/media/pci/ivtv/ivtv-ioctl.c
index 4d8ee18c3feb..682911117425 100644
--- a/drivers/media/pci/ivtv/ivtv-ioctl.c
+++ b/drivers/media/pci/ivtv/ivtv-ioctl.c
@@ -1771,10 +1771,10 @@ static int ivtv_decoder_ioctls(struct file *filp, unsigned int cmd, void *arg)
return 0;
}
-static long ivtv_default(struct file *file, void *fh, bool valid_prio,
+static long ivtv_default(struct file *file, bool valid_prio,
unsigned int cmd, void *arg)
{
- struct ivtv *itv = fh2id(fh)->itv;
+ struct ivtv *itv = fh2id(file->private_data)->itv;
if (!valid_prio) {
switch (cmd) {
diff --git a/drivers/media/pci/meye/meye.c b/drivers/media/pci/meye/meye.c
index 9d9f90cb7740..f3a68fac33d6 100644
--- a/drivers/media/pci/meye/meye.c
+++ b/drivers/media/pci/meye/meye.c
@@ -946,7 +946,7 @@ static int meyeioc_qbuf_capt(int *nb)
return 0;
}
-static int meyeioc_sync(struct file *file, void *fh, int *i)
+static int meyeioc_sync(struct file *file, int *i)
{
int unused;
@@ -1404,7 +1404,7 @@ static int vidioc_streamoff(struct file *file, void *fh, enum v4l2_buf_type i)
return 0;
}
-static long vidioc_default(struct file *file, void *fh, bool valid_prio,
+static long vidioc_default(struct file *file, bool valid_prio,
unsigned int cmd, void *arg)
{
switch (cmd) {
@@ -1418,7 +1418,7 @@ static long vidioc_default(struct file *file, void *fh, bool valid_prio,
return meyeioc_qbuf_capt((int *) arg);
case MEYEIOC_SYNC:
- return meyeioc_sync(file, fh, (int *) arg);
+ return meyeioc_sync(file, (int *) arg);
case MEYEIOC_STILLCAPT:
return meyeioc_stillcapt();
diff --git a/drivers/media/platform/am437x/am437x-vpfe.c b/drivers/media/platform/am437x/am437x-vpfe.c
index 56a5cb0d2152..04f010f90651 100644
--- a/drivers/media/platform/am437x/am437x-vpfe.c
+++ b/drivers/media/platform/am437x/am437x-vpfe.c
@@ -2177,7 +2177,7 @@ vpfe_s_selection(struct file *file, void *fh, struct v4l2_selection *s)
return 0;
}
-static long vpfe_ioctl_default(struct file *file, void *priv,
+static long vpfe_ioctl_default(struct file *file,
bool valid_prio, unsigned int cmd, void *param)
{
struct vpfe_device *vpfe = video_drvdata(file);
diff --git a/drivers/media/platform/davinci/vpfe_capture.c b/drivers/media/platform/davinci/vpfe_capture.c
index b41bf7e822c8..a2f23aa4fe7f 100644
--- a/drivers/media/platform/davinci/vpfe_capture.c
+++ b/drivers/media/platform/davinci/vpfe_capture.c
@@ -1685,7 +1685,7 @@ unlock_out:
}
-static long vpfe_param_handler(struct file *file, void *priv,
+static long vpfe_param_handler(struct file *file,
bool valid_prio, unsigned int cmd, void *param)
{
struct vpfe_device *vpfe_dev = video_drvdata(file);
diff --git a/drivers/media/radio/si4713/radio-platform-si4713.c b/drivers/media/radio/si4713/radio-platform-si4713.c
index 6c7597383ca2..7fffa01a342d 100644
--- a/drivers/media/radio/si4713/radio-platform-si4713.c
+++ b/drivers/media/radio/si4713/radio-platform-si4713.c
@@ -119,7 +119,7 @@ static int radio_si4713_s_frequency(struct file *file, void *p,
s_frequency, vf);
}
-static long radio_si4713_default(struct file *file, void *p,
+static long radio_si4713_default(struct file *file,
bool valid_prio, unsigned int cmd, void *arg)
{
return v4l2_device_call_until_err(get_v4l2_dev(file), 0, core,
diff --git a/drivers/media/usb/uvc/uvc_v4l2.c b/drivers/media/usb/uvc/uvc_v4l2.c
index 43e953f73e02..9880d9ed20b7 100644
--- a/drivers/media/usb/uvc/uvc_v4l2.c
+++ b/drivers/media/usb/uvc/uvc_v4l2.c
@@ -1162,10 +1162,10 @@ static int uvc_ioctl_subscribe_event(struct v4l2_fh *fh,
}
}
-static long uvc_ioctl_default(struct file *file, void *fh, bool valid_prio,
+static long uvc_ioctl_default(struct file *file, bool valid_prio,
unsigned int cmd, void *arg)
{
- struct uvc_fh *handle = fh;
+ struct uvc_fh *handle = file->private_data;
struct uvc_video_chain *chain = handle->chain;
switch (cmd) {
diff --git a/drivers/media/v4l2-core/v4l2-ioctl.c b/drivers/media/v4l2-core/v4l2-ioctl.c
index 09ad8ddfaaf9..da5930e1ba16 100644
--- a/drivers/media/v4l2-core/v4l2-ioctl.c
+++ b/drivers/media/v4l2-core/v4l2-ioctl.c
@@ -2380,7 +2380,7 @@ static long __video_do_ioctl(struct file *file,
} else if (!ops->vidioc_default) {
ret = -ENOTTY;
} else {
- ret = ops->vidioc_default(file, fh,
+ ret = ops->vidioc_default(file,
vfh ? v4l2_prio_check(vfd->prio, vfh->prio) >= 0 : 0,
cmd, arg);
}
diff --git a/drivers/usb/gadget/function/uvc_v4l2.c b/drivers/usb/gadget/function/uvc_v4l2.c
index cbd9bf020fb3..746ca0394fd7 100644
--- a/drivers/usb/gadget/function/uvc_v4l2.c
+++ b/drivers/usb/gadget/function/uvc_v4l2.c
@@ -246,7 +246,7 @@ uvc_v4l2_unsubscribe_event(struct v4l2_fh *fh,
}
static long
-uvc_v4l2_ioctl_default(struct file *file, void *fh, bool valid_prio,
+uvc_v4l2_ioctl_default(struct file *file, bool valid_prio,
unsigned int cmd, void *arg)
{
struct video_device *vdev = video_devdata(file);
diff --git a/include/media/v4l2-ioctl.h b/include/media/v4l2-ioctl.h
index 8fbbd76d78e8..5ea7f8008803 100644
--- a/include/media/v4l2-ioctl.h
+++ b/include/media/v4l2-ioctl.h
@@ -278,7 +278,7 @@ struct v4l2_ioctl_ops {
const struct v4l2_event_subscription *sub);
/* For other private ioctls */
- long (*vidioc_default) (struct file *file, void *fh,
+ long (*vidioc_default) (struct file *file,
bool valid_prio, unsigned int cmd, void *arg);
};

Privacy Policy