drm/i915: disable sdvo pixel multiplier cross-check for HAS_PCH_SPLIT
Subsystems (2)
PATCH 1/1 drm/i915: disable sdvo pixel multiplier cross-check for HAS_PCH_SPLIT
We don't (yet) have proper pixel multiplier readout support on pch split platforms, so the cross check will naturally fail.
--- drivers/gpu/drm/i915/intel_sdvo.c | 4 ++++ 1 file changed, 4 insertions(+)
drivers/gpu/drm/i915/intel_sdvo.c +4 -0
@@ -1362,6 +1362,10 @@ static void intel_sdvo_get_config(struct intel_encoder *encoder, encoder_pixel_multiplier =4 ;break ; } + +if (HAS_PCH_SPLIT (dev)) +return ;/* no pixel mutlierplier readout support yet */ +WARN (encoder_pixel_multiplier != pipe_config->pixel_multiplier,"SDVO pixel multiplier mismatch, port: %i, encoder: %i\n" , pipe_config->pixel_multiplier, encoder_pixel_multiplier);
Signature · 1 line
1.7.11.7
Quoted 15 lines · Daniel Vetter
We don't (yet) have proper pixel multiplier readout support on pch split platforms, so the cross check will naturally fail.
Reported-by Chris Wilson <[email protected]>Cc Chris Wilson <[email protected]>Signed-off-by Daniel Vetter <[email protected]>--- drivers/gpu/drm/i915/intel_sdvo.c | 4 ++++ 1 file changed, 4 insertions(+)drivers/gpu/drm/i915/intel_sdvo.c +0
-0
drivers/gpu/drm/i915/intel_sdvo.c static void intel_sdvo_get_config(struct intel_encoder *encoder, · line 1367
Quoted 6 lines
drivers/gpu/drm/i915/intel_sdvo.c +3
-0@@ -1362,6 +1362,10 @@ static void intel_sdvo_get_config(struct intel_encoder *encoder, encoder_pixel_multiplier =4 ;break ; } + +if (HAS_PCH_SPLIT (dev)) +return ;/* no pixel mutlierplier readout support yet */
^^^^^^^^^^^^
Quoted 11 lines
drivers/gpu/drm/i915/intel_sdvo.c +1
-0+WARN (encoder_pixel_multiplier != pipe_config->pixel_multiplier,"SDVO pixel multiplier mismatch, port: %i, encoder: %i\n" , pipe_config->pixel_multiplier, encoder_pixel_multiplier);Signature · 6 lines
1.7.11.7 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Signature · 2 lines
Ville Syrjälä Intel OTC
PATCH 1/1 drm/i915: disable sdvo pixel multiplier cross-check for HAS_PCH_SPLIT
We don't (yet) have proper pixel multiplier readout support on pch split platforms, so the cross check will naturally fail.
v2: Fix spelling in the comment, spotted by Ville.
--- drivers/gpu/drm/i915/intel_sdvo.c | 4 ++++ 1 file changed, 4 insertions(+)
drivers/gpu/drm/i915/intel_sdvo.c +4 -0
@@ -1362,6 +1362,10 @@ static void intel_sdvo_get_config(struct intel_encoder *encoder, encoder_pixel_multiplier =4 ;break ; } + +if (HAS_PCH_SPLIT (dev)) +return ;/* no pixel multiplier readout support yet */ +WARN (encoder_pixel_multiplier != pipe_config->pixel_multiplier,"SDVO pixel multiplier mismatch, port: %i, encoder: %i\n" , pipe_config->pixel_multiplier, encoder_pixel_multiplier);
Signature · 6 lines
1.7.11.7 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH 1/1 drm/i915: disable sdvo pixel multiplier cross-check for HAS_PCH_SPLIT
We don't (yet) have proper pixel multiplier readout support on pch split platforms, so the cross check will naturally fail.
v2: Fix spelling in the comment, spotted by Ville.
v3: Since the ordering constraint is pretty tricky between the crtc get_pipe_config callback and the encoder->get_config callback add a few comments about it. Prompted by a discussion with Chris Wilson on irc about why this does work anywhere else than on i915g/gm.
--- drivers/gpu/drm/i915/intel_drv.h | 3 ++- drivers/gpu/drm/i915/intel_sdvo.c | 11 +++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-)
drivers/gpu/drm/i915/intel_drv.h +2 -1
@@ -140,7 +140,8 @@ struct intel_encoder {* it is connected to in the pipe parameter. */ bool (*get_hw_state)(struct intel_encoder *,enum pipe *pipe);/* Reconstructs the equivalent mode flags for the current hardware -* state. */ +* state. This must be called _after_ display->get_pipe_config has +* pre-filled the pipe config. */ void (*get_config)(struct intel_encoder *,struct intel_crtc_config *pipe_config);int crtc_mask;
drivers/gpu/drm/i915/intel_sdvo.c +11 -0
@@ -1342,6 +1342,13 @@ static void intel_sdvo_get_config(struct intel_encoder *encoder, pipe_config->adjusted_mode.flags |= flags; +/* +* pixel multiplier readout is tricky: Only on i915g/gm it is stored in +* the sdvo port register, on all other platforms it is part of the dpll +* state. Since the general pipe state readout happens before the +* encoder->get_config we so already have a valid pixel multplier on all +* other platfroms. +*/ if (IS_I915G (dev) ||IS_I915GM (dev)) { sdvox =I915_READ (intel_sdvo->sdvo_reg); pipe_config->pixel_multiplier =
@@ -1362,6 +1369,10 @@ static void intel_sdvo_get_config(struct intel_encoder *encoder, encoder_pixel_multiplier =4 ;break ; } + +if (HAS_PCH_SPLIT (dev)) +return ;/* no pixel multiplier readout support yet */ +WARN (encoder_pixel_multiplier != pipe_config->pixel_multiplier,"SDVO pixel multiplier mismatch, port: %i, encoder: %i\n" , pipe_config->pixel_multiplier, encoder_pixel_multiplier);
Signature · 6 lines
1.7.11.7 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 10 lines · Daniel Vetter
We don't (yet) have proper pixel multiplier readout support on pch split platforms, so the cross check will naturally fail.
v2: Fix spelling in the comment, spotted by Ville.
v3: Since the ordering constraint is pretty tricky between the crtc
get_pipe_configcallback and theencoder->get_configcallback add a few comments about it. Prompted by a discussion with Chris Wilson on irc about why this does work anywhere else than on i915g/gm.
Quoted 4 lines
Reported-by Chris Wilson <[email protected]>Cc Chris Wilson <[email protected]>Cc Ville Syrjälä <[email protected]>Signed-off-by Daniel Vetter <[email protected]>
Merged with Chris' irc-ack to dinq.
-Daniel
Quoted 51 lines
--- drivers/gpu/drm/i915/intel_drv.h | 3 ++- drivers/gpu/drm/i915/intel_sdvo.c | 11 +++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-)drivers/gpu/drm/i915/intel_drv.h +2
-1@@ -140,7 +140,8 @@ struct intel_encoder {* it is connected to in the pipe parameter. */ bool (*get_hw_state)(struct intel_encoder *,enum pipe *pipe);/* Reconstructs the equivalent mode flags for the current hardware -* state. */ +* state. This must be called _after_ display->get_pipe_config has +* pre-filled the pipe config. */ void (*get_config)(struct intel_encoder *,struct intel_crtc_config *pipe_config);int crtc_mask;drivers/gpu/drm/i915/intel_sdvo.c +11
-0@@ -1342,6 +1342,13 @@ static void intel_sdvo_get_config(struct intel_encoder *encoder, pipe_config->adjusted_mode.flags |= flags; +/* +* pixel multiplier readout is tricky: Only on i915g/gm it is stored in +* the sdvo port register, on all other platforms it is part of the dpll +* state. Since the general pipe state readout happens before the +* encoder->get_config we so already have a valid pixel multplier on all +* other platfroms. +*/ if (IS_I915G (dev) ||IS_I915GM (dev)) { sdvox =I915_READ (intel_sdvo->sdvo_reg); pipe_config->pixel_multiplier =@@ -1362,6 +1369,10 @@ static void intel_sdvo_get_config(struct intel_encoder *encoder, encoder_pixel_multiplier =4 ;break ; } + +if (HAS_PCH_SPLIT (dev)) +return ;/* no pixel multiplier readout support yet */ +WARN (encoder_pixel_multiplier != pipe_config->pixel_multiplier,"SDVO pixel multiplier mismatch, port: %i, encoder: %i\n" , pipe_config->pixel_multiplier, encoder_pixel_multiplier);Signature · 1 line
1.7.11.7
Signature · 3 lines
Daniel Vetter Software Engineer, Intel Corporation +41 (0) 79 365 57 48 - http://blog.ffwll.ch