aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/gpu/drm/i915/i915_debugfs.c19
-rw-r--r--drivers/gpu/drm/i915/i915_drv.h7
-rw-r--r--drivers/gpu/drm/i915/i915_irq.c7
-rw-r--r--drivers/gpu/drm/i915/i915_reg.h4
4 files changed, 30 insertions, 7 deletions
diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c
index ba2af4e046ed..70eec5aceabe 100644
--- a/drivers/gpu/drm/i915/i915_debugfs.c
+++ b/drivers/gpu/drm/i915/i915_debugfs.c
@@ -616,21 +616,28 @@ static int i915_error_state(struct seq_file *m, void *unused)
616 seq_printf(m, "Time: %ld s %ld us\n", error->time.tv_sec, 616 seq_printf(m, "Time: %ld s %ld us\n", error->time.tv_sec,
617 error->time.tv_usec); 617 error->time.tv_usec);
618 seq_printf(m, "PCI ID: 0x%04x\n", dev->pci_device); 618 seq_printf(m, "PCI ID: 0x%04x\n", dev->pci_device);
619 seq_printf(m, "EIR: 0x%08x\n", error->eir);
620 seq_printf(m, "PGTBL_ER: 0x%08x\n", error->pgtbl_er);
619 if (INTEL_INFO(dev)->gen >= 6) { 621 if (INTEL_INFO(dev)->gen >= 6) {
620 seq_printf(m, "ERROR: 0x%08x\n", error->error); 622 seq_printf(m, "ERROR: 0x%08x\n", error->error);
623 seq_printf(m, "Blitter command stream:\n");
624 seq_printf(m, " ACTHD: 0x%08x\n", error->bcs_acthd);
625 seq_printf(m, " IPEHR: 0x%08x\n", error->bcs_ipehr);
626 seq_printf(m, " IPEIR: 0x%08x\n", error->bcs_ipeir);
627 seq_printf(m, " INSTDONE: 0x%08x\n", error->bcs_instdone);
628 seq_printf(m, " seqno: 0x%08x\n", error->bcs_seqno);
621 } 629 }
622 seq_printf(m, "EIR: 0x%08x\n", error->eir); 630 seq_printf(m, "Render command stream:\n");
623 seq_printf(m, " PGTBL_ER: 0x%08x\n", error->pgtbl_er); 631 seq_printf(m, " ACTHD: 0x%08x\n", error->acthd);
624 seq_printf(m, " INSTPM: 0x%08x\n", error->instpm);
625 seq_printf(m, " IPEIR: 0x%08x\n", error->ipeir); 632 seq_printf(m, " IPEIR: 0x%08x\n", error->ipeir);
626 seq_printf(m, " IPEHR: 0x%08x\n", error->ipehr); 633 seq_printf(m, " IPEHR: 0x%08x\n", error->ipehr);
627 seq_printf(m, " INSTDONE: 0x%08x\n", error->instdone); 634 seq_printf(m, " INSTDONE: 0x%08x\n", error->instdone);
628 seq_printf(m, " ACTHD: 0x%08x\n", error->acthd);
629 if (INTEL_INFO(dev)->gen >= 4) { 635 if (INTEL_INFO(dev)->gen >= 4) {
630 seq_printf(m, " INSTPS: 0x%08x\n", error->instps);
631 seq_printf(m, " INSTDONE1: 0x%08x\n", error->instdone1); 636 seq_printf(m, " INSTDONE1: 0x%08x\n", error->instdone1);
637 seq_printf(m, " INSTPS: 0x%08x\n", error->instps);
632 } 638 }
633 seq_printf(m, "seqno: 0x%08x\n", error->seqno); 639 seq_printf(m, " INSTPM: 0x%08x\n", error->instpm);
640 seq_printf(m, " seqno: 0x%08x\n", error->seqno);
634 641
635 if (error->active_bo_count) { 642 if (error->active_bo_count) {
636 seq_printf(m, "Buffers [%d]:\n", error->active_bo_count); 643 seq_printf(m, "Buffers [%d]:\n", error->active_bo_count);
diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
index 7aa7f8abf892..05bff9e6a9cb 100644
--- a/drivers/gpu/drm/i915/i915_drv.h
+++ b/drivers/gpu/drm/i915/i915_drv.h
@@ -142,13 +142,18 @@ struct sdvo_device_mapping {
142struct drm_i915_error_state { 142struct drm_i915_error_state {
143 u32 eir; 143 u32 eir;
144 u32 pgtbl_er; 144 u32 pgtbl_er;
145 u32 error; /* gen6+ */
146 u32 pipeastat; 145 u32 pipeastat;
147 u32 pipebstat; 146 u32 pipebstat;
148 u32 ipeir; 147 u32 ipeir;
149 u32 ipehr; 148 u32 ipehr;
150 u32 instdone; 149 u32 instdone;
151 u32 acthd; 150 u32 acthd;
151 u32 error; /* gen6+ */
152 u32 bcs_acthd; /* gen6+ blt engine */
153 u32 bcs_ipehr;
154 u32 bcs_ipeir;
155 u32 bcs_instdone;
156 u32 bcs_seqno;
152 u32 instpm; 157 u32 instpm;
153 u32 instps; 158 u32 instps;
154 u32 instdone1; 159 u32 instdone1;
diff --git a/drivers/gpu/drm/i915/i915_irq.c b/drivers/gpu/drm/i915/i915_irq.c
index 2a29497a4694..4ff39dee7f1c 100644
--- a/drivers/gpu/drm/i915/i915_irq.c
+++ b/drivers/gpu/drm/i915/i915_irq.c
@@ -595,6 +595,13 @@ static void i915_capture_error_state(struct drm_device *dev)
595 error->error = 0; 595 error->error = 0;
596 if (INTEL_INFO(dev)->gen >= 6) { 596 if (INTEL_INFO(dev)->gen >= 6) {
597 error->error = I915_READ(ERROR_GEN6); 597 error->error = I915_READ(ERROR_GEN6);
598 error->bcs_acthd = I915_READ(BCS_ACTHD);
599 error->bcs_ipehr = I915_READ(BCS_IPEHR);
600 error->bcs_ipeir = I915_READ(BCS_IPEIR);
601 error->bcs_instdone = I915_READ(BCS_INSTDONE);
602 error->bcs_seqno = 0;
603 if (dev_priv->blt_ring.get_seqno)
604 error->bcs_seqno = dev_priv->blt_ring.get_seqno(&dev_priv->blt_ring);
598 } 605 }
599 if (INTEL_INFO(dev)->gen >= 4) { 606 if (INTEL_INFO(dev)->gen >= 4) {
600 error->ipeir = I915_READ(IPEIR_I965); 607 error->ipeir = I915_READ(IPEIR_I965);
diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h
index fc161196da21..b173e5b77f96 100644
--- a/drivers/gpu/drm/i915/i915_reg.h
+++ b/drivers/gpu/drm/i915/i915_reg.h
@@ -305,6 +305,10 @@
305#define INSTDONE 0x02090 305#define INSTDONE 0x02090
306#define NOPID 0x02094 306#define NOPID 0x02094
307#define HWSTAM 0x02098 307#define HWSTAM 0x02098
308#define BCS_INSTDONE 0x2206C
309#define BCS_IPEIR 0x22064
310#define BCS_IPEHR 0x22068
311#define BCS_ACTHD 0x22074
308 312
309#define ERROR_GEN6 0x040a0 313#define ERROR_GEN6 0x040a0
310 314