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

Commit 419edc05 authored by Srinu Gorle's avatar Srinu Gorle Committed by Gerrit - the friendly Code Review server
Browse files

msm: vidc: correct buffer size calcuation logic for output plane



if input format and resolution are same buffer size then
plane buffer size re-calculation is getting skipped,
due to this client not able to set custom buffer size.
Recalculate buffer sizes of output plane, when client
set valid custom buffer size.

Change-Id: I830040c311c3ffacf33c2b3d9ccb753e42970df9
Signed-off-by: default avatarSrinu Gorle <sgorle@codeaurora.org>
parent 5bf14d48
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
/* Copyright (c) 2012-2017, The Linux Foundation. All rights reserved.
/* Copyright (c) 2012-2017, 2019 The Linux Foundation. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
@@ -685,7 +685,8 @@ int msm_vdec_s_fmt(struct msm_vidc_inst *inst, struct v4l2_format *f)
		if (inst->fmts[fmt->type].fourcc == f->fmt.pix_mp.pixelformat &&
			inst->prop.width[OUTPUT_PORT] == f->fmt.pix_mp.width &&
			inst->prop.height[OUTPUT_PORT] ==
				f->fmt.pix_mp.height) {
			f->fmt.pix_mp.height &&
			!inst->buffer_size_limit) {
			dprintk(VIDC_DBG, "No change in OUTPUT port params\n");
			return 0;
		}