msm: vidc: fix time stamp store and fetch

Fix to skip time stamp store and fetch for buffers
with codec config flag.

Change-Id: I867db519c45751ef2dadef5a323c7a4ad2741385
Signed-off-by: Shi Zhongbo <zhongbos@codeaurora.org>
This commit is contained in:
Shi Zhongbo 2020-08-03 16:21:45 +08:00
commit 21cba5ad49

View file

@ -437,7 +437,9 @@ int msm_vidc_qbuf(void *instance, struct media_device *mdev,
msm_comm_release_timestamps(inst);
inst->flush_timestamps = false;
rc = msm_comm_store_timestamp(inst, timestamp_us);
if (!(b->flags & V4L2_BUF_FLAG_CODECCONFIG))
rc = msm_comm_store_timestamp(inst, timestamp_us);
if (rc)
goto unlock;
inst->clk_data.frame_rate = msm_comm_get_max_framerate(inst);
@ -508,7 +510,9 @@ int msm_vidc_dqbuf(void *instance, struct v4l2_buffer *b)
return -EINVAL;
}
}
if (is_decode_session(inst) && b->type == OUTPUT_MPLANE)
if (is_decode_session(inst) &&
b->type == OUTPUT_MPLANE &&
!(b->flags & V4L2_BUF_FLAG_CODECCONFIG))
msm_comm_fetch_ts_framerate(inst, b);
return rc;