drm/amdgpu: remove the check for sessions being closed
Subsystems (2)
PATCH 1/1 drm/amdgpu: remove the check for sessions being closed
This will make clock and power gated when no block decoded, for example when paused during the playback.
Signed-off-by Leo Liu <[email protected]>
--- drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c +2 -8
@@ -1089,15 +1089,9 @@ static void amdgpu_uvd_idle_work_handler(struct work_struct *work) {struct amdgpu_device *adev = container_of(work, struct amdgpu_device, uvd.idle_work.work); -unsigned i, fences, handles =0 ; +unsigned fences =amdgpu_fence_count_emitted (&adev->uvd.ring); - fences =amdgpu_fence_count_emitted (&adev->uvd.ring); - -for (i =0 ; i < adev->uvd.max_handles; ++i) -if (atomic_read (&adev->uvd.handles[i])) - ++handles; - -if (fences ==0 && handles ==0 ) { +if (fences ==0 ) {if (adev->pm.dpm_enabled) {amdgpu_dpm_enable_uvd (adev, false); }else {
Signature · 6 lines
2.7.4 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
A message that is not in the archive (sent off-list or not yet received): 1470232699-2579-1-git-send-email-leo.liu-5C7GfCeVMHo@public.gmane.org
Christian König
Reviewed-byAm 03.08.2016 um 15:58 schrieb Leo Liu:
Quoted 4 lines
This will make clock and power gated when no block decoded, for example when paused during the playback.
Signed-off-by Leo Liu <[email protected]>
Reviewed-by Christian König <[email protected]>
Quoted 16 lines
--- drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-)drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c +1
-2@@ -1089,15 +1089,9 @@ static void amdgpu_uvd_idle_work_handler(struct work_struct *work) {struct amdgpu_device *adev = container_of(work, struct amdgpu_device, uvd.idle_work.work); -unsigned i, fences, handles =0 ; +unsigned fences =amdgpu_fence_count_emitted (&adev->uvd.ring); - fences =amdgpu_fence_count_emitted (&adev->uvd.ring);
drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c static void amdgpu_uvd_idle_work_handler(struct work_struct *work) · line 1097
Quoted 10 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c +1
-6- -for (i =0 ; i < adev->uvd.max_handles; ++i) -if (atomic_read (&adev->uvd.handles[i])) - ++handles; - -if (fences ==0 && handles ==0 ) { +if (fences ==0 ) {if (adev->pm.dpm_enabled) {amdgpu_dpm_enable_uvd (adev, false); }else {
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx