diff --git a/drivers/hid/hid-core.c b/drivers/hid/hid-core.c index 67f3347afcf35620d941a893183f0883f0392f00..1cca32f46947e0675ea7b77ea28b043393ef3f75 100644 --- a/drivers/hid/hid-core.c +++ b/drivers/hid/hid-core.c @@ -969,7 +969,7 @@ int hid_input_report(struct hid_device *hid, int type, u8 *data, int size, int i if (size < rsize) { dbg("report %d is too short, (%d < %d)", report->id, size, rsize); - return -1; + memset(data + size, 0, rsize - size); } if ((hid->claimed & HID_CLAIMED_HIDDEV) && hid->hiddev_report_event)