drm/i915: enable error detection & state collection
This patch enables error detection by enabling several types of error interrupts. When an error interrupt is received, the interrupt handler captures the error state; hopefully resulting in an accurate set of error data (error type, active head pointer, etc.). The new record is then available from sysfs. The current code will also dump the error state to the system log. Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org> Signed-off-by: Eric Anholt <eric@anholt.net>
This commit is contained in:
committed by
Eric Anholt
parent
e83c2b0ff3
commit
63eeaf3825
@@ -133,6 +133,22 @@ struct sdvo_device_mapping {
|
||||
u8 initialized;
|
||||
};
|
||||
|
||||
struct drm_i915_error_state {
|
||||
u32 eir;
|
||||
u32 pgtbl_er;
|
||||
u32 pipeastat;
|
||||
u32 pipebstat;
|
||||
u32 ipeir;
|
||||
u32 ipehr;
|
||||
u32 instdone;
|
||||
u32 acthd;
|
||||
u32 instpm;
|
||||
u32 instps;
|
||||
u32 instdone1;
|
||||
u32 seqno;
|
||||
struct timeval time;
|
||||
};
|
||||
|
||||
typedef struct drm_i915_private {
|
||||
struct drm_device *dev;
|
||||
|
||||
@@ -209,6 +225,9 @@ typedef struct drm_i915_private {
|
||||
int fence_reg_start; /* 4 if userland hasn't ioctl'd us yet */
|
||||
int num_fence_regs; /* 8 on pre-965, 16 otherwise */
|
||||
|
||||
spinlock_t error_lock;
|
||||
struct drm_i915_error_state *first_error;
|
||||
|
||||
/* Register state */
|
||||
u8 saveLBB;
|
||||
u32 saveDSPACNTR;
|
||||
|
Reference in New Issue
Block a user