From: Lijo Lazar Date: Mon, 9 Dec 2024 03:44:53 +0000 (+0530) Subject: drm/amdgpu: Avoid VF for RAS recovery source check X-Git-Tag: v6.14-rc1~174^2~14^2~62 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=fccb446f82b9155c05758d1fa30af4a06494e0ec;p=thirdparty%2Fkernel%2Flinux.git drm/amdgpu: Avoid VF for RAS recovery source check VF device sets the RAS flag when mailbox data can't be read properly. There is no conclusive way to tell if the real source is RAS error. Therefore VF schedules a KFD based reset which doesn't set RAS source. SKip checking RAS source for any VF scheduled recovery. Signed-off-by: Lijo Lazar Reported-by: Vojislav Tomasevic Reviewed-by: Yiqing Yao Tested-by: Yiqing Yao Fixes: e1ee2111ca48 ("drm/amdgpu: Prefer RAS recovery for scheduler hang") 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 144295da9e4cc..e22fc7a8101f0 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c @@ -5866,6 +5866,7 @@ int amdgpu_device_gpu_recover(struct amdgpu_device *adev, * detected at the same time, let RAS recovery take care of it. */ if (amdgpu_ras_is_err_state(adev, AMDGPU_RAS_BLOCK__ANY) && + !amdgpu_sriov_vf(adev) && reset_context->src != AMDGPU_RESET_SRC_RAS) { dev_dbg(adev->dev, "Gpu recovery from source: %d yielding to RAS error recovery handling",