aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIlia Mirkin <imirkin@alum.mit.edu>2014-01-17 06:19:46 -0500
committerBen Skeggs <bskeggs@redhat.com>2014-01-22 22:39:17 -0500
commitf750ecc95068b2b492819ca15182fc4c632b4cca (patch)
treeb4336210ff4b341390e5df16abd1ca6848859831
parente2dd003dfa81de3247d7edae5d1a49427cf5a2c4 (diff)
drm/nv50/gr: update list of mp errors, make it a bitfield
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
-rw-r--r--drivers/gpu/drm/nouveau/core/engine/graph/nv50.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/drivers/gpu/drm/nouveau/core/engine/graph/nv50.c b/drivers/gpu/drm/nouveau/core/engine/graph/nv50.c
index a489ac2f3382..0f8d18ae6802 100644
--- a/drivers/gpu/drm/nouveau/core/engine/graph/nv50.c
+++ b/drivers/gpu/drm/nouveau/core/engine/graph/nv50.c
@@ -304,12 +304,14 @@ nv84_graph_tlb_flush(struct nouveau_engine *engine)
304 return timeout ? -EBUSY : 0; 304 return timeout ? -EBUSY : 0;
305} 305}
306 306
307static const struct nouveau_enum nv50_mp_exec_error_names[] = { 307static const struct nouveau_bitfield nv50_mp_exec_errors[] = {
308 { 3, "STACK_UNDERFLOW", NULL }, 308 { 0x01, "STACK_UNDERFLOW" },
309 { 4, "QUADON_ACTIVE", NULL }, 309 { 0x02, "STACK_MISMATCH" },
310 { 8, "TIMEOUT", NULL }, 310 { 0x04, "QUADON_ACTIVE" },
311 { 0x10, "INVALID_OPCODE", NULL }, 311 { 0x08, "TIMEOUT" },
312 { 0x40, "BREAKPOINT", NULL }, 312 { 0x10, "INVALID_OPCODE" },
313 { 0x20, "PM_OVERFLOW" },
314 { 0x40, "BREAKPOINT" },
313 {} 315 {}
314}; 316};
315 317
@@ -474,8 +476,8 @@ nv50_priv_mp_trap(struct nv50_graph_priv *priv, int tpid, int display)
474 oplow = nv_rd32(priv, addr + 0x70); 476 oplow = nv_rd32(priv, addr + 0x70);
475 ophigh = nv_rd32(priv, addr + 0x74); 477 ophigh = nv_rd32(priv, addr + 0x74);
476 nv_error(priv, "TRAP_MP_EXEC - " 478 nv_error(priv, "TRAP_MP_EXEC - "
477 "TP %d MP %d: ", tpid, i); 479 "TP %d MP %d:", tpid, i);
478 nouveau_enum_print(nv50_mp_exec_error_names, status); 480 nouveau_bitfield_print(nv50_mp_exec_errors, status);
479 pr_cont(" at %06x warp %d, opcode %08x %08x\n", 481 pr_cont(" at %06x warp %d, opcode %08x %08x\n",
480 pc&0xffffff, pc >> 24, 482 pc&0xffffff, pc >> 24,
481 oplow, ophigh); 483 oplow, ophigh);