summaryrefslogtreecommitdiff
path: root/drivers/input/evdev.c
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2014-05-15 03:49:19 +0400
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2014-05-15 03:49:19 +0400
commit879f99ef2c4c05d9a7f0a67a05f1415663119825 (patch)
tree0399664761f675eef741f8b08b92635069586151 /drivers/input/evdev.c
parent70a26071f8552a0f193cf442f424decfe0f2e569 (diff)
parentd6d211db37e75de2ddc3a4f979038c40df7cc79c (diff)
downloadlinux-879f99ef2c4c05d9a7f0a67a05f1415663119825.tar.xz
Merge tag 'v3.15-rc5' into next
Merge with Linux 3.15-rc5 to sync up Wacom and other changes.
Diffstat (limited to 'drivers/input/evdev.c')
-rw-r--r--drivers/input/evdev.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/input/evdev.c b/drivers/input/evdev.c
index 4af24f1e91b1..fd325ec9f064 100644
--- a/drivers/input/evdev.c
+++ b/drivers/input/evdev.c
@@ -936,11 +936,13 @@ static long evdev_do_ioctl(struct file *file, unsigned int cmd,
return -EFAULT;
error = input_ff_upload(dev, &effect, file);
+ if (error)
+ return error;
if (put_user(effect.id, &(((struct ff_effect __user *)p)->id)))
return -EFAULT;
- return error;
+ return 0;
}
/* Multi-number variable-length handlers */