diff options
author | Hans Verkuil <hverkuil@xs4all.nl> | 2008-12-30 05:04:34 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-01-02 14:11:34 -0500 |
commit | 069b747931f13eda289c1d59a09ecc8162281a76 (patch) | |
tree | 144b8ebf131eba4f3468d8d3f52bd192bc2e4f76 /drivers/media/video/pwc | |
parent | 4ab9203b1b7e45f1beae7eb0c67d663a26257a69 (diff) |
V4L/DVB (10138): v4l2-ioctl: change to long return type to match unlocked_ioctl.
Since internal to v4l2 the ioctl prototype is the same regardless of it
being called through .ioctl or .unlocked_ioctl, we need to convert it all
to the long return type of unlocked_ioctl.
Thanks to Jean-Francois Moine for posting an initial patch for this and
thus bringing it to our attention.
Cc: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/pwc')
-rw-r--r-- | drivers/media/video/pwc/pwc-ctrl.c | 4 | ||||
-rw-r--r-- | drivers/media/video/pwc/pwc-if.c | 6 | ||||
-rw-r--r-- | drivers/media/video/pwc/pwc-v4l.c | 2 | ||||
-rw-r--r-- | drivers/media/video/pwc/pwc.h | 4 |
4 files changed, 8 insertions, 8 deletions
diff --git a/drivers/media/video/pwc/pwc-ctrl.c b/drivers/media/video/pwc/pwc-ctrl.c index c66530210192..f9fbe02e0f69 100644 --- a/drivers/media/video/pwc/pwc-ctrl.c +++ b/drivers/media/video/pwc/pwc-ctrl.c | |||
@@ -1266,9 +1266,9 @@ int pwc_get_cmos_sensor(struct pwc_device *pdev, int *sensor) | |||
1266 | /* copy local variable to arg */ | 1266 | /* copy local variable to arg */ |
1267 | #define ARG_OUT(ARG_name) /* nothing */ | 1267 | #define ARG_OUT(ARG_name) /* nothing */ |
1268 | 1268 | ||
1269 | int pwc_ioctl(struct pwc_device *pdev, unsigned int cmd, void *arg) | 1269 | long pwc_ioctl(struct pwc_device *pdev, unsigned int cmd, void *arg) |
1270 | { | 1270 | { |
1271 | int ret = 0; | 1271 | long ret = 0; |
1272 | 1272 | ||
1273 | switch(cmd) { | 1273 | switch(cmd) { |
1274 | case VIDIOCPWCRUSER: | 1274 | case VIDIOCPWCRUSER: |
diff --git a/drivers/media/video/pwc/pwc-if.c b/drivers/media/video/pwc/pwc-if.c index 315337bfd673..39fbc970f43d 100644 --- a/drivers/media/video/pwc/pwc-if.c +++ b/drivers/media/video/pwc/pwc-if.c | |||
@@ -147,7 +147,7 @@ static int pwc_video_close(struct file *file); | |||
147 | static ssize_t pwc_video_read(struct file *file, char __user *buf, | 147 | static ssize_t pwc_video_read(struct file *file, char __user *buf, |
148 | size_t count, loff_t *ppos); | 148 | size_t count, loff_t *ppos); |
149 | static unsigned int pwc_video_poll(struct file *file, poll_table *wait); | 149 | static unsigned int pwc_video_poll(struct file *file, poll_table *wait); |
150 | static int pwc_video_ioctl(struct file *file, | 150 | static long pwc_video_ioctl(struct file *file, |
151 | unsigned int ioctlnr, unsigned long arg); | 151 | unsigned int ioctlnr, unsigned long arg); |
152 | static int pwc_video_mmap(struct file *file, struct vm_area_struct *vma); | 152 | static int pwc_video_mmap(struct file *file, struct vm_area_struct *vma); |
153 | 153 | ||
@@ -1395,12 +1395,12 @@ static unsigned int pwc_video_poll(struct file *file, poll_table *wait) | |||
1395 | return 0; | 1395 | return 0; |
1396 | } | 1396 | } |
1397 | 1397 | ||
1398 | static int pwc_video_ioctl(struct file *file, | 1398 | static long pwc_video_ioctl(struct file *file, |
1399 | unsigned int cmd, unsigned long arg) | 1399 | unsigned int cmd, unsigned long arg) |
1400 | { | 1400 | { |
1401 | struct video_device *vdev = file->private_data; | 1401 | struct video_device *vdev = file->private_data; |
1402 | struct pwc_device *pdev; | 1402 | struct pwc_device *pdev; |
1403 | int r = -ENODEV; | 1403 | long r = -ENODEV; |
1404 | 1404 | ||
1405 | if (!vdev) | 1405 | if (!vdev) |
1406 | goto out; | 1406 | goto out; |
diff --git a/drivers/media/video/pwc/pwc-v4l.c b/drivers/media/video/pwc/pwc-v4l.c index d7c147328e35..bc0a464295c5 100644 --- a/drivers/media/video/pwc/pwc-v4l.c +++ b/drivers/media/video/pwc/pwc-v4l.c | |||
@@ -337,7 +337,7 @@ static int pwc_vidioc_set_fmt(struct pwc_device *pdev, struct v4l2_format *f) | |||
337 | 337 | ||
338 | } | 338 | } |
339 | 339 | ||
340 | int pwc_video_do_ioctl(struct file *file, unsigned int cmd, void *arg) | 340 | long pwc_video_do_ioctl(struct file *file, unsigned int cmd, void *arg) |
341 | { | 341 | { |
342 | struct video_device *vdev = video_devdata(file); | 342 | struct video_device *vdev = video_devdata(file); |
343 | struct pwc_device *pdev; | 343 | struct pwc_device *pdev; |
diff --git a/drivers/media/video/pwc/pwc.h b/drivers/media/video/pwc/pwc.h index c046a2535668..01411fb2337a 100644 --- a/drivers/media/video/pwc/pwc.h +++ b/drivers/media/video/pwc/pwc.h | |||
@@ -337,10 +337,10 @@ extern int pwc_get_dynamic_noise(struct pwc_device *pdev, int *noise); | |||
337 | extern int pwc_camera_power(struct pwc_device *pdev, int power); | 337 | extern int pwc_camera_power(struct pwc_device *pdev, int power); |
338 | 338 | ||
339 | /* Private ioctl()s; see pwc-ioctl.h */ | 339 | /* Private ioctl()s; see pwc-ioctl.h */ |
340 | extern int pwc_ioctl(struct pwc_device *pdev, unsigned int cmd, void *arg); | 340 | extern long pwc_ioctl(struct pwc_device *pdev, unsigned int cmd, void *arg); |
341 | 341 | ||
342 | /** Functions in pwc-v4l.c */ | 342 | /** Functions in pwc-v4l.c */ |
343 | extern int pwc_video_do_ioctl(struct file *file, unsigned int cmd, void *arg); | 343 | extern long pwc_video_do_ioctl(struct file *file, unsigned int cmd, void *arg); |
344 | 344 | ||
345 | /** pwc-uncompress.c */ | 345 | /** pwc-uncompress.c */ |
346 | /* Expand frame to image, possibly including decompression. Uses read_frame and fill_image */ | 346 | /* Expand frame to image, possibly including decompression. Uses read_frame and fill_image */ |