Skip to contentSkip to conversation

drm/amdkfd Avoid destroy hqd when GPU is on reset

PATCH New Jack Zhang 1 participant 1 message Apr 7, 2020

Subsystems (3)
lore
Share & tools
lore

Jack Zhang

author
#0 lore raw

PATCH 3/3 drm/amdkfd Avoid destroy hqd when GPU is on reset

porting to gfx10 from
commit 1b0bfcff463f390c4032ebe36a4d5fb777c00a4c

Originally, MEC is touched
without GPU initialized first.

---
 drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v10.c | 3 +++
 1 file changed, 3 insertions(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v10.c +3 -0
index 4ec6d0c..691c897 100644
@@ -543,6 +543,9 @@ static int kgd_hqd_destroy(struct kgd_dev *kgd, void *mqd,
 	uint32_t temp;
 	struct v10_compute_mqd *m = get_mqd(mqd);
 
+	if (adev->in_gpu_reset)
+		return -EIO;
+
 #if 0
 	unsigned long flags;
 	int retry;
Signature · 6 lines
2.7.4

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx