From: Keith Walker Date: Wed, 5 Dec 2001 15:11:48 +0000 (+0000) Subject: * gdbserver/low-linux.c (arm_register_u_addr): added. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=ae45a35b444897e5dfd902d37386c4b6e54f2122;p=binutils-gdb.git * gdbserver/low-linux.c (arm_register_u_addr): added. (initialize_arch): added for ARM target. * config/arm/nm-linux.h (U_REGS_OFFSET) defined. (REGISTER_U_ADDR) defined. * config/arm/tm-linux.h (ARM_GNULINUX_TARGET) defined. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 59a4666b558..dece6474f49 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,10 @@ +2001-12-03 Keith Walker + * gdbserver/low-linux.c (arm_register_u_addr): added. + (initialize_arch): added for ARM target. + * config/arm/nm-linux.h (U_REGS_OFFSET) defined. + (REGISTER_U_ADDR) defined. + * config/arm/tm-linux.h (ARM_GNULINUX_TARGET) defined. + 2001-12-04 Corinna Vinschen * arm-tdep.c (arm_skip_prologue): Always skip prologue by scanning diff --git a/gdb/config/arm/nm-linux.h b/gdb/config/arm/nm-linux.h index e2a1795af47..2a0ebb3804b 100644 --- a/gdb/config/arm/nm-linux.h +++ b/gdb/config/arm/nm-linux.h @@ -23,6 +23,15 @@ #include "nm-linux.h" +/* ptrace register ``addresses'' are absolute. */ + +#define U_REGS_OFFSET 0 + +#ifdef GDBSERVER +#define REGISTER_U_ADDR(addr,blockend,regno) \ + (addr) = arm_register_u_addr ((blockend),(regno)) +#endif /* GDBSERVER */ + /* Return sizeof user struct to callers in less machine dependent routines */ extern int kernel_u_size (void); #define KERNEL_U_SIZE arm_linux_kernel_u_size() diff --git a/gdb/config/arm/tm-linux.h b/gdb/config/arm/tm-linux.h index 4ef05bb813c..97520e701d4 100644 --- a/gdb/config/arm/tm-linux.h +++ b/gdb/config/arm/tm-linux.h @@ -21,6 +21,10 @@ #ifndef TM_ARMLINUX_H #define TM_ARMLINUX_H +#ifdef GDBSERVER +#define ARM_GNULINUX_TARGET +#endif + /* Include the common ARM target definitions. */ #include "arm/tm-arm.h" diff --git a/gdb/gdbserver/low-linux.c b/gdb/gdbserver/low-linux.c index 0c7fce55833..0fd14af97ac 100644 --- a/gdb/gdbserver/low-linux.c +++ b/gdb/gdbserver/low-linux.c @@ -541,6 +541,19 @@ initialize_arch (void) { return; } + +#elif defined(ARM_GNULINUX_TARGET) +int arm_register_u_addr(blockend, regnum) + int blockend; + int regnum; +{ + return blockend + REGISTER_BYTE(regnum); +} + +static void +initialize_arch () +{ +} #endif CORE_ADDR