aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/i915_reg.h
diff options
context:
space:
mode:
authorPaulo Zanoni <paulo.r.zanoni@intel.com>2013-04-12 16:57:57 -0400
committerDaniel Vetter <daniel.vetter@ffwll.ch>2013-04-19 03:33:11 -0400
commit8664281b64c457705db72fc60143d03827e75ca9 (patch)
treeafe46a87c518c13636a05c25744e3b1f49c0aeec /drivers/gpu/drm/i915/i915_reg.h
parent89b667f86a62a99a7b484a7e1b3f8f7a108a7dee (diff)
drm/i915: report Gen5+ CPU and PCH FIFO underruns
In this commit we enable both CPU and PCH FIFO underrun reporting and start reporting them. We follow a few rules: - after we receive one of these errors, we mask the interrupt, so we won't get an "interrupt storm" and we also won't flood dmesg; - at each mode set we enable the interrupts again, so we'll see each message at most once per mode set; - in the specific places where we need to ignore the errors, we completely mask the interrupts. The downside of this patch is that since we're completely disabling (masking) the interrupts instead of just not printing error messages, we will mask more than just what we want on IVB/HSW CPU interrupts (due to GEN7_ERR_INT) and on CPT/PPT/LPT PCHs (due to SERR_INT). So when we decide to mask PCH FIFO underruns for pipe A on CPT, we'll also be masking PCH FIFO underruns for pipe B, because both are reported by SERR_INT, which has to be either completely enabled or completely disabled (in othe words, there's no way to disable/enable specific bits of GEN7_ERR_INT and SERR_INT). V2: Rename some functions and variables, downgrade messages to DRM_DEBUG_DRIVER and rebase. Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com> Reviewed-by: Imre Deak <imre.deak@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/i915/i915_reg.h')
-rw-r--r--drivers/gpu/drm/i915/i915_reg.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h
index fb1a4fa68d55..32f970d2fd51 100644
--- a/drivers/gpu/drm/i915/i915_reg.h
+++ b/drivers/gpu/drm/i915/i915_reg.h
@@ -640,7 +640,10 @@
640 640
641#define ERROR_GEN6 0x040a0 641#define ERROR_GEN6 0x040a0
642#define GEN7_ERR_INT 0x44040 642#define GEN7_ERR_INT 0x44040
643#define ERR_INT_MMIO_UNCLAIMED (1<<13) 643#define ERR_INT_MMIO_UNCLAIMED (1<<13)
644#define ERR_INT_FIFO_UNDERRUN_C (1<<6)
645#define ERR_INT_FIFO_UNDERRUN_B (1<<3)
646#define ERR_INT_FIFO_UNDERRUN_A (1<<0)
644 647
645#define FPGA_DBG 0x42300 648#define FPGA_DBG 0x42300
646#define FPGA_DBG_RM_NOCLAIM (1<<31) 649#define FPGA_DBG_RM_NOCLAIM (1<<31)
@@ -3622,7 +3625,7 @@
3622#define DE_PIPEA_FIFO_UNDERRUN (1 << 0) 3625#define DE_PIPEA_FIFO_UNDERRUN (1 << 0)
3623 3626
3624/* More Ivybridge lolz */ 3627/* More Ivybridge lolz */
3625#define DE_ERR_DEBUG_IVB (1<<30) 3628#define DE_ERR_INT_IVB (1<<30)
3626#define DE_GSE_IVB (1<<29) 3629#define DE_GSE_IVB (1<<29)
3627#define DE_PCH_EVENT_IVB (1<<28) 3630#define DE_PCH_EVENT_IVB (1<<28)
3628#define DE_DP_A_HOTPLUG_IVB (1<<27) 3631#define DE_DP_A_HOTPLUG_IVB (1<<27)
@@ -3781,6 +3784,7 @@
3781 SDE_PORTC_HOTPLUG_CPT | \ 3784 SDE_PORTC_HOTPLUG_CPT | \
3782 SDE_PORTB_HOTPLUG_CPT) 3785 SDE_PORTB_HOTPLUG_CPT)
3783#define SDE_GMBUS_CPT (1 << 17) 3786#define SDE_GMBUS_CPT (1 << 17)
3787#define SDE_ERROR_CPT (1 << 16)
3784#define SDE_AUDIO_CP_REQ_C_CPT (1 << 10) 3788#define SDE_AUDIO_CP_REQ_C_CPT (1 << 10)
3785#define SDE_AUDIO_CP_CHG_C_CPT (1 << 9) 3789#define SDE_AUDIO_CP_CHG_C_CPT (1 << 9)
3786#define SDE_FDI_RXC_CPT (1 << 8) 3790#define SDE_FDI_RXC_CPT (1 << 8)
@@ -3805,6 +3809,11 @@
3805#define SDEIIR 0xc4008 3809#define SDEIIR 0xc4008
3806#define SDEIER 0xc400c 3810#define SDEIER 0xc400c
3807 3811
3812#define SERR_INT 0xc4040
3813#define SERR_INT_TRANS_C_FIFO_UNDERRUN (1<<6)
3814#define SERR_INT_TRANS_B_FIFO_UNDERRUN (1<<3)
3815#define SERR_INT_TRANS_A_FIFO_UNDERRUN (1<<0)
3816
3808/* digital port hotplug */ 3817/* digital port hotplug */
3809#define PCH_PORT_HOTPLUG 0xc4030 /* SHOTPLUG_CTL */ 3818#define PCH_PORT_HOTPLUG 0xc4030 /* SHOTPLUG_CTL */
3810#define PORTD_HOTPLUG_ENABLE (1 << 20) 3819#define PORTD_HOTPLUG_ENABLE (1 << 20)