Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

drm/amdgpu: remove partition attributes sys file for gfx_v9_4_3

For driver de-init like rmmod operations those partition specific
attributes need to be removed accordingly.

Signed-off-by: Shiwu Zhang <shiwu.zhang@amd.com>
Reviewed-by: Rajneesh Bhardwaj <rajneesh.bhardwaj@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>

authored by

Shiwu Zhang and committed by
Alex Deucher
993d218f 37dd9d58

+9
+7
drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c
··· 1345 1345 1346 1346 return 0; 1347 1347 } 1348 + 1349 + void amdgpu_gfx_sysfs_fini(struct amdgpu_device *adev) 1350 + { 1351 + device_remove_file(adev->dev, &dev_attr_current_compute_partition); 1352 + device_remove_file(adev->dev, &dev_attr_available_compute_partition); 1353 + device_remove_file(adev->dev, &dev_attr_current_memory_partition); 1354 + }
+1
drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h
··· 502 502 503 503 bool amdgpu_gfx_is_master_xcc(struct amdgpu_device *adev, int xcc_id); 504 504 int amdgpu_gfx_sysfs_init(struct amdgpu_device *adev); 505 + void amdgpu_gfx_sysfs_fini(struct amdgpu_device *adev); 505 506 #endif
+1
drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c
··· 895 895 gfx_v9_4_3_mec_fini(adev); 896 896 amdgpu_bo_unref(&adev->gfx.rlc.clear_state_obj); 897 897 gfx_v9_4_3_free_microcode(adev); 898 + amdgpu_gfx_sysfs_fini(adev); 898 899 899 900 return 0; 900 901 }