]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amdgpu: stop scheduler when calling hw_fini (v2)
authorGuchun Chen <guchun.chen@amd.com>
Fri, 27 Aug 2021 10:31:41 +0000 (18:31 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 31 Aug 2021 18:19:47 +0000 (14:19 -0400)
commit31670e2d09032293a8407cc00e2f5fc4d6fc3df4
treecb9003e2aefeb301a9c21a76f85a5ca4b37d66e0
parentae0e371ea5e2d4eb9dae7492a10cac8c08e0f32e
drm/amdgpu: stop scheduler when calling hw_fini (v2)

This gurantees no more work on the ring can be submitted
to hardware in suspend/resume case, otherwise a potential
race will occur and the ring will get no chance to stay
empty before suspend.

v2: Call drm_sched_resubmit_job before drm_sched_start to
restart jobs from the pending list.

Suggested-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com>
Suggested-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Guchun Chen <guchun.chen@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c