[PATCH] drm/amdgpu/vcn2.5: fix the enc loop with hw fini
Leo Liu
leo.liu at amd.com
Fri Nov 15 22:30:30 UTC 2019
On 2019-11-15 5:15 p.m., Leo Liu wrote:
> Fixes: 9072c584 (drm/amdgpu: move JPEG2.5 out from VCN2.5)
Just checked the bug was existing before the changes above.
Regards,
Leo
>
> Signed-off-by: Leo Liu <leo.liu at amd.com>
> ---
> drivers/gpu/drm/amd/amdgpu/vcn_v2_5.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/vcn_v2_5.c b/drivers/gpu/drm/amd/amdgpu/vcn_v2_5.c
> index 451dc814d845..42d6b9f0553b 100644
> --- a/drivers/gpu/drm/amd/amdgpu/vcn_v2_5.c
> +++ b/drivers/gpu/drm/amd/amdgpu/vcn_v2_5.c
> @@ -268,7 +268,7 @@ static int vcn_v2_5_hw_fini(void *handle)
> {
> struct amdgpu_device *adev = (struct amdgpu_device *)handle;
> struct amdgpu_ring *ring;
> - int i;
> + int i, j;
>
> for (i = 0; i < adev->vcn.num_vcn_inst; ++i) {
> if (adev->vcn.harvest_config & (1 << i))
> @@ -280,8 +280,8 @@ static int vcn_v2_5_hw_fini(void *handle)
>
> ring->sched.ready = false;
>
> - for (i = 0; i < adev->vcn.num_enc_rings; ++i) {
> - ring = &adev->vcn.inst[i].ring_enc[i];
> + for (j = 0; j < adev->vcn.num_enc_rings; ++j) {
> + ring = &adev->vcn.inst[i].ring_enc[j];
> ring->sched.ready = false;
> }
> }
More information about the amd-gfx
mailing list