Explorar o código

drm/i915: disable hotplug detect before Ironlake CRT detect

This tries to fix CRT detect loop hang seen on some Ironlake form
factor, to clear up hotplug detect state before taking CRT detect
to make sure next hotplug detect cycle is consistent.

Cc: Stable Team <stable@kernel.org>
Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
Signed-off-by: Eric Anholt <eric@anholt.net>
Zhenyu Wang %!s(int64=15) %!d(string=hai) anos
pai
achega
eceb784cec
Modificáronse 1 ficheiros con 3 adicións e 0 borrados
  1. 3 0
      drivers/gpu/drm/i915/intel_crt.c

+ 3 - 0
drivers/gpu/drm/i915/intel_crt.c

@@ -157,6 +157,9 @@ static bool intel_ironlake_crt_detect_hotplug(struct drm_connector *connector)
 	adpa = I915_READ(PCH_ADPA);
 	adpa = I915_READ(PCH_ADPA);
 
 
 	adpa &= ~ADPA_CRT_HOTPLUG_MASK;
 	adpa &= ~ADPA_CRT_HOTPLUG_MASK;
+	/* disable HPD first */
+	I915_WRITE(PCH_ADPA, adpa);
+	(void)I915_READ(PCH_ADPA);
 
 
 	adpa |= (ADPA_CRT_HOTPLUG_PERIOD_128 |
 	adpa |= (ADPA_CRT_HOTPLUG_PERIOD_128 |
 			ADPA_CRT_HOTPLUG_WARMUP_10MS |
 			ADPA_CRT_HOTPLUG_WARMUP_10MS |