From: Brian Starkey <brian.starkey@arm.com>
To: airlied@linux.ie
Cc: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org,
Liviu.Dudau@arm.com
Subject: [PATCH] drm/atomic: mode_set encoders when routing changes
Date: Tue, 6 Sep 2016 16:12:36 +0100 [thread overview]
Message-ID: <1473174756-14517-1-git-send-email-brian.starkey@arm.com> (raw)
crtc_set_mode() only checks if the CRTC mode has changed when deciding
whether encoders require a mode_set. This is insufficient when the CRTC
mode isn't changed but a new encoder is added to it, leading to encoders
never getting mode_set.
Fix this by also checking that a connector's CRTC and encoder have not
changed before skipping its encoder's mode_set.
Signed-off-by: Brian Starkey <brian.starkey@arm.com>
---
drivers/gpu/drm/drm_atomic_helper.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/drm_atomic_helper.c b/drivers/gpu/drm/drm_atomic_helper.c
index 20be86d..206fba1 100644
--- a/drivers/gpu/drm/drm_atomic_helper.c
+++ b/drivers/gpu/drm/drm_atomic_helper.c
@@ -876,7 +876,9 @@ crtc_set_mode(struct drm_device *dev, struct drm_atomic_state *old_state)
mode = &new_crtc_state->mode;
adjusted_mode = &new_crtc_state->adjusted_mode;
- if (!new_crtc_state->mode_changed)
+ if (!new_crtc_state->mode_changed &&
+ connector->state->crtc == old_conn_state->crtc &&
+ connector->state->best_encoder == old_conn_state->best_encoder)
continue;
DRM_DEBUG_ATOMIC("modeset on [ENCODER:%d:%s]\n",
--
1.7.9.5
reply other threads:[~2016-09-06 15:12 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1473174756-14517-1-git-send-email-brian.starkey@arm.com \
--to=brian.starkey@arm.com \
--cc=Liviu.Dudau@arm.com \
--cc=airlied@linux.ie \
--cc=dri-devel@lists.freedesktop.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®