diff options
Diffstat (limited to 'drivers/hid/hid-core.c')
-rw-r--r-- | drivers/hid/hid-core.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/hid/hid-core.c b/drivers/hid/hid-core.c index 1fd5e331fa8d..5ddace093f0f 100644 --- a/drivers/hid/hid-core.c +++ b/drivers/hid/hid-core.c | |||
@@ -654,13 +654,12 @@ int hid_parse_report(struct hid_device *device, __u8 *start, | |||
654 | return -ENOMEM; | 654 | return -ENOMEM; |
655 | device->rsize = size; | 655 | device->rsize = size; |
656 | 656 | ||
657 | parser = vmalloc(sizeof(struct hid_parser)); | 657 | parser = vzalloc(sizeof(struct hid_parser)); |
658 | if (!parser) { | 658 | if (!parser) { |
659 | ret = -ENOMEM; | 659 | ret = -ENOMEM; |
660 | goto err; | 660 | goto err; |
661 | } | 661 | } |
662 | 662 | ||
663 | memset(parser, 0, sizeof(struct hid_parser)); | ||
664 | parser->device = device; | 663 | parser->device = device; |
665 | 664 | ||
666 | end = start + size; | 665 | end = start + size; |