Commit 78810ff6 authored by Michael Ellerman's avatar Michael Ellerman Committed by Paul Mackerras

[POWERPC] spufs: Add contents of npc file to SPU coredumps

Signed-off-by: default avatarMichael Ellerman <michael@ellerman.id.au>
Signed-off-by: default avatarJeremy Kerr <jk@ozlabs.org>
Acked-by: default avatarArnd Bergmann <arnd.bergmann@de.ibm.com>
Signed-off-by: default avatarPaul Mackerras <paulus@samba.org>
parent 74de08bc
...@@ -1606,12 +1606,17 @@ static void spufs_npc_set(void *data, u64 val) ...@@ -1606,12 +1606,17 @@ static void spufs_npc_set(void *data, u64 val)
spu_release(ctx); spu_release(ctx);
} }
static u64 __spufs_npc_get(struct spu_context *ctx)
{
return ctx->ops->npc_read(ctx);
}
static u64 spufs_npc_get(void *data) static u64 spufs_npc_get(void *data)
{ {
struct spu_context *ctx = data; struct spu_context *ctx = data;
u64 ret; u64 ret;
spu_acquire(ctx); spu_acquire(ctx);
ret = ctx->ops->npc_read(ctx); ret = __spufs_npc_get(ctx);
spu_release(ctx); spu_release(ctx);
return ret; return ret;
} }
...@@ -2242,5 +2247,6 @@ struct spufs_coredump_reader spufs_coredump_read[] = { ...@@ -2242,5 +2247,6 @@ struct spufs_coredump_reader spufs_coredump_read[] = {
{ "proxydma_info", __spufs_proxydma_info_read, { "proxydma_info", __spufs_proxydma_info_read,
NULL, sizeof(struct spu_proxydma_info)}, NULL, sizeof(struct spu_proxydma_info)},
{ "object-id", NULL, __spufs_object_id_get, 19 }, { "object-id", NULL, __spufs_object_id_get, 19 },
{ "npc", NULL, __spufs_npc_get, 19 },
{ NULL }, { NULL },
}; };
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment