drm/amdkfd: Use memdup_user() rather than duplicating its implementation
authorAtul Raut <rauji.raut@gmail.com>
Wed, 9 Aug 2023 05:30:18 +0000 (22:30 -0700)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 15 Aug 2023 22:07:41 +0000 (18:07 -0400)
commitbd6040b0ea04aca3f90bc81ccd2aa816d20292d7
tree8fc960055bc259a598a0fb6dd257b164503c6e3e
parent8b3a7a707c6c5f7ccde47cf2427a560675cc5202
drm/amdkfd: Use memdup_user() rather than duplicating its implementation

To prevent its redundant implementation and streamline
code, use memdup_user.

This fixes warnings reported by Coccinelle:
./drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.c:2811:13-20: WARNING opportunity for memdup_user

Signed-off-by: Atul Raut <rauji.raut@gmail.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.c