Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 67347
b: refs/heads/master
c: d464fb4
h: refs/heads/master
i:
  67345: 7ba80d6
  67343: c20fe44
v: v3
  • Loading branch information
Michael Ellerman authored and Paul Mackerras committed Sep 19, 2007
1 parent ccf5fc5 commit f9b4295
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 11 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 4fca9c425009c01d41db6c6ebf0189843ee90f0b
refs/heads/master: d464fb441071a3d65bde2264c5f97f9ca47ce5c3
8 changes: 5 additions & 3 deletions trunk/arch/powerpc/platforms/cell/spufs/coredump.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@

#include "spufs.h"

static ssize_t do_coredump_read(int num, struct spu_context *ctx, void __user *buffer,
static ssize_t do_coredump_read(int num, struct spu_context *ctx, void *buffer,
size_t size, loff_t *off)
{
u64 data;
Expand All @@ -41,8 +41,10 @@ static ssize_t do_coredump_read(int num, struct spu_context *ctx, void __user *b
return spufs_coredump_read[num].read(ctx, buffer, size, off);

data = spufs_coredump_read[num].get(ctx);
ret = copy_to_user(buffer, &data, 8);
return ret ? -EFAULT : 8;
ret = snprintf(buffer, size, "0x%.16lx", data);
if (ret >= size)
return size;
return ++ret; /* count trailing NULL */
}

/*
Expand Down
14 changes: 7 additions & 7 deletions trunk/arch/powerpc/platforms/cell/spufs/file.c
Original file line number Diff line number Diff line change
Expand Up @@ -2233,16 +2233,16 @@ struct tree_descr spufs_dir_nosched_contents[] = {
struct spufs_coredump_reader spufs_coredump_read[] = {
{ "regs", __spufs_regs_read, NULL, sizeof(struct spu_reg128[128])},
{ "fpcr", __spufs_fpcr_read, NULL, sizeof(struct spu_reg128) },
{ "lslr", NULL, __spufs_lslr_get, 11 },
{ "decr", NULL, __spufs_decr_get, 11 },
{ "decr_status", NULL, __spufs_decr_status_get, 11 },
{ "lslr", NULL, __spufs_lslr_get, 19 },
{ "decr", NULL, __spufs_decr_get, 19 },
{ "decr_status", NULL, __spufs_decr_status_get, 19 },
{ "mem", __spufs_mem_read, NULL, LS_SIZE, },
{ "signal1", __spufs_signal1_read, NULL, sizeof(u32) },
{ "signal1_type", NULL, __spufs_signal1_type_get, 2 },
{ "signal1_type", NULL, __spufs_signal1_type_get, 19 },
{ "signal2", __spufs_signal2_read, NULL, sizeof(u32) },
{ "signal2_type", NULL, __spufs_signal2_type_get, 2 },
{ "event_mask", NULL, __spufs_event_mask_get, 8 },
{ "event_status", NULL, __spufs_event_status_get, 8 },
{ "signal2_type", NULL, __spufs_signal2_type_get, 19 },
{ "event_mask", NULL, __spufs_event_mask_get, 19 },
{ "event_status", NULL, __spufs_event_status_get, 19 },
{ "mbox_info", __spufs_mbox_info_read, NULL, sizeof(u32) },
{ "ibox_info", __spufs_ibox_info_read, NULL, sizeof(u32) },
{ "wbox_info", __spufs_wbox_info_read, NULL, 4 * sizeof(u32)},
Expand Down

0 comments on commit f9b4295

Please sign in to comment.