Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e3dbdab5 authored by Priyanka Gujjula's avatar Priyanka Gujjula Committed by Gerrit - the friendly Code Review server
Browse files

msm: vidc: Update num_ref calculation for VP8



Vp8 follows default num_ref value 2 as per
FW calculation.

Change-Id: Ibb00a3db49d1467605e63abf681061a69ec8557f
Signed-off-by: default avatarPriyanka Gujjula <pgujjula@codeaurora.org>
parent ef486705
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -477,6 +477,10 @@ int msm_vidc_get_num_ref_frames(struct msm_vidc_inst *inst)
	struct v4l2_ctrl *layer_ctrl;
	u32 codec;

	codec = get_v4l2_codec(inst);
	if (codec == V4L2_PIX_FMT_VP8)
		num_ref = num_ref << 1;

	bframe_ctrl = get_ctrl(inst, V4L2_CID_MPEG_VIDEO_B_FRAMES);
	num_bframes = bframe_ctrl->val;
	if (num_bframes > 0)
@@ -491,7 +495,6 @@ int msm_vidc_get_num_ref_frames(struct msm_vidc_inst *inst)
	layer_ctrl = get_ctrl(inst,
		V4L2_CID_MPEG_VIDC_VIDEO_HEVC_MAX_HIER_CODING_LAYER);
	num_hp_layers = layer_ctrl->val;
	codec = get_v4l2_codec(inst);
	if (num_hp_layers > 1) {
		/* LTR and B - frame not supported with hybrid HP */
		if (inst->hybrid_hp)