aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/w9968cf.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media/video/w9968cf.c')
-rw-r--r--drivers/media/video/w9968cf.c36
1 files changed, 16 insertions, 20 deletions
diff --git a/drivers/media/video/w9968cf.c b/drivers/media/video/w9968cf.c
index 4dfb43bd1846..a3997b7d4366 100644
--- a/drivers/media/video/w9968cf.c
+++ b/drivers/media/video/w9968cf.c
@@ -399,13 +399,13 @@ MODULE_PARM_DESC(specific_debug,
399 ****************************************************************************/ 399 ****************************************************************************/
400 400
401/* Video4linux interface */ 401/* Video4linux interface */
402static const struct file_operations w9968cf_fops; 402static const struct v4l2_file_operations w9968cf_fops;
403static int w9968cf_open(struct inode*, struct file*); 403static int w9968cf_open(struct file *);
404static int w9968cf_release(struct inode*, struct file*); 404static int w9968cf_release(struct file *);
405static int w9968cf_mmap(struct file*, struct vm_area_struct*); 405static int w9968cf_mmap(struct file *, struct vm_area_struct *);
406static int w9968cf_ioctl(struct inode*, struct file*, unsigned, unsigned long); 406static long w9968cf_ioctl(struct file *, unsigned, unsigned long);
407static ssize_t w9968cf_read(struct file*, char __user *, size_t, loff_t*); 407static ssize_t w9968cf_read(struct file *, char __user *, size_t, loff_t *);
408static int w9968cf_v4l_ioctl(struct inode*, struct file*, unsigned int, 408static long w9968cf_v4l_ioctl(struct file *, unsigned int,
409 void __user *); 409 void __user *);
410 410
411/* USB-specific */ 411/* USB-specific */
@@ -2662,7 +2662,7 @@ static void w9968cf_release_resources(struct w9968cf_device* cam)
2662 * Video4Linux interface * 2662 * Video4Linux interface *
2663 ****************************************************************************/ 2663 ****************************************************************************/
2664 2664
2665static int w9968cf_open(struct inode* inode, struct file* filp) 2665static int w9968cf_open(struct file *filp)
2666{ 2666{
2667 struct w9968cf_device* cam; 2667 struct w9968cf_device* cam;
2668 int err; 2668 int err;
@@ -2748,7 +2748,7 @@ deallocate_memory:
2748} 2748}
2749 2749
2750 2750
2751static int w9968cf_release(struct inode* inode, struct file* filp) 2751static int w9968cf_release(struct file *filp)
2752{ 2752{
2753 struct w9968cf_device* cam; 2753 struct w9968cf_device* cam;
2754 2754
@@ -2885,12 +2885,12 @@ static int w9968cf_mmap(struct file* filp, struct vm_area_struct *vma)
2885} 2885}
2886 2886
2887 2887
2888static int 2888static long
2889w9968cf_ioctl(struct inode* inode, struct file* filp, 2889w9968cf_ioctl(struct file *filp,
2890 unsigned int cmd, unsigned long arg) 2890 unsigned int cmd, unsigned long arg)
2891{ 2891{
2892 struct w9968cf_device* cam; 2892 struct w9968cf_device* cam;
2893 int err; 2893 long err;
2894 2894
2895 cam = (struct w9968cf_device*)video_get_drvdata(video_devdata(filp)); 2895 cam = (struct w9968cf_device*)video_get_drvdata(video_devdata(filp));
2896 2896
@@ -2909,15 +2909,15 @@ w9968cf_ioctl(struct inode* inode, struct file* filp,
2909 return -EIO; 2909 return -EIO;
2910 } 2910 }
2911 2911
2912 err = w9968cf_v4l_ioctl(inode, filp, cmd, (void __user *)arg); 2912 err = w9968cf_v4l_ioctl(filp, cmd, (void __user *)arg);
2913 2913
2914 mutex_unlock(&cam->fileop_mutex); 2914 mutex_unlock(&cam->fileop_mutex);
2915 return err; 2915 return err;
2916} 2916}
2917 2917
2918 2918
2919static int w9968cf_v4l_ioctl(struct inode* inode, struct file* filp, 2919static long w9968cf_v4l_ioctl(struct file *filp,
2920 unsigned int cmd, void __user * arg) 2920 unsigned int cmd, void __user *arg)
2921{ 2921{
2922 struct w9968cf_device* cam; 2922 struct w9968cf_device* cam;
2923 const char* v4l1_ioctls[] = { 2923 const char* v4l1_ioctls[] = {
@@ -3456,17 +3456,13 @@ ioctl_fail:
3456} 3456}
3457 3457
3458 3458
3459static const struct file_operations w9968cf_fops = { 3459static const struct v4l2_file_operations w9968cf_fops = {
3460 .owner = THIS_MODULE, 3460 .owner = THIS_MODULE,
3461 .open = w9968cf_open, 3461 .open = w9968cf_open,
3462 .release = w9968cf_release, 3462 .release = w9968cf_release,
3463 .read = w9968cf_read, 3463 .read = w9968cf_read,
3464 .ioctl = w9968cf_ioctl, 3464 .ioctl = w9968cf_ioctl,
3465#ifdef CONFIG_COMPAT
3466 .compat_ioctl = v4l_compat_ioctl32,
3467#endif
3468 .mmap = w9968cf_mmap, 3465 .mmap = w9968cf_mmap,
3469 .llseek = no_llseek,
3470}; 3466};
3471 3467
3472 3468