]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
drm/i915: Use adjusted_mode in the fastboot hack to disable pfit
authorDamien Lespiau <damien.lespiau@intel.com>
Mon, 30 Sep 2013 13:21:50 +0000 (14:21 +0100)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Fri, 4 Oct 2013 08:32:17 +0000 (10:32 +0200)
When booting with i915.fastboot=1, we always take tha code path and end
up undoing what we're trying to do with adjusted_mode.

Hopefully, as the fastboot hardware readout code is using adjusted_mode
as well, it should be equivalent.

Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/intel_display.c

index fe863255dedcdb1fd2d20ff4ae7a96087c75aeb7..617b963dfb67f230bbabdaf8a66f613592bacd88 100644 (file)
@@ -2334,9 +2334,12 @@ intel_pipe_set_base(struct drm_crtc *crtc, int x, int y,
         * then update the pipesrc and pfit state, even on the flip path.
         */
        if (i915_fastboot) {
+               const struct drm_display_mode *adjusted_mode =
+                       &intel_crtc->config.adjusted_mode;
+
                I915_WRITE(PIPESRC(intel_crtc->pipe),
-                          ((crtc->mode.hdisplay - 1) << 16) |
-                          (crtc->mode.vdisplay - 1));
+                          ((adjusted_mode->crtc_hdisplay - 1) << 16) |
+                          (adjusted_mode->crtc_vdisplay - 1));
                if (!intel_crtc->config.pch_pfit.enabled &&
                    (intel_pipe_has_type(crtc, INTEL_OUTPUT_LVDS) ||
                     intel_pipe_has_type(crtc, INTEL_OUTPUT_EDP))) {