]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amdkfd: add helper function for kfd sysfs create
authorPhilip Yang <Philip.Yang@amd.com>
Wed, 16 Jun 2021 14:02:18 +0000 (10:02 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 30 Jun 2021 04:18:23 +0000 (00:18 -0400)
commit3a3366717438d13f5d88d22eff3326e47a6e15f6
tree7708714d03dbe21e411c41c370917aecf914360a
parent7fb6f02c08224363bdefbaf63f7851f09d617a27
drm/amdkfd: add helper function for kfd sysfs create

No functionality change. Modify kfd_sysfs_create_file to use kobject as
parameter, so it becomes common helper function to remove duplicate code
and will simplify new kfd sysfs file create in future.

Move pr_warn to helper function if sysfs file create failed. Set helper
function as void return because caller doesn't use the helper function
return value.

Signed-off-by: Philip Yang <Philip.Yang@amd.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdkfd/kfd_process.c