gdb/ChangeLog:
* config/alpha/nm-osf.h (PTRACE_XFER_TYPE): Remove. * config/mips/nm-linux.h (PTRACE_ARG3_TYPE, PTRACE_XFER_TYPE): Remove. * config/sparc/nm-linux.h (PTRACE_ARG3_TYPE, PTRACE_XFER_TYPE): Remove. * config/powerpc/nm-ppc64-linux.h: Remove file. * config/powerpc/ppc64-linux.mh (NATDEPFILES): Set to nm-linux.h. * inferior.h (PTRACE_ARG3_TYPE): Do not define. (call_ptrace): Change type of third argument to PTRACE_TYPE_ARG3. * infptrace.c (call_ptrace): Likewise. * m68klinux-nat.c (PTRACE_XFER_TYPE): Do not define. (fetch_register): Replace PTRACE_ARG3_TYPE by PTRACE_TYPE_ARG3 and PTRACE_XFER_TYPE by PTRACE_TYPE_RET. (store_register): Likewise. gdb/doc/ChangeLog: * gdbint.texi (Native Conditionals): Remove PTRACE_ARG3_TYPE.
This commit is contained in:
parent
bbf90c8127
commit
5f4026606b
11 changed files with 30 additions and 67 deletions
|
@ -118,11 +118,6 @@ m68k_linux_register_u_addr (int blockend, int regnum)
|
|||
#define PT_WRITE_U PTRACE_POKEUSR
|
||||
#endif
|
||||
|
||||
/* Default the type of the ptrace transfer to int. */
|
||||
#ifndef PTRACE_XFER_TYPE
|
||||
#define PTRACE_XFER_TYPE int
|
||||
#endif
|
||||
|
||||
/* Fetch one register. */
|
||||
|
||||
static void
|
||||
|
@ -152,12 +147,12 @@ fetch_register (int regno)
|
|||
|
||||
regaddr = register_addr (regno, offset);
|
||||
for (i = 0; i < register_size (current_gdbarch, regno);
|
||||
i += sizeof (PTRACE_XFER_TYPE))
|
||||
i += sizeof (PTRACE_TYPE_RET))
|
||||
{
|
||||
errno = 0;
|
||||
*(PTRACE_XFER_TYPE *) &buf[i] = ptrace (PT_READ_U, tid,
|
||||
(PTRACE_ARG3_TYPE) regaddr, 0);
|
||||
regaddr += sizeof (PTRACE_XFER_TYPE);
|
||||
*(PTRACE_TYPE_RET *) &buf[i] = ptrace (PT_READ_U, tid,
|
||||
(PTRACE_TYPE_ARG3) regaddr, 0);
|
||||
regaddr += sizeof (PTRACE_TYPE_RET);
|
||||
if (errno != 0)
|
||||
{
|
||||
sprintf (mess, "reading register %s (#%d)",
|
||||
|
@ -220,12 +215,12 @@ store_register (int regno)
|
|||
|
||||
/* Store the local buffer into the inferior a chunk at the time. */
|
||||
for (i = 0; i < register_size (current_gdbarch, regno);
|
||||
i += sizeof (PTRACE_XFER_TYPE))
|
||||
i += sizeof (PTRACE_TYPE_RET))
|
||||
{
|
||||
errno = 0;
|
||||
ptrace (PT_WRITE_U, tid, (PTRACE_ARG3_TYPE) regaddr,
|
||||
*(PTRACE_XFER_TYPE *) (buf + i));
|
||||
regaddr += sizeof (PTRACE_XFER_TYPE);
|
||||
ptrace (PT_WRITE_U, tid, (PTRACE_TYPE_ARG3) regaddr,
|
||||
*(PTRACE_TYPE_RET *) (buf + i));
|
||||
regaddr += sizeof (PTRACE_TYPE_RET);
|
||||
if (errno != 0)
|
||||
{
|
||||
sprintf (mess, "writing register %s (#%d)",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue