From: Gavin Wan Date: Wed, 9 Nov 2022 18:12:42 +0000 (-0500) Subject: drm/amdgpu: Ignore stop rlc on SRIOV environment. X-Git-Tag: v6.6.7~3824^2~17^2~85 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ecc9b6e15af2ffc8b9c0e6f15160eb8aaea36af5;p=platform%2Fkernel%2Flinux-starfive.git drm/amdgpu: Ignore stop rlc on SRIOV environment. For SRIOV, the guest driver should not do stop rlc. The host handles programing RLC. On SRIOV, the stop rlc will be hang (RLC related registers are blocked by policy) when the RLCG interface is not enabled. Reviewed-by: Yang Wang Acked-by: Alex Deucher Signed-off-by: Gavin Wan Signed-off-by: Alex Deucher --- diff --git a/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c b/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c index 320cfce..9492dd6 100644 --- a/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c +++ b/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c @@ -1518,7 +1518,7 @@ static int smu_disable_dpms(struct smu_context *smu) } if (adev->ip_versions[GC_HWIP][0] >= IP_VERSION(9, 4, 2) && - adev->gfx.rlc.funcs->stop) + !amdgpu_sriov_vf(adev) && adev->gfx.rlc.funcs->stop) adev->gfx.rlc.funcs->stop(adev); return ret;