Skip to content

Commit

Permalink
HID: tiny patch to remove a kmalloc cast
Browse files Browse the repository at this point in the history
Remove unnecessary cast.

Signed-off-by: Ahmed Darwish <darwish.07@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
  • Loading branch information
Ahmed S. Darwish authored and Jiri Kosina committed Jan 8, 2007
1 parent 3506897 commit d6509c3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/hid/hid-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -656,7 +656,7 @@ struct hid_device *hid_parse_report(__u8 *start, unsigned size)
for (i = 0; i < HID_REPORT_TYPES; i++)
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);
return NULL;
Expand Down

0 comments on commit d6509c3

Please sign in to comment.