diff mbox

[7/8] drm/sti: in crtc_atomic_flush, enable only planes of this crtc

Message ID 1473946905-4374-8-git-send-email-fabien.dessenne@st.com (mailing list archive)
State New, archived
Headers show

Commit Message

Fabien DESSENNE Sept. 15, 2016, 1:41 p.m. UTC
crtc_atomic_flush performs some additional processing, like plane
enable at mixer level.
Enable only the planes attached to the CRTC.

Signed-off-by: Fabien Dessenne <fabien.dessenne@st.com>
---
 drivers/gpu/drm/sti/sti_crtc.c | 4 ++++
 1 file changed, 4 insertions(+)

Comments

Vincent Abriou Sept. 15, 2016, 3:29 p.m. UTC | #1
Acked-by: Vincent Abriou <vincent.abriou@st.com>


On 09/15/2016 03:41 PM, Fabien Dessenne wrote:
> crtc_atomic_flush performs some additional processing, like plane
> enable at mixer level.
> Enable only the planes attached to the CRTC.
>
> Signed-off-by: Fabien Dessenne <fabien.dessenne@st.com>
> ---
>  drivers/gpu/drm/sti/sti_crtc.c | 4 ++++
>  1 file changed, 4 insertions(+)
>
> diff --git a/drivers/gpu/drm/sti/sti_crtc.c b/drivers/gpu/drm/sti/sti_crtc.c
> index 96afe68..bc1b186 100644
> --- a/drivers/gpu/drm/sti/sti_crtc.c
> +++ b/drivers/gpu/drm/sti/sti_crtc.c
> @@ -165,6 +165,10 @@ static void sti_crtc_atomic_flush(struct drm_crtc *crtc,
>
>  		switch (plane->status) {
>  		case STI_PLANE_UPDATED:
> +			/* ignore update for other CRTC */
> +			if (p->state->crtc != crtc)
> +				continue;
> +
>  			/* update planes tag as updated */
>  			DRM_DEBUG_DRIVER("update plane %s\n",
>  					 sti_plane_to_str(plane));
>
diff mbox

Patch

diff --git a/drivers/gpu/drm/sti/sti_crtc.c b/drivers/gpu/drm/sti/sti_crtc.c
index 96afe68..bc1b186 100644
--- a/drivers/gpu/drm/sti/sti_crtc.c
+++ b/drivers/gpu/drm/sti/sti_crtc.c
@@ -165,6 +165,10 @@  static void sti_crtc_atomic_flush(struct drm_crtc *crtc,
 
 		switch (plane->status) {
 		case STI_PLANE_UPDATED:
+			/* ignore update for other CRTC */
+			if (p->state->crtc != crtc)
+				continue;
+
 			/* update planes tag as updated */
 			DRM_DEBUG_DRIVER("update plane %s\n",
 					 sti_plane_to_str(plane));