Commit 009ce6ad authored by Sergey Vlasov's avatar Sergey Vlasov Committed by Vojtech Pavlik

hid: Add missing 'return 0's in hiddev ioctl handler.

parent d605e922
...@@ -442,10 +442,14 @@ static int hiddev_ioctl(struct inode *inode, struct file *file, unsigned int cmd ...@@ -442,10 +442,14 @@ static int hiddev_ioctl(struct inode *inode, struct file *file, unsigned int cmd
if (copy_to_user((void *) arg, &dinfo, sizeof(dinfo))) if (copy_to_user((void *) arg, &dinfo, sizeof(dinfo)))
return -EFAULT; return -EFAULT;
return 0;
case HIDIOCGFLAG: case HIDIOCGFLAG:
if (put_user(list->flags, (int *) arg)) if (put_user(list->flags, (int *) arg))
return -EFAULT; return -EFAULT;
return 0;
case HIDIOCSFLAG: case HIDIOCSFLAG:
{ {
int newflags; int newflags;
...@@ -533,6 +537,8 @@ static int hiddev_ioctl(struct inode *inode, struct file *file, unsigned int cmd ...@@ -533,6 +537,8 @@ static int hiddev_ioctl(struct inode *inode, struct file *file, unsigned int cmd
if (copy_to_user((void *) arg, &rinfo, sizeof(rinfo))) if (copy_to_user((void *) arg, &rinfo, sizeof(rinfo)))
return -EFAULT; return -EFAULT;
return 0;
case HIDIOCGFIELDINFO: case HIDIOCGFIELDINFO:
if (copy_from_user(&finfo, (void *) arg, sizeof(finfo))) if (copy_from_user(&finfo, (void *) arg, sizeof(finfo)))
return -EFAULT; return -EFAULT;
...@@ -564,6 +570,8 @@ static int hiddev_ioctl(struct inode *inode, struct file *file, unsigned int cmd ...@@ -564,6 +570,8 @@ static int hiddev_ioctl(struct inode *inode, struct file *file, unsigned int cmd
if (copy_to_user((void *) arg, &finfo, sizeof(finfo))) if (copy_to_user((void *) arg, &finfo, sizeof(finfo)))
return -EFAULT; return -EFAULT;
return 0;
case HIDIOCGUCODE: case HIDIOCGUCODE:
if (copy_from_user(&uref, (void *) arg, sizeof(uref))) if (copy_from_user(&uref, (void *) arg, sizeof(uref)))
return -EFAULT; return -EFAULT;
...@@ -585,6 +593,8 @@ static int hiddev_ioctl(struct inode *inode, struct file *file, unsigned int cmd ...@@ -585,6 +593,8 @@ static int hiddev_ioctl(struct inode *inode, struct file *file, unsigned int cmd
if (copy_to_user((void *) arg, &uref, sizeof(uref))) if (copy_to_user((void *) arg, &uref, sizeof(uref)))
return -EFAULT; return -EFAULT;
return 0;
case HIDIOCGUSAGE: case HIDIOCGUSAGE:
case HIDIOCSUSAGE: case HIDIOCSUSAGE:
case HIDIOCGCOLLECTIONINDEX: case HIDIOCGCOLLECTIONINDEX:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment