aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEgbert Eich <eich@suse.de>2014-07-07 12:20:34 -0400
committerDaniel Vetter <daniel.vetter@ffwll.ch>2014-07-07 12:29:27 -0400
commita7de62fe94deda8339c72d03ffd4bd5586aa20cb (patch)
treee6812501866337fa917365d284249229a96be675
parent0eaa53f021847eec5b759843e0cb195322c26896 (diff)
DRM/i915: Remove magic to prevent blank screen on gen4 chipsets
Since the root cause is understood now and with the fix commit 564ed191f5d816d24501664296991ec70327e2bc Author: Imre Deak <imre.deak@intel.com> Date: Fri Jun 13 14:54:21 2014 +0300 drm/i915: gmch: fix stuck primary plane due to memory self-refresh mode in place the magic for G4x chipsets introduced with commit commit 61bc95c1fbbb6a08b55bbe161fdf1ea5493fc595 Author: Egbert Eich <eich@suse.com> Date: Mon Mar 4 09:24:38 2013 -0500 DRM/i915: On G45 enable cursor plane briefly after enabling the display plane. to avoided occasional screen blanking on mode changes can finally be removed. It's been verified that Imre's fix also resolves the said issue. Signed-off-by: Egbert Eich <eich@suse.de> Tested-by: Stefan Dirsch <sndirsch@suse.de> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
-rw-r--r--drivers/gpu/drm/i915/intel_display.c27
1 files changed, 0 insertions, 27 deletions
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index 74b8b388773a..b961122ad515 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -3894,30 +3894,6 @@ static void intel_crtc_dpms_overlay(struct intel_crtc *intel_crtc, bool enable)
3894 */ 3894 */
3895} 3895}
3896 3896
3897/**
3898 * i9xx_fixup_plane - ugly workaround for G45 to fire up the hardware
3899 * cursor plane briefly if not already running after enabling the display
3900 * plane.
3901 * This workaround avoids occasional blank screens when self refresh is
3902 * enabled.
3903 */
3904static void
3905g4x_fixup_plane(struct drm_i915_private *dev_priv, enum pipe pipe)
3906{
3907 u32 cntl = I915_READ(CURCNTR(pipe));
3908
3909 if ((cntl & CURSOR_MODE) == 0) {
3910 u32 fw_bcl_self = I915_READ(FW_BLC_SELF);
3911
3912 I915_WRITE(FW_BLC_SELF, fw_bcl_self & ~FW_BLC_SELF_EN);
3913 I915_WRITE(CURCNTR(pipe), CURSOR_MODE_64_ARGB_AX);
3914 intel_wait_for_vblank(dev_priv->dev, pipe);
3915 I915_WRITE(CURCNTR(pipe), cntl);
3916 I915_WRITE(CURBASE(pipe), I915_READ(CURBASE(pipe)));
3917 I915_WRITE(FW_BLC_SELF, fw_bcl_self);
3918 }
3919}
3920
3921static void intel_crtc_enable_planes(struct drm_crtc *crtc) 3897static void intel_crtc_enable_planes(struct drm_crtc *crtc)
3922{ 3898{
3923 struct drm_device *dev = crtc->dev; 3899 struct drm_device *dev = crtc->dev;
@@ -3930,9 +3906,6 @@ static void intel_crtc_enable_planes(struct drm_crtc *crtc)
3930 3906
3931 intel_enable_primary_hw_plane(dev_priv, plane, pipe); 3907 intel_enable_primary_hw_plane(dev_priv, plane, pipe);
3932 intel_enable_planes(crtc); 3908 intel_enable_planes(crtc);
3933 /* The fixup needs to happen before cursor is enabled */
3934 if (IS_G4X(dev))
3935 g4x_fixup_plane(dev_priv, pipe);
3936 intel_crtc_update_cursor(crtc, true); 3909 intel_crtc_update_cursor(crtc, true);
3937 intel_crtc_dpms_overlay(intel_crtc, true); 3910 intel_crtc_dpms_overlay(intel_crtc, true);
3938 3911