aboutsummaryrefslogtreecommitdiff
path: root/gdb/mipsnbsd-tdep.c
diff options
context:
space:
mode:
authorUlrich Weigand <uweigand@de.ibm.com>2007-05-06 14:29:15 +0000
committerUlrich Weigand <uweigand@de.ibm.com>2007-05-06 14:29:15 +0000
commit28f5035f336a0d28983f5c58b3c7abb3d2e47b5d (patch)
tree984894d5000d06d02c9b39c5a9e84a404f806ab0 /gdb/mipsnbsd-tdep.c
parent26144df5d2c0b2fa0244f3fb95f8ed2686ac0815 (diff)
downloadgdb-28f5035f336a0d28983f5c58b3c7abb3d2e47b5d.zip
gdb-28f5035f336a0d28983f5c58b3c7abb3d2e47b5d.tar.gz
gdb-28f5035f336a0d28983f5c58b3c7abb3d2e47b5d.tar.bz2
* mips-linux-tdep.c (supply_32bit_reg): Add REGCACHE parameter. Use it
instead of current_regcache. (mips_supply_gregset): Likewise. Pass REGCACHE to supply_32bit_reg. Make GREGSETP const, remove superfluous casts. (mips_fill_gregset): Add REGCACHE parameter; replace current_regcache. (mips_supply_fpregset): Likewise. Make FPREGSETP const, remove superfluous casts. (mips_fill_fpregset): Add REGCACHE parameter; replace current_regcache. (supply_64bit_reg): Likewise (mips64_supply_gregset): Likewise. Pass REGCACHE to supply_64bit_reg. Make GREGSETP const, adapt casts accordingly. (mips64_fill_gregset): Add REGCACHE parameter; replace current_regcache. (mips64_supply_fpregset): Likewise. Make FPREGSET const, adapt casts accordingly. (mips64_fill_fpregset): Add REGCACHE parameter; replace current_regcache. (fetch_core_registers): Pass current_regcache to mips{64}_(supply|fill)_ helper routines. * mips-linux-tdep.h (mips_supply_gregset, mips_fill_gregset, mips_supply_fpregset, mips_fill_fpregset, mips64_supply_gregset, mips64_fill_gregset, mips64_supply_fpregset, mips64_fill_fpregset): Adapt prototypes. * mips-linux-nat.c: Include "regcache.h". (supply_gregset, fill_gregset, supply_fpregset, fill_fpregset): Pass current_regcache to mips{64}_(supply|fill)_ helper routines. (mips64_linux_regsets_fetch_registers): Likewise. (mips64_linux_regsets_store_registers): Likewise. * mipsnbsd-tdep.c (mipsnbsd_supply_reg, mipsnbsd_supply_fpreg): Add REGCACHE argument; replace current_regcache. Make REGS const. (mipsnbds_fill_reg, mipsnbsd_fill_fpreg): Add REGCACHE argument; replace current_regcache. * mipsnbsd-tdep.h (ipsnbsd_supply_reg, mipsnbsd_supply_fpreg, mipsnbds_fill_reg, mipsnbsd_fill_fpreg): Adapt prototypes. * mipsnbsd-nat.c (mipsnbsd_fetch_inferior_registers, mipsnbsd_store_inferior_registers): Pass current_regcache to mipsnbsd_(supply|fill)_... helper routines. * Makefile.in (mips-linux-nat.o): Update dependencies.
Diffstat (limited to 'gdb/mipsnbsd-tdep.c')
-rw-r--r--gdb/mipsnbsd-tdep.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/gdb/mipsnbsd-tdep.c b/gdb/mipsnbsd-tdep.c
index d55708d..3e69d1c 100644
--- a/gdb/mipsnbsd-tdep.c
+++ b/gdb/mipsnbsd-tdep.c
@@ -142,7 +142,7 @@ mipsnbsd_regset_from_core_section (struct gdbarch *gdbarch,
ptrace register structure used by NetBSD/mips. */
void
-mipsnbsd_supply_reg (char *regs, int regno)
+mipsnbsd_supply_reg (struct regcache *regcache, const char *regs, int regno)
{
int i;
@@ -151,27 +151,27 @@ mipsnbsd_supply_reg (char *regs, int regno)
if (regno == i || regno == -1)
{
if (CANNOT_FETCH_REGISTER (i))
- regcache_raw_supply (current_regcache, i, NULL);
+ regcache_raw_supply (regcache, i, NULL);
else
- regcache_raw_supply (current_regcache, i,
+ regcache_raw_supply (regcache, i,
regs + (i * mips_isa_regsize (current_gdbarch)));
}
}
}
void
-mipsnbsd_fill_reg (char *regs, int regno)
+mipsnbsd_fill_reg (const struct regcache *regcache, char *regs, int regno)
{
int i;
for (i = 0; i <= PC_REGNUM; i++)
if ((regno == i || regno == -1) && ! CANNOT_STORE_REGISTER (i))
- regcache_raw_collect (current_regcache, i,
+ regcache_raw_collect (regcache, i,
regs + (i * mips_isa_regsize (current_gdbarch)));
}
void
-mipsnbsd_supply_fpreg (char *fpregs, int regno)
+mipsnbsd_supply_fpreg (struct regcache *regcache, const char *fpregs, int regno)
{
int i;
@@ -182,23 +182,23 @@ mipsnbsd_supply_fpreg (char *fpregs, int regno)
if (regno == i || regno == -1)
{
if (CANNOT_FETCH_REGISTER (i))
- regcache_raw_supply (current_regcache, i, NULL);
+ regcache_raw_supply (regcache, i, NULL);
else
- regcache_raw_supply (current_regcache, i,
+ regcache_raw_supply (regcache, i,
fpregs + ((i - FP0_REGNUM) * mips_isa_regsize (current_gdbarch)));
}
}
}
void
-mipsnbsd_fill_fpreg (char *fpregs, int regno)
+mipsnbsd_fill_fpreg (const struct regcache *regcache, char *fpregs, int regno)
{
int i;
for (i = FP0_REGNUM; i <= mips_regnum (current_gdbarch)->fp_control_status;
i++)
if ((regno == i || regno == -1) && ! CANNOT_STORE_REGISTER (i))
- regcache_raw_collect (current_regcache, i,
+ regcache_raw_collect (regcache, i,
fpregs + ((i - FP0_REGNUM) * mips_isa_regsize (current_gdbarch)));
}