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

Commit b26a0ee6 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "msm: mdss: Modify SMP requirement for BWC decompression"

parents a5b0c890 d04fc76f
Loading
Loading
Loading
Loading
+25 −0
Original line number Diff line number Diff line
@@ -176,6 +176,31 @@ int mdss_mdp_smp_reserve(struct mdss_mdp_pipe *pipe)
			pipe->src_fmt, &ps);
		if (rc)
			return rc;
		/*
		 * Override fetch strides with SMP buffer size for both the
		 * planes
		 */
		if (pipe->src_fmt->fetch_planes == MDSS_MDP_PLANE_INTERLEAVED) {
			/*
			 * BWC line buffer needs to be divided into 16
			 * segments and every segment is aligned to format
			 * specific RAU size
			 */
			ps.ystride[0] = ALIGN(pipe->src.w / 16 , 32) * 16 *
				ps.rau_h[0] * pipe->src_fmt->bpp;
			ps.ystride[1] = 0;
		} else {
			u32 bwc_width = ALIGN(pipe->src.w / 16, 64) * 16;
			ps.ystride[0] = bwc_width * ps.rau_h[0];
			ps.ystride[1] = bwc_width * ps.rau_h[1];
			/*
			 * Since chroma for H1V2 is not subsampled it needs
			 * to be accounted for with bpp factor
			 */
			if (pipe->src_fmt->chroma_sample ==
				MDSS_MDP_CHROMA_H1V2)
				ps.ystride[1] *= 2;
		}
		pr_debug("BWC SMP strides ystride0=%x ystride1=%x\n",
			ps.ystride[0], ps.ystride[1]);
	} else {