HID: fix memdup.cocci warnings
authorkernel test robot <lkp@intel.com>
Thu, 25 Mar 2021 15:49:56 +0000 (23:49 +0800)
committerJiri Kosina <jkosina@suse.cz>
Tue, 30 Mar 2021 07:44:31 +0000 (09:44 +0200)
commit66ff89946e6a71e48acaecfd5190038922b8e96a
tree163e32bf10b214407705b6e4bfee534ac9acd654
parentdfe74f550810cf7480d8759956d850ce40512f7a
HID: fix memdup.cocci warnings

drivers/hid/hid-thrustmaster.c:300:27-34: WARNING opportunity for kmemdup

 Use kmemdup rather than duplicating its implementation

Generated by: scripts/coccinelle/api/memdup.cocci

Fixes: c49c33637802 ("HID: support for initialization of some Thrustmaster wheels")
CC: Dario Pagani <dario.pagani.146@gmail.com>
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: kernel test robot <lkp@intel.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
drivers/hid/hid-thrustmaster.c