[Libva] [PATCH] Fix 'vpp_kernels' might be used unintialized in vpp_gpe_process_sharpening
Xiang, Haihao
haihao.xiang at intel.com
Sat Sep 5 21:58:57 PDT 2015
> if IS_HASWELL, IS_GEN8 and IS_GEN9 are false condition, it will using
> unintialized 'vpp_kernels'.
> Detected by klockwork scan under critical severity.
>
Sharpening is only available on GEN75/GEN8/GEN9 in the driver, please
check xxx_codec_info in i965_device_info.c. So it won't result in any
error.
> Signed-off-by: Lim Siew Hoon <siew.hoon.lim at intel.com>
> ---
> src/gen75_vpp_gpe.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/gen75_vpp_gpe.c b/src/gen75_vpp_gpe.c
> index 118a544..d6b8585 100644
> --- a/src/gen75_vpp_gpe.c
> +++ b/src/gen75_vpp_gpe.c
> @@ -645,7 +645,7 @@ vpp_gpe_process_sharpening(VADriverContextP ctx,
>
> if(vpp_gpe_ctx->is_first_frame){
> vpp_gpe_ctx->sub_shader_sum = 3;
> - struct i965_kernel * vpp_kernels;
> + struct i965_kernel * vpp_kernels = NULL;
> if (IS_HASWELL(i965->intel.device_info))
> vpp_kernels = gen75_vpp_sharpening_kernels;
> else if (IS_GEN8(i965->intel.device_info) ||
More information about the Libva
mailing list