From: Jim Blandy Date: Wed, 28 May 2003 20:20:21 +0000 (+0000) Subject: * ppc-linux-nat.c (store_altivec_registers): Don't cast fourth X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3c043fb7fbafd6b5816a4993e15211115cd24a53;p=thirdparty%2Fbinutils-gdb.git * ppc-linux-nat.c (store_altivec_registers): Don't cast fourth argument to ptrace to int; the system headers should give it the right type, and pointers don't fit in ints on powerpc64-*-*. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 2580a1670de..61f59e51305 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,9 @@ 2003-05-28 Jim Blandy + * ppc-linux-nat.c (store_altivec_registers): Don't cast fourth + argument to ptrace to int; the system headers should give it the + right type, and pointers don't fit in ints on powerpc64-*-*. + * ppc-linux-nat.c (ppc_register_u_addr): Compute u-area offsets using the tdep's wordsize, not just '4'. diff --git a/gdb/ppc-linux-nat.c b/gdb/ppc-linux-nat.c index f69c14011b3..c668c589def 100644 --- a/gdb/ppc-linux-nat.c +++ b/gdb/ppc-linux-nat.c @@ -429,7 +429,7 @@ store_altivec_registers (int tid) int ret; gdb_vrregset_t regs; - ret = ptrace (PTRACE_GETVRREGS, tid, 0, (int) ®s); + ret = ptrace (PTRACE_GETVRREGS, tid, 0, ®s); if (ret < 0) { if (errno == EIO) @@ -442,7 +442,7 @@ store_altivec_registers (int tid) fill_vrregset (®s); - if (ptrace (PTRACE_SETVRREGS, tid, 0, (int) ®s) < 0) + if (ptrace (PTRACE_SETVRREGS, tid, 0, ®s) < 0) perror_with_name ("Couldn't write AltiVec registers"); }