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

Commit 26df0a2a authored by Jin Li's avatar Jin Li
Browse files

drm/msm/sde: apply default csc matrix when no user setting



If user space doesn't configure CSC matrix for YUV color format,
driver needs to apply a default CSC matrix, otherwise, color will
be wrong.

Change-Id: I9d93362578daab2dcf90b4b2fa353faa37fc6b9b
Signed-off-by: default avatarJin Li <jinl@codeaurora.org>
parent 11b62eaa
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -417,7 +417,7 @@ static void _sde_plane_setup_csc(struct sde_phy_plane *pp,
			&csc_size,
			PLANE_PROP_CSC);
	if (!csc)
		return;
		goto apply_value;

	/* user space override */
	memcpy(&pp->csc_cfg, &sde_csc_NOP, sizeof(struct sde_csc_cfg));
@@ -451,6 +451,7 @@ static void _sde_plane_setup_csc(struct sde_phy_plane *pp,
	if (!pp->csc_ptr)
		SDE_ERROR("invalid csc blob, v%lld\n", csc->version);

apply_value:
	/* revert to kernel default if override not available */
	if (pp->csc_ptr)
		SDE_DEBUG("user blob override for csc\n");