X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=drivers%2Fmedia%2Fvideo%2Fvideodev.c;h=fbc5cb1e286df167471361e7d57c54c32f099bc9;hb=9bf4aaab3e101692164d49b7ca357651eb691cb6;hp=afaf612fcd4b429aeb87db9e7787882d5f1e4731;hpb=db216c3d5e4c040e557a50f8f5d35d5c415e8c1c;p=linux-2.6.git diff --git a/drivers/media/video/videodev.c b/drivers/media/video/videodev.c index afaf612fc..fbc5cb1e2 100644 --- a/drivers/media/video/videodev.c +++ b/drivers/media/video/videodev.c @@ -183,7 +183,7 @@ video_usercopy(struct inode *inode, struct file *file, /* Copy arguments into temp kernel buffer */ switch (_IOC_DIR(cmd)) { case _IOC_NONE: - parg = (void *)arg; + parg = NULL; break; case _IOC_READ: case _IOC_WRITE: @@ -200,7 +200,7 @@ video_usercopy(struct inode *inode, struct file *file, err = -EFAULT; if (_IOC_DIR(cmd) & _IOC_WRITE) - if (copy_from_user(parg, (void *)arg, _IOC_SIZE(cmd))) + if (copy_from_user(parg, (void __user *)arg, _IOC_SIZE(cmd))) goto out; break; } @@ -217,7 +217,7 @@ video_usercopy(struct inode *inode, struct file *file, { case _IOC_READ: case (_IOC_WRITE | _IOC_READ): - if (copy_to_user((void *)arg, parg, _IOC_SIZE(cmd))) + if (copy_to_user((void __user *)arg, parg, _IOC_SIZE(cmd))) err = -EFAULT; break; } @@ -231,7 +231,7 @@ out: /* * open/release helper functions -- handle exclusive opens */ -extern int video_exclusive_open(struct inode *inode, struct file *file) +int video_exclusive_open(struct inode *inode, struct file *file) { struct video_device *vfl = video_devdata(file); int retval = 0; @@ -246,7 +246,7 @@ extern int video_exclusive_open(struct inode *inode, struct file *file) return retval; } -extern int video_exclusive_release(struct inode *inode, struct file *file) +int video_exclusive_release(struct inode *inode, struct file *file) { struct video_device *vfl = video_devdata(file);