diff options
author | Jiri Kosina <jkosina@suse.cz> | 2014-04-01 18:45:27 +0200 |
---|---|---|
committer | Jiri Kosina <jkosina@suse.cz> | 2014-04-01 18:45:27 +0200 |
commit | b95dd3ca034a044471242fcbc8b8256f272b5062 (patch) | |
tree | 32a59028a1823e89214fce3149e80d65a0dda778 /drivers/hid/hid-input.c | |
parent | 2078b9bb240ea31ff3ea715881d1ec03d83e6de4 (diff) | |
parent | c3d77fab51f40821de91a744e4b514e9e4e76a7c (diff) |
Merge branch 'for-3.15/hid-core-ll-transport-cleanup' into for-3.15/sony
Diffstat (limited to 'drivers/hid/hid-input.c')
-rw-r--r-- | drivers/hid/hid-input.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/hid/hid-input.c b/drivers/hid/hid-input.c index 15959fbae268..f5aef792f13b 100644 --- a/drivers/hid/hid-input.c +++ b/drivers/hid/hid-input.c @@ -1150,7 +1150,7 @@ static void hidinput_led_worker(struct work_struct *work) led_work); struct hid_field *field; struct hid_report *report; - int len; + int len, ret; __u8 *buf; field = hidinput_get_led_field(hid); @@ -1184,7 +1184,10 @@ static void hidinput_led_worker(struct work_struct *work) hid_output_report(report, buf); /* synchronous output report */ - hid_output_raw_report(hid, buf, len, HID_OUTPUT_REPORT); + ret = hid_hw_output_report(hid, buf, len); + if (ret == -ENOSYS) + hid_hw_raw_request(hid, report->id, buf, len, HID_OUTPUT_REPORT, + HID_REQ_SET_REPORT); kfree(buf); } @@ -1263,8 +1266,7 @@ static struct hid_input *hidinput_allocate(struct hid_device *hid) } input_set_drvdata(input_dev, hid); - if (hid->ll_driver->request || hid->hid_output_raw_report) - input_dev->event = hidinput_input_event; + input_dev->event = hidinput_input_event; input_dev->open = hidinput_open; input_dev->close = hidinput_close; input_dev->setkeycode = hidinput_setkeycode; |