Commit d6509c36 authored by Ahmed S. Darwish's avatar Ahmed S. Darwish Committed by Jiri Kosina

HID: tiny patch to remove a kmalloc cast

Remove unnecessary cast.
Signed-off-by: default avatarAhmed Darwish <darwish.07@gmail.com>
Signed-off-by: default avatarJiri Kosina <jkosina@suse.cz>
parent 35068976
...@@ -656,7 +656,7 @@ struct hid_device *hid_parse_report(__u8 *start, unsigned size) ...@@ -656,7 +656,7 @@ struct hid_device *hid_parse_report(__u8 *start, unsigned size)
for (i = 0; i < HID_REPORT_TYPES; i++) for (i = 0; i < HID_REPORT_TYPES; i++)
INIT_LIST_HEAD(&device->report_enum[i].report_list); INIT_LIST_HEAD(&device->report_enum[i].report_list);
if (!(device->rdesc = (__u8 *)kmalloc(size, GFP_KERNEL))) { if (!(device->rdesc = kmalloc(size, GFP_KERNEL))) {
kfree(device->collection); kfree(device->collection);
kfree(device); kfree(device);
return NULL; return NULL;
......
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