[PATCH] drm/amdgpu: correct the gpu reset handling for job != NULL case

Jian, Jane Jane.Jian at amd.com
Thu Oct 15 08:34:41 UTC 2020


[AMD Official Use Only - Internal Distribution Only]

Reviewed-by: Jane Jian <Jane.Jian at amd.com>

-----Original Message-----
From: Quan, Evan <Evan.Quan at amd.com>
Sent: Thursday, October 15, 2020 3:03 PM
To: amd-gfx at lists.freedesktop.org
Cc: Deucher, Alexander <Alexander.Deucher at amd.com>; Jian, Jane <Jane.Jian at amd.com>; Quan, Evan <Evan.Quan at amd.com>
Subject: [PATCH] drm/amdgpu: correct the gpu reset handling for job != NULL case

Current code wrongly treat all cases as job == NULL.

Change-Id: I3d686617bbe67bf64e8a6ff8cc5b0de11b80afb6
Signed-off-by: Evan Quan <evan.quan at amd.com>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
index a2f0ce854160..24e6de3aa8d8 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
@@ -4643,7 +4643,7 @@ int amdgpu_device_gpu_recover(struct amdgpu_device *adev,
 retry:/* Rest of adevs pre asic reset from XGMI hive. */
 list_for_each_entry(tmp_adev, device_list_handle, gmc.xgmi.head) {
 r = amdgpu_device_pre_asic_reset(tmp_adev,
- NULL,
+ (tmp_adev == adev) ? job : NULL,
  &need_full_reset);
 /*TODO Should we stop ?*/
 if (r) {
--
2.28.0



More information about the amd-gfx mailing list