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

Commit fa91a6ed authored by Aravind Venkateswaran's avatar Aravind Venkateswaran
Browse files

msm: mdss: Program unpack pattern for pipes with solidfill



When a pipe is staged with a solidfill color, we need to also
program the correct unpack pattern for the color format. If the
unpack pattern is not specified, the corresponding color layer may
not be display correctly.

Change-Id: Ic52fe29235813faa788745dd72f82edaca2635f1
Signed-off-by: default avatarAravind Venkateswaran <aravindh@codeaurora.org>
parent c35ae825
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -1240,7 +1240,7 @@ static int mdss_mdp_src_addr_setup(struct mdss_mdp_pipe *pipe,
static int mdss_mdp_pipe_solidfill_setup(struct mdss_mdp_pipe *pipe)
{
	int ret;
	u32 secure, format;
	u32 secure, format, unpack;

	pr_debug("solid fill setup on pnum=%d\n", pipe->num);

@@ -1253,9 +1253,13 @@ static int mdss_mdp_pipe_solidfill_setup(struct mdss_mdp_pipe *pipe)
	format = MDSS_MDP_FMT_SOLID_FILL;
	secure = (pipe->flags & MDP_SECURE_OVERLAY_SESSION ? 0xF : 0x0);

	/* support ARGB color format only */
	unpack = (C3_ALPHA << 24) | (C2_R_Cr << 16) |
		(C1_B_Cb << 8) | (C0_G_Y << 0);
	mdss_mdp_pipe_write(pipe, MDSS_MDP_REG_SSPP_SRC_FORMAT, format);
	mdss_mdp_pipe_write(pipe, MDSS_MDP_REG_SSPP_SRC_CONSTANT_COLOR,
		pipe->bg_color);
	mdss_mdp_pipe_write(pipe, MDSS_MDP_REG_SSPP_SRC_UNPACK_PATTERN, unpack);
	mdss_mdp_pipe_write(pipe, MDSS_MDP_REG_SSPP_SRC_ADDR_SW_STATUS, secure);

	return 0;