aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHette Visser <hettevisser@gmail.com>2010-09-24 05:51:30 -0400
committerChris Wilson <chris@chris-wilson.co.uk>2010-09-24 09:22:13 -0400
commit27d64339a8d8465484286a2da93f5f6c36be5c3d (patch)
tree2e91c2660fda807d2732a7fbb275e765a72a64db
parente61cb0d5fd172ab95a4501917526382f25158e83 (diff)
drm/i915/dp: Wait for PP_CONTROL to take effect.
This patch fixes the black screen bug on Dell e6510, by adding two delays to give the eDP panel time to turn on before we continue with the next write. 300ms is rather arbitray and a rather long sleep, we need to find a way of refining this value. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=29278 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Jesse Barnes <jbarnes@virtuousgeek.org>
-rw-r--r--drivers/gpu/drm/i915/intel_dp.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
index 117eb9988250..d19334aa66ad 100644
--- a/drivers/gpu/drm/i915/intel_dp.c
+++ b/drivers/gpu/drm/i915/intel_dp.c
@@ -784,6 +784,11 @@ static bool ironlake_edp_panel_on (struct drm_device *dev)
784 pp |= POWER_TARGET_ON; 784 pp |= POWER_TARGET_ON;
785 I915_WRITE(PCH_PP_CONTROL, pp); 785 I915_WRITE(PCH_PP_CONTROL, pp);
786 786
787 /* Ouch. We need to wait here for some panels, like Dell e6510
788 * https://bugs.freedesktop.org/show_bug.cgi?id=29278i
789 */
790 msleep(300);
791
787 if (wait_for(I915_READ(PCH_PP_STATUS) & PP_ON, 5000)) 792 if (wait_for(I915_READ(PCH_PP_STATUS) & PP_ON, 5000))
788 DRM_ERROR("panel on wait timed out: 0x%08x\n", 793 DRM_ERROR("panel on wait timed out: 0x%08x\n",
789 I915_READ(PCH_PP_STATUS)); 794 I915_READ(PCH_PP_STATUS));
@@ -819,6 +824,11 @@ static void ironlake_edp_panel_off (struct drm_device *dev)
819 pp |= PANEL_POWER_RESET; /* restore panel reset bit */ 824 pp |= PANEL_POWER_RESET; /* restore panel reset bit */
820 I915_WRITE(PCH_PP_CONTROL, pp); 825 I915_WRITE(PCH_PP_CONTROL, pp);
821 POSTING_READ(PCH_PP_CONTROL); 826 POSTING_READ(PCH_PP_CONTROL);
827
828 /* Ouch. We need to wait here for some panels, like Dell e6510
829 * https://bugs.freedesktop.org/show_bug.cgi?id=29278i
830 */
831 msleep(300);
822} 832}
823 833
824static void ironlake_edp_panel_vdd_on(struct drm_device *dev) 834static void ironlake_edp_panel_vdd_on(struct drm_device *dev)