[PATCH] drm/amdgpu: Fix memory trashing if UVD ring test fails

Christian König deathsimple at vodafone.de
Wed Aug 3 19:05:35 UTC 2016


Am 03.08.2016 um 20:39 schrieb Jay Cornwall:
> fence_put was called on an uninitialized variable.
>
> Signed-off-by: Jay Cornwall <jay at jcornwall.me>

Good catch, patch is Reviewed-by: Christian König <christian.koenig at amd.com>

Regards,
Christian.

> ---
>   drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 3 ++-
>   1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c
> index b11f4e8..4aa993d 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c
> @@ -1187,7 +1187,8 @@ int amdgpu_uvd_ring_test_ib(struct amdgpu_ring *ring, long timeout)
>   		r = 0;
>   	}
>   
> -error:
>   	fence_put(fence);
> +
> +error:
>   	return r;
>   }




More information about the amd-gfx mailing list