From ee0daffed45d88405abfe04c8a14b031f4bf914f Mon Sep 17 00:00:00 2001 From: Alban Browaeys Date: Thu, 5 Jan 2012 21:39:47 +0100 Subject: [PATCH] drm/i915: check intel_crtc active before loading lut. Before loading lut check the active state of intel_crtc. Otherwise at least on i965g gen2 hang ensue. This is reproducible in Xorg via: xset dpms force off then xgamma -rgamma 2.0 (freeze). --- drivers/gpu/drm/i915/intel_display.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index 7eaea5a..6f58477 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c @@ -6006,7 +6006,7 @@ void intel_crtc_load_lut(struct drm_crtc *crtc) int i; /* The clocks have to be on to load the palette. */ - if (!crtc->enabled) + if (!crtc->enabled || !intel_crtc->active) return; /* use legacy palette for Ironlake */ -- 1.7.8.2