Commit 45dc1ac7 authored by Jiri Kosina's avatar Jiri Kosina

HID: propagate return value correctly in hid_input_report()

Fix a return value propagation that was omitted in David Herrmann's
locking fix around hid_input_report().
Reported-by: default avatarDavid Herrmann <dh.herrmann@googlemail.com>
Signed-off-by: default avatarJiri Kosina <jkosina@suse.cz>
parent 4ea54542
...@@ -1086,7 +1086,7 @@ int hid_input_report(struct hid_device *hid, int type, u8 *data, int size, int i ...@@ -1086,7 +1086,7 @@ int hid_input_report(struct hid_device *hid, int type, u8 *data, int size, int i
struct hid_report *report; struct hid_report *report;
char *buf; char *buf;
unsigned int i; unsigned int i;
int ret; int ret = 0;
if (!hid) if (!hid)
return -ENODEV; return -ENODEV;
...@@ -1145,7 +1145,7 @@ int hid_input_report(struct hid_device *hid, int type, u8 *data, int size, int i ...@@ -1145,7 +1145,7 @@ int hid_input_report(struct hid_device *hid, int type, u8 *data, int size, int i
unlock: unlock:
up(&hid->driver_lock); up(&hid->driver_lock);
return 0; return ret;
} }
EXPORT_SYMBOL_GPL(hid_input_report); EXPORT_SYMBOL_GPL(hid_input_report);
......
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