From: Aaron Liu Date: Wed, 5 Apr 2023 11:22:20 +0000 (+0800) Subject: drm/amdgpu: skip kfd-iommu suspend/resume for S0ix X-Git-Tag: v6.6.17~4917^2~7^2~12 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f22067419e9683f8fba40ca3a0d56fb3106c7c6f;p=platform%2Fkernel%2Flinux-rpi.git drm/amdgpu: skip kfd-iommu suspend/resume for S0ix GFX is in gfxoff mode during s0ix so we shouldn't need to actually execute kfd_iommu_suspend/kfd_iommu_resume operation. Signed-off-by: Aaron Liu Acked-by: Alex Deucher Reviewed-by: Mario Limonciello Signed-off-by: Alex Deucher --- diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c index 97068c4dee74..a2292acf06d0 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c @@ -3305,9 +3305,11 @@ static int amdgpu_device_ip_resume(struct amdgpu_device *adev) { int r; - r = amdgpu_amdkfd_resume_iommu(adev); - if (r) - return r; + if (!adev->in_s0ix) { + r = amdgpu_amdkfd_resume_iommu(adev); + if (r) + return r; + } r = amdgpu_device_ip_resume_phase1(adev); if (r)