From 53de1be85254a97eebb70a2c00d6cf38494ff77c Mon Sep 17 00:00:00 2001 From: Rakshitha Shakamuri Date: Thu, 4 Jun 2020 21:05:22 -0700 Subject: [PATCH] msm: vidc: Fix KW error Fixing KW error with ID: 72859, 72860, 72861, 72862, 111827. Change-Id: Ia37cb77b27689c2064e0c4d5138d4f9d95c84455 Signed-off-by: Rakshitha Shakamuri --- msm/vidc/msm_vidc_buffer_calculations.c | 4 +++- msm/vidc/msm_vidc_debug.h | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/msm/vidc/msm_vidc_buffer_calculations.c b/msm/vidc/msm_vidc_buffer_calculations.c index e99e2fc7aee2..4f3561b64006 100644 --- a/msm/vidc/msm_vidc_buffer_calculations.c +++ b/msm/vidc/msm_vidc_buffer_calculations.c @@ -376,13 +376,15 @@ int msm_vidc_get_decoder_internal_buffer_sizes(struct msm_vidc_inst *inst) struct msm_vidc_dec_buff_size_calculators *dec_calculators; u32 width, height, i, out_min_count, num_vpp_pipes; struct v4l2_format *f; - u32 vpp_delay = inst->bse_vpp_delay; + u32 vpp_delay; if (!inst || !inst->core || !inst->core->platform_data) { d_vpr_e("%s: Instance is null!", __func__); return -EINVAL; } + vpp_delay = inst->bse_vpp_delay; + num_vpp_pipes = inst->core->platform_data->num_vpp_pipes; f = &inst->fmts[INPUT_PORT].v4l2_fmt; switch (f->fmt.pix_mp.pixelformat) { diff --git a/msm/vidc/msm_vidc_debug.h b/msm/vidc/msm_vidc_debug.h index c7ec5ae0e558..7b523eddb55f 100644 --- a/msm/vidc/msm_vidc_debug.h +++ b/msm/vidc/msm_vidc_debug.h @@ -228,7 +228,7 @@ static inline char *get_debug_level_str(int level) static inline void tic(struct msm_vidc_inst *i, enum profiling_points p, char *b) { - struct timeval __ddl_tv; + struct timeval __ddl_tv = { 0 }; if (!i->debug.pdata[p].name[0]) memcpy(i->debug.pdata[p].name, b, 64); @@ -243,7 +243,7 @@ static inline void tic(struct msm_vidc_inst *i, enum profiling_points p, static inline void toc(struct msm_vidc_inst *i, enum profiling_points p) { - struct timeval __ddl_tv; + struct timeval __ddl_tv = { 0 }; if ((msm_vidc_debug & VIDC_PERF) && !i->debug.pdata[p].sampling) {