[PATCH v2 5/5] drm/amdgpu: skip amdgpu_gmc_flush_gpu_tlb_pasid if device is wedged
Pierre-Eric Pelloux-Prayer <[email protected]>
| Newsgroups | gmane.comp.freedesktop.amd-gfx,gmane.comp.video.dri.devel,gmane.linux.kernel |
|---|---|
| Message-ID | <[email protected]> |
Otherwise it'll fail with: "failed to reg_write_reg_wait" and we're going to fill the MES buffer which will prevent the reset to succeed. Signed-off-by: Pierre-Eric Pelloux-Prayer <[email protected]> --- drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c index f43d85ba4b78..c33320a6413e 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c @@ -786,6 +786,9 @@ int amdgpu_gmc_flush_gpu_tlb_pasid(struct amdgpu_device *adev, uint16_t pasid, int r, cnt = 0; uint32_t seq; + if (amdgpu_device_is_wedged(adev)) + return -ENODEV; + /* * A GPU reset should flush all TLBs anyway, so no need to do * this while one is ongoing. -- 2.43.0