drm/amd/psp: Fix sysfs: cannot create duplicate filename
authorAndrey Grodzovsky <andrey.grodzovsky@amd.com>
Fri, 16 Oct 2020 14:50:44 +0000 (10:50 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 21 Oct 2020 21:33:43 +0000 (17:33 -0400)
psp sysfs not cleaned up on driver unload for sienna_cichlid

Fixes: ce87c98db428e7 ("drm/amdgpu: Include sienna_cichlid in USBC PD FW support.")
Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org # 5.9.x
drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c

index a9cae6d..96a9699 100644 (file)
@@ -208,7 +208,8 @@ static int psp_sw_fini(void *handle)
                adev->psp.ta_fw = NULL;
        }
 
-       if (adev->asic_type == CHIP_NAVI10)
+       if (adev->asic_type == CHIP_NAVI10 ||
+           adev->asic_type == CHIP_SIENNA_CICHLID)
                psp_sysfs_fini(adev);
 
        return 0;