summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorBen Skeggs <bskeggs@redhat.com>2012-12-04 05:25:28 (GMT)
committerBen Skeggs <bskeggs@redhat.com>2013-02-20 06:00:22 (GMT)
commit382b5bbb4a1ef96be863b71593d23968308b6d24 (patch)
tree87cec569d092d9b2933dfab7fbc72d1e1427f758 /drivers
parenta10220bbf883931fcf18eb0e850b87d82cfaa412 (diff)
downloadlinux-fsl-qoriq-382b5bbb4a1ef96be863b71593d23968308b6d24.tar.xz
drm/nvc0/bus: report useful data on mmio fault
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/gpu/drm/nouveau/core/subdev/bus/nvc0.c15
1 files changed, 10 insertions, 5 deletions
diff --git a/drivers/gpu/drm/nouveau/core/subdev/bus/nvc0.c b/drivers/gpu/drm/nouveau/core/subdev/bus/nvc0.c
index 10d95f5..b192d62 100644
--- a/drivers/gpu/drm/nouveau/core/subdev/bus/nvc0.c
+++ b/drivers/gpu/drm/nouveau/core/subdev/bus/nvc0.c
@@ -36,12 +36,17 @@ nvc0_bus_intr(struct nouveau_subdev *subdev)
u32 stat = nv_rd32(pbus, 0x001100) & nv_rd32(pbus, 0x001140);
if (stat & 0x0000000e) {
- nv_error(pbus, "MMIO FAULT [");
- if (stat & 0x00000002) pr_cont(" !ENGINE");
- if (stat & 0x00000004) pr_cont(" IBUS");
- if (stat & 0x00000004) pr_cont(" TIMEOUT");
- pr_cont("]\n");
+ u32 addr = nv_rd32(pbus, 0x009084);
+ u32 data = nv_rd32(pbus, 0x009088);
+ nv_error(pbus, "MMIO %s of 0x%08x FAULT at 0x%06x [ %s%s%s]\n",
+ (addr & 0x00000002) ? "write" : "read", data,
+ (addr & 0x00fffffc),
+ (stat & 0x00000002) ? "!ENGINE " : "",
+ (stat & 0x00000004) ? "IBUS " : "",
+ (stat & 0x00000008) ? "TIMEOUT " : "");
+
+ nv_wr32(pbus, 0x009084, 0x00000000);
nv_wr32(pbus, 0x001100, (stat & 0x0000000e));
stat &= ~0x0000000e;
}