drm/amdgpu: stop cp resume when compute ring test failed
Subsystems (2)
PATCH 1/2 drm/amdgpu: stop cp resume when compute ring test failed
driver should stop cp resume once compute
ring test failed
--- drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 4 +++- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 4 +++- drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 4 +++- 3 files changed, 9 insertions(+), 3 deletions(-)
drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c +3 -1
@@ -3132,7 +3132,9 @@ static int gfx_v7_0_cp_compute_resume(struct amdgpu_device *adev)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { ring = &adev->gfx.compute_ring[i]; -amdgpu_ring_test_helper (ring); + r =amdgpu_ring_test_helper (ring); +if (r) +return r; }return 0 ;
drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c +3 -1
@@ -4781,7 +4781,9 @@ static int gfx_v8_0_cp_test_all_rings(struct amdgpu_device *adev)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { ring = &adev->gfx.compute_ring[i]; -amdgpu_ring_test_helper (ring); + r =amdgpu_ring_test_helper (ring); +if (r) +return r; }return 0 ;
drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c +3 -1
@@ -3846,7 +3846,9 @@ static int gfx_v9_0_cp_resume(struct amdgpu_device *adev)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { ring = &adev->gfx.compute_ring[i]; -amdgpu_ring_test_helper (ring); + r =amdgpu_ring_test_helper (ring); +if (r) +return r; }gfx_v9_0_enable_gui_idle_interrupt (adev, true);
Signature · 6 lines
2.7.4 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
PATCH 2/2 drm/amdgpu: drop the unused local variable
local variable kiq won't be used in functiongfx_v8_0_ring_emit_rreg
--- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 1 - 1 file changed, 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c +0 -1
@@ -6395,7 +6395,6 @@ static void gfx_v8_0_ring_emit_rreg(struct amdgpu_ring *ring, uint32_t reg, uint32_t reg_val_offs) {struct amdgpu_device *adev = ring->adev; -struct amdgpu_kiq *kiq = &adev->gfx.kiq;amdgpu_ring_write (ring,PACKET3 (PACKET3_COPY_DATA ,4 )); amdgpu_ring_write(ring, 0 | /* src: register*/
Signature · 6 lines
2.7.4 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
RE: [PATCH 2/2] drm/amdgpu: drop the unused local variable
Hi Hawking
Can you help also remove the same local variable kiq for gfx_v10_0_ring_emit_rreg? Thanks in advance. After that , Reviewed-by: Yintian Tao <[email protected]>
Best Regards
Yintian Tao
-----Original Message-----
From: amd-gfx <[email protected]> On Behalf Of Hawking Zhang
Sent: 2020年4月23日 17:02
To: [email protected]
Cc: Zhang, Hawking <[email protected]>
Subject: [PATCH 2/2] drm/amdgpu: drop the unused local variable
local variable kiq won't be used in function gfx_v8_0_ring_emit_rreg
--- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 1 - 1 file changed, 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c +0 -1
@@ -6395,7 +6395,6 @@ static void gfx_v8_0_ring_emit_rreg(struct amdgpu_ring *ring, uint32_t reg, uint32_t reg_val_offs) {struct amdgpu_device *adev = ring->adev; -struct amdgpu_kiq *kiq = &adev->gfx.kiq;amdgpu_ring_write (ring,PACKET3 (PACKET3_COPY_DATA ,4 )); amdgpu_ring_write(ring, 0 | /* src: register*/
--
2.7.4
_______________________________________________
amd-gfx mailing list
[email protected]
https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.freedesktop.org%2Fmailman%2Flistinfo%2Famd-gfx&data=02%7C01%7Cyintian.tao%40amd.com%7C3e351ebdd7ff45259e6108d7e76502d0%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637232293332601376&sdata=dH2o%2Bl9%2FjqzP2IIN43qIDrbpmmQpXjPwgGvyaAc%2B1L8%3D&reserved=0
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Am 23.04.20 um 11:01 schrieb Hawking Zhang:
Quoted 2 lines
driver should stop cp resume once compute
ring test failed
Mhm intentionally ignored those errors because the compute rings sometimes doesn't come up again after a GPU reset.
We even have the necessary logic in the SW scheduler to redirect the jobs to another compute ring when one fails to come up again.
Christian.
Quoted 44 lines
Change-Id I4cd3328f38e0755d0c877484936132d204c9fe50Signed-off-by Hawking Zhang <[email protected]>--- drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 4 +++- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 4 +++- drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 4 +++- 3 files changed, 9 insertions(+), 3 deletions(-)drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c +3
-1@@ -3132,7 +3132,9 @@ static int gfx_v7_0_cp_compute_resume(struct amdgpu_device *adev)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { ring = &adev->gfx.compute_ring[i]; -amdgpu_ring_test_helper (ring); + r =amdgpu_ring_test_helper (ring); +if (r) +return r; }return 0 ;drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c +3
-1@@ -4781,7 +4781,9 @@ static int gfx_v8_0_cp_test_all_rings(struct amdgpu_device *adev)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { ring = &adev->gfx.compute_ring[i]; -amdgpu_ring_test_helper (ring); + r =amdgpu_ring_test_helper (ring); +if (r) +return r; }return 0 ;drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c +0
-0
drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c static int gfx_v9_0_cp_resume(struct amdgpu_device *adev) · line 3854
Quoted 10 lines
drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c +3
-1@@ -3846,7 +3846,9 @@ static int gfx_v9_0_cp_resume(struct amdgpu_device *adev)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { ring = &adev->gfx.compute_ring[i]; -amdgpu_ring_test_helper (ring); + r =amdgpu_ring_test_helper (ring); +if (r) +return r; }gfx_v9_0_enable_gui_idle_interrupt (adev, true);
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
[AMD Official Use Only - Internal Distribution Only]
Would you mind to enable this and try it again? The recent gpu reset testing on vega20 looks very positive.
Regards,
Hawking
-----Original Message-----
From: Christian König <[email protected]>
Sent: Thursday, April 23, 2020 20:31
To: Zhang, Hawking <[email protected]>; [email protected]
Subject: Re: [PATCH 1/2] drm/amdgpu: stop cp resume when compute ring test failed
Am 23.04.20 um 11:01 schrieb Hawking Zhang:
Quoted 1 line
driver should stop cp resume once compute ring test failed
Mhm intentionally ignored those errors because the compute rings sometimes doesn't come up again after a GPU reset.
We even have the necessary logic in the SW scheduler to redirect the jobs to another compute ring when one fails to come up again.
Christian.
Quoted 59 lines
Change-Id I4cd3328f38e0755d0c877484936132d204c9fe50Signed-off-by Hawking Zhang <[email protected]>--- drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 4 +++- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 4 +++- drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 4 +++- 3 files changed, 9 insertions(+), 3 deletions(-)drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c +3
-1@@ -3132,7 +3132,9 @@ static int gfx_v7_0_cp_compute_resume(struct amdgpu_device *adev)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { ring = &adev->gfx.compute_ring[i]; -amdgpu_ring_test_helper (ring); + r =amdgpu_ring_test_helper (ring); +if (r) +return r; }return 0;
drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c +3
-1@@ -4781,7 +4781,9 @@ static int gfx_v8_0_cp_test_all_rings(struct amdgpu_device *adev)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { ring = &adev->gfx.compute_ring[i]; -amdgpu_ring_test_helper (ring); + r =amdgpu_ring_test_helper (ring); +if (r) +return r; }return 0;
drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c +3
-1@@ -3846,7 +3846,9 @@ static int gfx_v9_0_cp_resume(struct amdgpu_device *adev)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { ring = &adev->gfx.compute_ring[i]; -amdgpu_ring_test_helper (ring); + r =amdgpu_ring_test_helper (ring); +if (r) +return r; }
Quoted 1 line
gfx_v9_0_enable_gui_idle_interrupt(adev, true);
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Yeah, we certainly could try this again. But maybe split that up into individual patches for gfx7/8/9.
In other words make it easy to revert if this still doesn't work well on gfx7 or some other generation.
Christian.
Am 23.04.20 um 15:43 schrieb Zhang, Hawking:
Quoted 78 lines
[AMD Official Use Only - Internal Distribution Only]
Would you mind to enable this and try it again? The recent gpu reset testing on vega20 looks very positive.
Regards,
Hawking
-----Original Message-----
From: Christian König <[email protected]>
Sent: Thursday, April 23, 2020 20:31
To: Zhang, Hawking <[email protected]>; [email protected]
Subject: Re: [PATCH 1/2] drm/amdgpu: stop cp resume when compute ring test failedAm 23.04.20 um 11:01 schrieb Hawking Zhang:
Quoted 1 line
driver should stop cp resume once compute ring test failed
Mhm intentionally ignored those errors because the compute rings sometimes doesn't come up again after a GPU reset.
We even have the necessary logic in the SW scheduler to redirect the jobs to another compute ring when one fails to come up again.
Christian.
Quoted 58 lines
Change-Id I4cd3328f38e0755d0c877484936132d204c9fe50Signed-off-by Hawking Zhang <[email protected]>--- drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 4 +++- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 4 +++- drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 4 +++- 3 files changed, 9 insertions(+), 3 deletions(-)drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c +3
-1@@ -3132,7 +3132,9 @@ static int gfx_v7_0_cp_compute_resume(struct amdgpu_device *adev)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { ring = &adev->gfx.compute_ring[i]; -amdgpu_ring_test_helper (ring); + r =amdgpu_ring_test_helper (ring); +if (r) +return r; }return 0;drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c +3
-1@@ -4781,7 +4781,9 @@ static int gfx_v8_0_cp_test_all_rings(struct amdgpu_device *adev)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { ring = &adev->gfx.compute_ring[i]; -amdgpu_ring_test_helper (ring); + r =amdgpu_ring_test_helper (ring); +if (r) +return r; }return 0;drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c +3
-1@@ -3846,7 +3846,9 @@ static int gfx_v9_0_cp_resume(struct amdgpu_device *adev)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { ring = &adev->gfx.compute_ring[i]; -amdgpu_ring_test_helper (ring); + r =amdgpu_ring_test_helper (ring); +if (r) +return r; }
Quoted 5 lines
Quoted 1 line
gfx_v9_0_enable_gui_idle_interrupt(adev, true);_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Quoted 6 lines · Christian König
Yeah, we certainly could try this again. But maybe split that up into individual patches for gfx7/8/9.
In other words make it easy to revert if this still doesn't work well on gfx7 or some other generation.
Yeah, unless there is a good reason, I don't think we should do this. IIRC, compute rings randomly fail to recover on a lot of hw generations.
Alex
Quoted 88 lines
Christian.
Am 23.04.20 um 15:43 schrieb Zhang, Hawking:
Quoted 78 lines
[AMD Official Use Only - Internal Distribution Only]
Would you mind to enable this and try it again? The recent gpu reset testing on vega20 looks very positive.
Regards,
Hawking
-----Original Message-----
From: Christian König <[email protected]>
Sent: Thursday, April 23, 2020 20:31
To: Zhang, Hawking <[email protected]>; [email protected]
Subject: Re: [PATCH 1/2] drm/amdgpu: stop cp resume when compute ring test failedAm 23.04.20 um 11:01 schrieb Hawking Zhang:
Quoted 1 line
driver should stop cp resume once compute ring test failed
Mhm intentionally ignored those errors because the compute rings sometimes doesn't come up again after a GPU reset.
We even have the necessary logic in the SW scheduler to redirect the jobs to another compute ring when one fails to come up again.
Christian.
Quoted 58 lines
Change-Id I4cd3328f38e0755d0c877484936132d204c9fe50Signed-off-by Hawking Zhang <[email protected]>--- drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 4 +++- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 4 +++- drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 4 +++- 3 files changed, 9 insertions(+), 3 deletions(-)drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c +3
-1@@ -3132,7 +3132,9 @@ static int gfx_v7_0_cp_compute_resume(struct amdgpu_device *adev)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { ring = &adev->gfx.compute_ring[i]; -amdgpu_ring_test_helper (ring); + r =amdgpu_ring_test_helper (ring); +if (r) +return r; }return 0;drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c +3
-1@@ -4781,7 +4781,9 @@ static int gfx_v8_0_cp_test_all_rings(struct amdgpu_device *adev)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { ring = &adev->gfx.compute_ring[i]; -amdgpu_ring_test_helper (ring); + r =amdgpu_ring_test_helper (ring); +if (r) +return r; }return 0;drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c +3
-1@@ -3846,7 +3846,9 @@ static int gfx_v9_0_cp_resume(struct amdgpu_device *adev)for (i =0 ; i < adev->gfx.num_compute_rings; i++) { ring = &adev->gfx.compute_ring[i]; -amdgpu_ring_test_helper (ring); + r =amdgpu_ring_test_helper (ring); +if (r) +return r; }Quoted 5 lines
Quoted 1 line
gfx_v9_0_enable_gui_idle_interrupt(adev, true);_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Quoted 4 lines
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx