From: Jason Wessel Date: Thu, 5 Aug 2010 14:22:32 +0000 (-0500) Subject: i915: when kgdb is active display compression should be off X-Git-Tag: firefly_0821_release~9833^2~1276^2~2 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=c924b934d0cd14a4559611da91f28f59acebe32a;hp=81255565dbf5958187bdb6cc4e3aa0db9ce4d237;p=firefly-linux-kernel-4.4.55.git i915: when kgdb is active display compression should be off If the HW compression is left on, the call backs from the HW will crash the kernel. The only time this code is called is when kernel mode setting is in use with kgdb and the kdb shell. The atomic display pipe handler callback will reset everything when kgdb restores kernel to the run state. Signed-off-by: Jason Wessel Acked-by: Jesse Barnes CC: David Airlie --- diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index eff28e5de4dc..714bf539918b 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c @@ -1251,6 +1251,10 @@ static void intel_update_fbc(struct drm_crtc *crtc, goto out_disable; } + /* If the kernel debugger is active, always disable compression */ + if (in_dbg_master()) + goto out_disable; + if (intel_fbc_enabled(dev)) { /* We can re-enable it in this case, but need to update pitch */ if ((fb->pitch > dev_priv->cfb_pitch) ||