aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu
diff options
context:
space:
mode:
authorBen Skeggs <bskeggs@redhat.com>2011-03-07 18:57:17 -0500
committerBen Skeggs <bskeggs@redhat.com>2011-03-14 02:32:30 -0400
commit6fdb383e81a644a244299d635de5eb30ed401278 (patch)
tree7414b0d2ec2e55c173c9b7ee0cd542bfd8a0e091 /drivers/gpu
parent312d1d5fe9b832899b02c620c143bc7eb5a3bdb1 (diff)
drm/nv50: check for vm traps on every gr irq
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r--drivers/gpu/drm/nouveau/nouveau_drv.h2
-rw-r--r--drivers/gpu/drm/nouveau/nv04_fifo.c2
-rw-r--r--drivers/gpu/drm/nouveau/nv50_fb.c2
-rw-r--r--drivers/gpu/drm/nouveau/nv50_graph.c3
-rw-r--r--drivers/gpu/drm/nouveau/nv84_crypt.c2
5 files changed, 5 insertions, 6 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_drv.h b/drivers/gpu/drm/nouveau/nouveau_drv.h
index 00aff226397d..8efefed58c15 100644
--- a/drivers/gpu/drm/nouveau/nouveau_drv.h
+++ b/drivers/gpu/drm/nouveau/nouveau_drv.h
@@ -1076,7 +1076,7 @@ extern void nv40_fb_set_tile_region(struct drm_device *dev, int i);
1076/* nv50_fb.c */ 1076/* nv50_fb.c */
1077extern int nv50_fb_init(struct drm_device *); 1077extern int nv50_fb_init(struct drm_device *);
1078extern void nv50_fb_takedown(struct drm_device *); 1078extern void nv50_fb_takedown(struct drm_device *);
1079extern void nv50_fb_vm_trap(struct drm_device *, int display, const char *); 1079extern void nv50_fb_vm_trap(struct drm_device *, int display);
1080 1080
1081/* nvc0_fb.c */ 1081/* nvc0_fb.c */
1082extern int nvc0_fb_init(struct drm_device *); 1082extern int nvc0_fb_init(struct drm_device *);
diff --git a/drivers/gpu/drm/nouveau/nv04_fifo.c b/drivers/gpu/drm/nouveau/nv04_fifo.c
index dfa600c46186..db465a3ee1b2 100644
--- a/drivers/gpu/drm/nouveau/nv04_fifo.c
+++ b/drivers/gpu/drm/nouveau/nv04_fifo.c
@@ -516,7 +516,7 @@ nv04_fifo_isr(struct drm_device *dev)
516 516
517 if (dev_priv->card_type == NV_50) { 517 if (dev_priv->card_type == NV_50) {
518 if (status & 0x00000010) { 518 if (status & 0x00000010) {
519 nv50_fb_vm_trap(dev, 1, "PFIFO_BAR_FAULT"); 519 nv50_fb_vm_trap(dev, nouveau_ratelimit());
520 status &= ~0x00000010; 520 status &= ~0x00000010;
521 nv_wr32(dev, 0x002100, 0x00000010); 521 nv_wr32(dev, 0x002100, 0x00000010);
522 } 522 }
diff --git a/drivers/gpu/drm/nouveau/nv50_fb.c b/drivers/gpu/drm/nouveau/nv50_fb.c
index 705f59743db8..bdd2afe29205 100644
--- a/drivers/gpu/drm/nouveau/nv50_fb.c
+++ b/drivers/gpu/drm/nouveau/nv50_fb.c
@@ -210,7 +210,7 @@ static struct nouveau_enum vm_fault[] = {
210}; 210};
211 211
212void 212void
213nv50_fb_vm_trap(struct drm_device *dev, int display, const char *name) 213nv50_fb_vm_trap(struct drm_device *dev, int display)
214{ 214{
215 struct drm_nouveau_private *dev_priv = dev->dev_private; 215 struct drm_nouveau_private *dev_priv = dev->dev_private;
216 const struct nouveau_enum *en, *cl; 216 const struct nouveau_enum *en, *cl;
diff --git a/drivers/gpu/drm/nouveau/nv50_graph.c b/drivers/gpu/drm/nouveau/nv50_graph.c
index a8be5184477a..8675b00caf18 100644
--- a/drivers/gpu/drm/nouveau/nv50_graph.c
+++ b/drivers/gpu/drm/nouveau/nv50_graph.c
@@ -702,7 +702,6 @@ nv50_pgraph_tp_trap(struct drm_device *dev, int type, uint32_t ustatus_old,
702 tps++; 702 tps++;
703 switch (type) { 703 switch (type) {
704 case 6: /* texture error... unknown for now */ 704 case 6: /* texture error... unknown for now */
705 nv50_fb_vm_trap(dev, display, name);
706 if (display) { 705 if (display) {
707 NV_ERROR(dev, "magic set %d:\n", i); 706 NV_ERROR(dev, "magic set %d:\n", i);
708 for (r = ustatus_addr + 4; r <= ustatus_addr + 0x10; r += 4) 707 for (r = ustatus_addr + 4; r <= ustatus_addr + 0x10; r += 4)
@@ -725,7 +724,6 @@ nv50_pgraph_tp_trap(struct drm_device *dev, int type, uint32_t ustatus_old,
725 uint32_t e1c = nv_rd32(dev, ustatus_addr + 0x14); 724 uint32_t e1c = nv_rd32(dev, ustatus_addr + 0x14);
726 uint32_t e20 = nv_rd32(dev, ustatus_addr + 0x18); 725 uint32_t e20 = nv_rd32(dev, ustatus_addr + 0x18);
727 uint32_t e24 = nv_rd32(dev, ustatus_addr + 0x1c); 726 uint32_t e24 = nv_rd32(dev, ustatus_addr + 0x1c);
728 nv50_fb_vm_trap(dev, display, name);
729 /* 2d engine destination */ 727 /* 2d engine destination */
730 if (ustatus & 0x00000010) { 728 if (ustatus & 0x00000010) {
731 if (display) { 729 if (display) {
@@ -1068,6 +1066,7 @@ nv50_graph_isr(struct drm_device *dev)
1068 NV_INFO(dev, "PGRAPH - ch %d (0x%010llx) subc %d " 1066 NV_INFO(dev, "PGRAPH - ch %d (0x%010llx) subc %d "
1069 "class 0x%04x mthd 0x%04x data 0x%08x\n", 1067 "class 0x%04x mthd 0x%04x data 0x%08x\n",
1070 chid, inst, subc, class, mthd, data); 1068 chid, inst, subc, class, mthd, data);
1069 nv50_fb_vm_trap(dev, 1);
1071 } 1070 }
1072 } 1071 }
1073 1072
diff --git a/drivers/gpu/drm/nouveau/nv84_crypt.c b/drivers/gpu/drm/nouveau/nv84_crypt.c
index ec18ae1c3886..fabc7fd30b1d 100644
--- a/drivers/gpu/drm/nouveau/nv84_crypt.c
+++ b/drivers/gpu/drm/nouveau/nv84_crypt.c
@@ -136,5 +136,5 @@ nv84_crypt_isr(struct drm_device *dev)
136 nv_wr32(dev, 0x102130, stat); 136 nv_wr32(dev, 0x102130, stat);
137 nv_wr32(dev, 0x10200c, 0x10); 137 nv_wr32(dev, 0x10200c, 0x10);
138 138
139 nv50_fb_vm_trap(dev, show, "PCRYPT"); 139 nv50_fb_vm_trap(dev, show);
140} 140}