]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amdgpu/pm_runtime: update usage count in fence handling
authorAlex Deucher <alexander.deucher@amd.com>
Thu, 12 Dec 2019 22:43:36 +0000 (17:43 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 18 Dec 2019 21:09:11 +0000 (16:09 -0500)
commit18a0949467012dfd31e595512659fdd3fd307b84
treeb9de5d8cbe29dca1002016c87af3a4fff000e800
parent91601eaf4f8004df0913da901c0fd0d23aba46b2
drm/amdgpu/pm_runtime: update usage count in fence handling

Increment the usage count in emit fence, and decrement in
process fence to make sure the GPU is always considered in
use while there are fences outstanding.  We always wait for
the engines to drain in runtime suspend, but in practice
that only covers short lived jobs for gfx.  This should
cover us for longer lived fences.

Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c