drm/amdgpu: Take uvd encode rings into account in idle work
Subsystems (2)
PATCH 1/2 drm/amdgpu: Take uvd encode rings into account in idle work
Take the encode rings into account in the idle work handler.
--- drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c +4 -1
@@ -1146,10 +1146,13 @@ static void amdgpu_uvd_idle_work_handler(struct work_struct *work) {struct amdgpu_device *adev = container_of(work, struct amdgpu_device, uvd.inst->idle_work.work); -unsigned fences =0 , i; +unsigned fences =0 , i, j;for (i =0 ; i < adev->uvd.num_uvd_inst; ++i) { fences +=amdgpu_fence_count_emitted (&adev->uvd.inst[i].ring); +for (j =0 ; j < adev->uvd.num_uvd_inst; ++j) { + fences +=amdgpu_fence_count_emitted (&adev->uvd.inst[i].ring_enc[j]); + } }if (fences ==0 ) {
Signature · 6 lines
2.13.6 _______________________________________________ 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): 20180517180354.14541-1-alexander.deucher-5C7GfCeVMHo@public.gmane.org
PATCH 2/2 drm/amdgpu: Take vcn encode rings into account in idle work
Take the encode rings into account in the idle work handler.
--- drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.c | 5 +++++ 1 file changed, 5 insertions(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.c +5 -0
@@ -205,6 +205,11 @@ static void amdgpu_vcn_idle_work_handler(struct work_struct *work)struct amdgpu_device *adev = container_of(work, struct amdgpu_device, vcn.idle_work.work);unsigned fences =amdgpu_fence_count_emitted (&adev->vcn.ring_dec); +unsigned i; + +for (i =0 ; i < adev->vcn.num_enc_rings; ++i) { + fences +=amdgpu_fence_count_emitted (&adev->vcn.ring_enc[i]); + }if (fences ==0 ) {if (adev->pm.dpm_enabled) {
Signature · 6 lines
2.13.6 _______________________________________________ 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): 20180517180354.14541-2-alexander.deucher-5C7GfCeVMHo@public.gmane.org
Re: [PATCH 2/2] drm/amdgpu: Take vcn encode rings into account in idle work
Am 17.05.2018 um 20:03 schrieb Alex Deucher:
Quoted 12 lines
Take the encode rings into account in the idle work handler.
Signed-off-by Alex Deucher <[email protected]>--- drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.c | 5 +++++ 1 file changed, 5 insertions(+)drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.c +0
-0
drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.c static void amdgpu_vcn_idle_work_handler(struct work_struct *work) · line 212
Quoted 8 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.c +5
-0@@ -205,6 +205,11 @@ static void amdgpu_vcn_idle_work_handler(struct work_struct *work)struct amdgpu_device *adev = container_of(work, struct amdgpu_device, vcn.idle_work.work);unsigned fences =amdgpu_fence_count_emitted (&adev->vcn.ring_dec); +unsigned i; + +for (i =0 ; i < adev->vcn.num_enc_rings; ++i) { + fences +=amdgpu_fence_count_emitted (&adev->vcn.ring_enc[i]); + }
"{" and "}" should be dropped here if I'm not completely mistaken.
But either way Reviewed-by: Christian König <[email protected]> for the whole series.
Christian.
drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.c static void amdgpu_vcn_idle_work_handler(struct work_struct *work) · line 215
Quoted 3 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.c +0
-0if (fences ==0 ) {if (adev->pm.dpm_enabled) {
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx