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

Commit 144268a4 authored by Srinu Gorle's avatar Srinu Gorle
Browse files

msm: vidc: skip biggest internal buffer allocation for slave side CP



For slave side content protection targets, memory alignment is 1MB.
Allocating biggest internal buffers size need more CMA heap size,
skip allocating max internal buffers size for slave side CP targets.

Change-Id: I553161485b062de6ad2a7e192232432cb62e87fc
Signed-off-by: default avatarSrinu Gorle <sgorle@codeaurora.org>
CRs-Fixed: 978521
parent 676c9bc2
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -1831,6 +1831,7 @@ static inline int start_streaming(struct msm_vidc_inst *inst)
{
	int rc = 0;
	struct hfi_device *hdev;
	bool slave_side_cp = inst->core->resources.slave_side_cp;

	hdev = inst->core->device;

@@ -1841,7 +1842,8 @@ static inline int start_streaming(struct msm_vidc_inst *inst)
		dprintk(VIDC_ERR, "H/w scaling is not in valid range\n");
		return -EINVAL;
	}
	if ((inst->flags & VIDC_SECURE) && !inst->in_reconfig) {
	if ((inst->flags & VIDC_SECURE) && !inst->in_reconfig &&
		!slave_side_cp) {
		rc = set_max_internal_buffers_size(inst);
		if (rc) {
			dprintk(VIDC_ERR,