diff options
author | Jiri Kosina <jkosina@suse.cz> | 2013-07-22 11:11:44 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-10-13 19:08:28 -0400 |
commit | 88e2194c2aa9f29f80b2835295e298147c06f6e2 (patch) | |
tree | a2b9a78f54dd6076250244961ff3e2caf81d5933 | |
parent | b2b6cadad699d44a8a5b2a60f3d960e00d6fb3b7 (diff) |
HID: fix unused rsize usage
commit bc197eedef1ae082ec662c64c3f4aa302821fb7a upstream.
27ce4050 ("HID: fix data access in implement()") by mistake removed
a setting of buffer size in hidp. Fix that by putting it back.
Reported-by: kbuild test robot <fengguang.wu@intel.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | net/bluetooth/hidp/core.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/net/bluetooth/hidp/core.c b/net/bluetooth/hidp/core.c index 41f154d4a5e1..de030f50f72b 100644 --- a/net/bluetooth/hidp/core.c +++ b/net/bluetooth/hidp/core.c | |||
@@ -242,6 +242,7 @@ static int hidp_send_report(struct hidp_session *session, struct hid_report *rep | |||
242 | hid_output_report(report, buf); | 242 | hid_output_report(report, buf); |
243 | hdr = HIDP_TRANS_DATA | HIDP_DATA_RTYPE_OUPUT; | 243 | hdr = HIDP_TRANS_DATA | HIDP_DATA_RTYPE_OUPUT; |
244 | 244 | ||
245 | rsize = ((report->size - 1) >> 3) + 1 + (report->id > 0); | ||
245 | ret = hidp_send_intr_message(session, hdr, buf, rsize); | 246 | ret = hidp_send_intr_message(session, hdr, buf, rsize); |
246 | 247 | ||
247 | kfree(buf); | 248 | kfree(buf); |