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

Commit 954a066a authored by Darshana Patil's avatar Darshana Patil
Browse files

msm: vidc: Fixed LTR count capability



Kona target supports two LTR frames encoding.
Fixing this capability in kona driver.
Handle resolution check correctly while setting
slice mode.

Change-Id: Iea6a041ecafb24da014832ecf2146088d4569a6f
CRs-Fixed: 2444064
Signed-off-by: default avatarDarshana Patil <darshana@codeaurora.org>
parent 35da0d64
Loading
Loading
Loading
Loading
+7 −5
Original line number Diff line number Diff line
@@ -2374,7 +2374,7 @@ int msm_venc_set_vbv_delay(struct msm_vidc_inst *inst)
	height = f->fmt.pix_mp.height;
	width = f->fmt.pix_mp.width;
	mbpf = NUM_MBS_PER_FRAME(height, width);
	fps = inst->clk_data.frame_rate;
	fps = inst->clk_data.frame_rate >> 16;
	mbpf = NUM_MBS_PER_FRAME(height, width);
	mbps = NUM_MBS_PER_SEC(height, width, fps);

@@ -2850,11 +2850,13 @@ int msm_venc_set_slice_control_mode(struct msm_vidc_inst *inst)
	f = &inst->fmts[INPUT_PORT].v4l2_fmt;
	output_width = f->fmt.pix_mp.width;
	output_height = f->fmt.pix_mp.height;
	if (output_height < 128 ||
		(codec != V4L2_PIX_FMT_HEVC && output_width < 384) ||
		(codec != V4L2_PIX_FMT_H264 && output_width < 192)) {
	if ((codec == V4L2_PIX_FMT_HEVC) &&
		(output_height < 128 || output_width < 384))
		goto set_and_exit;

	if ((codec == V4L2_PIX_FMT_H264) &&
		(output_height < 128 || output_width < 192))
		goto set_and_exit;
	}

	ctrl = get_ctrl(inst, V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE);
	if (ctrl->val == V4L2_MPEG_VIDEO_MULTI_SICE_MODE_MAX_MB) {
+1 −1
Original line number Diff line number Diff line
@@ -171,7 +171,7 @@ static struct msm_vidc_codec_capability kona_capabilities[] = {
	{CAP_SCALE_Y, DOMAINS_ALL, CODECS_ALL, 4096, 65536, 1, 4096},
	{CAP_BFRAME, ENC, H264|HEVC, 0, 1, 1, 0},
	{CAP_HIER_P_NUM_ENH_LAYERS, ENC, H264|HEVC, 0, 6, 1, 0},
	{CAP_LTR_COUNT, ENC, H264|HEVC, 0, 6, 1, 0},
	{CAP_LTR_COUNT, ENC, H264|HEVC, 0, 2, 1, 0},
	/* ((4096 * 2304) / 256) * 60 fps */
	{CAP_MBS_PER_SECOND_POWER_SAVE, ENC, CODECS_ALL,
		0, 2211840, 1, 2211840},