diff options
author | Daniel Vetter <daniel.vetter@ffwll.ch> | 2013-07-21 15:36:59 -0400 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2013-08-04 15:25:20 -0400 |
commit | efea6e8e49388478be405b3ae62644ef06dca9a1 (patch) | |
tree | fd2f9548a86f3495999dd45815333ce36859c0a1 /drivers/gpu/drm/i915/intel_display.c | |
parent | a34703752e0b682ab4e6fccf1ce675176cf1dad2 (diff) |
drm/i915: rip out legacy encoder->mode_fixup logic
Everyone is now using our own ->compute_config callback, which means
we can now also make that callback mandatory.
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@gmail.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/i915/intel_display.c')
-rw-r--r-- | drivers/gpu/drm/i915/intel_display.c | 19 |
1 files changed, 3 insertions, 16 deletions
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index 3e66f05ea342..e9120843a9d7 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c | |||
@@ -4109,7 +4109,7 @@ static int intel_crtc_compute_config(struct intel_crtc *crtc, | |||
4109 | } | 4109 | } |
4110 | 4110 | ||
4111 | /* All interlaced capable intel hw wants timings in frames. Note though | 4111 | /* All interlaced capable intel hw wants timings in frames. Note though |
4112 | * that intel_lvds_mode_fixup does some funny tricks with the crtc | 4112 | * that intel_lvds_compute_config does some funny tricks with the crtc |
4113 | * timings, so we need to be careful not to clobber these.*/ | 4113 | * timings, so we need to be careful not to clobber these.*/ |
4114 | if (!pipe_config->timings_set) | 4114 | if (!pipe_config->timings_set) |
4115 | drm_mode_set_crtcinfo(adjusted_mode, 0); | 4115 | drm_mode_set_crtcinfo(adjusted_mode, 0); |
@@ -8061,7 +8061,6 @@ intel_modeset_pipe_config(struct drm_crtc *crtc, | |||
8061 | struct drm_display_mode *mode) | 8061 | struct drm_display_mode *mode) |
8062 | { | 8062 | { |
8063 | struct drm_device *dev = crtc->dev; | 8063 | struct drm_device *dev = crtc->dev; |
8064 | struct drm_encoder_helper_funcs *encoder_funcs; | ||
8065 | struct intel_encoder *encoder; | 8064 | struct intel_encoder *encoder; |
8066 | struct intel_crtc_config *pipe_config; | 8065 | struct intel_crtc_config *pipe_config; |
8067 | int plane_bpp, ret = -EINVAL; | 8066 | int plane_bpp, ret = -EINVAL; |
@@ -8106,20 +8105,8 @@ encoder_retry: | |||
8106 | if (&encoder->new_crtc->base != crtc) | 8105 | if (&encoder->new_crtc->base != crtc) |
8107 | continue; | 8106 | continue; |
8108 | 8107 | ||
8109 | if (encoder->compute_config) { | 8108 | if (!(encoder->compute_config(encoder, pipe_config))) { |
8110 | if (!(encoder->compute_config(encoder, pipe_config))) { | 8109 | DRM_DEBUG_KMS("Encoder config failure\n"); |
8111 | DRM_DEBUG_KMS("Encoder config failure\n"); | ||
8112 | goto fail; | ||
8113 | } | ||
8114 | |||
8115 | continue; | ||
8116 | } | ||
8117 | |||
8118 | encoder_funcs = encoder->base.helper_private; | ||
8119 | if (!(encoder_funcs->mode_fixup(&encoder->base, | ||
8120 | &pipe_config->requested_mode, | ||
8121 | &pipe_config->adjusted_mode))) { | ||
8122 | DRM_DEBUG_KMS("Encoder fixup failed\n"); | ||
8123 | goto fail; | 8110 | goto fail; |
8124 | } | 8111 | } |
8125 | } | 8112 | } |