diff options
author | Emily Deng <Emily.Deng@amd.com> | 2018-03-07 20:35:19 -0500 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2018-03-14 15:38:25 -0400 |
commit | 58e955d9defad833f9a23c38521d7bbf01097b1d (patch) | |
tree | 8af7068e85cd4dfef39e1858a38b8534279ab9bb /drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | |
parent | e89d0d332b7554f149648d293c2b6c77b79be529 (diff) |
drm/amdgpu: Correct the place of amdgpu_pm_sysfs_fini
The amdgpu_pm_sysfs_fini should call before amdgpu_device_ip_fini,
or the adev->pm.dpm_enabled would be set to 0, then the device files
related to pp won't be removed by amdgpu_pm_sysfs_fini when unload
driver.
Signed-off-by: Emily Deng <Emily.Deng@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_device.c')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c index 856378434ea2..9a2c2c3f0603 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | |||
@@ -2086,6 +2086,7 @@ void amdgpu_device_fini(struct amdgpu_device *adev) | |||
2086 | 2086 | ||
2087 | amdgpu_ib_pool_fini(adev); | 2087 | amdgpu_ib_pool_fini(adev); |
2088 | amdgpu_fence_driver_fini(adev); | 2088 | amdgpu_fence_driver_fini(adev); |
2089 | amdgpu_pm_sysfs_fini(adev); | ||
2089 | amdgpu_fbdev_fini(adev); | 2090 | amdgpu_fbdev_fini(adev); |
2090 | r = amdgpu_device_ip_fini(adev); | 2091 | r = amdgpu_device_ip_fini(adev); |
2091 | if (adev->firmware.gpu_info_fw) { | 2092 | if (adev->firmware.gpu_info_fw) { |
@@ -2114,7 +2115,6 @@ void amdgpu_device_fini(struct amdgpu_device *adev) | |||
2114 | iounmap(adev->rmmio); | 2115 | iounmap(adev->rmmio); |
2115 | adev->rmmio = NULL; | 2116 | adev->rmmio = NULL; |
2116 | amdgpu_device_doorbell_fini(adev); | 2117 | amdgpu_device_doorbell_fini(adev); |
2117 | amdgpu_pm_sysfs_fini(adev); | ||
2118 | amdgpu_debugfs_regs_cleanup(adev); | 2118 | amdgpu_debugfs_regs_cleanup(adev); |
2119 | } | 2119 | } |
2120 | 2120 | ||