From: Ander Conselvan de Oliveira Date: Thu, 2 Apr 2015 11:48:01 +0000 (+0300) Subject: drm/i915: Don't use staged config in intel_mst_pre_enable_dp() X-Git-Tag: v5.15~15474^2~58^2~138 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9b4fd8f250e08d8f22a31d947ac3ca16383df1e1;p=platform%2Fkernel%2Flinux-starfive.git drm/i915: Don't use staged config in intel_mst_pre_enable_dp() For the conversion to atomic. The pre_enable() hooks are called as part of the crtc enable sequence, at which point the staged config was already made effective. Furthermore, the function actually changes hardware state, so it should anyway deal with current and not staged config. Signed-off-by: Ander Conselvan de Oliveira Signed-off-by: Daniel Vetter --- diff --git a/drivers/gpu/drm/i915/intel_dp_mst.c b/drivers/gpu/drm/i915/intel_dp_mst.c index 5329c85..adcc5e6 100644 --- a/drivers/gpu/drm/i915/intel_dp_mst.c +++ b/drivers/gpu/drm/i915/intel_dp_mst.c @@ -150,14 +150,14 @@ static void intel_mst_pre_enable_dp(struct intel_encoder *encoder) enum port port = intel_dig_port->port; int ret; uint32_t temp; - struct intel_connector *found = NULL, *intel_connector; + struct intel_connector *found = NULL, *connector; int slots; struct drm_crtc *crtc = encoder->base.crtc; struct intel_crtc *intel_crtc = to_intel_crtc(crtc); - for_each_intel_connector(dev, intel_connector) { - if (intel_connector->new_encoder == encoder) { - found = intel_connector; + for_each_intel_connector(dev, connector) { + if (connector->base.state->best_encoder == &encoder->base) { + found = connector; break; } }