aboutsummaryrefslogtreecommitdiff
path: root/gdb/armnbsd-nat.c
diff options
context:
space:
mode:
authorUlrich Weigand <uweigand@de.ibm.com>2007-06-09 13:49:20 +0000
committerUlrich Weigand <uweigand@de.ibm.com>2007-06-09 13:49:20 +0000
commitbf6ae4641c04121071734f45fd22b2ee2533d3b1 (patch)
treef6862b215882e0410306eb5e626c366836ea1c2f /gdb/armnbsd-nat.c
parentc9f4d5725ddd4daae3866469aaa6293f1b58a404 (diff)
downloadgdb-bf6ae4641c04121071734f45fd22b2ee2533d3b1.zip
gdb-bf6ae4641c04121071734f45fd22b2ee2533d3b1.tar.gz
gdb-bf6ae4641c04121071734f45fd22b2ee2533d3b1.tar.bz2
2007-06-09 Markus Deuling <deuling@de.ibm.com>
* gdbarch.sh (ADDR_BITS_REMOVE): Replace by gdbarch_addr_bits_remove. * value.c (value_as_address): Likewise (comment). * remote-mips.c (common_breakpoint): Likewise. * regcache.c (read_pc_pid): Likewise. * printcmd.c (do_one_display): Likewise. * monitor.c (monitor_write_memory, monitor_read_memory) (monitor_insert_breakpoint): Likewise. * mips-tdep.c (heuristic_proc_start): Likewise. * infrun.c (insert_step_resume_breakpoint_at_frame) (insert_step_resume_breakpoint_at_caller): Likewise. * buildsym.c (record_line): Likewise. * arm-tdep.c (arm_scan_prologue, thumb_get_next_pc) (arm_get_next_pc): Likewise. * armnbsd-nat.c (arm_supply_gregset, fetch_register, store_register) (store_regs): Likewise. * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise. * arm-linux-nat.c (fetch_register, fetch_regs): Likewise. * gdbarch.c, gdbarch.h: Regenerate.
Diffstat (limited to 'gdb/armnbsd-nat.c')
-rw-r--r--gdb/armnbsd-nat.c22
1 files changed, 13 insertions, 9 deletions
diff --git a/gdb/armnbsd-nat.c b/gdb/armnbsd-nat.c
index 6f6bd77..e8febd3 100644
--- a/gdb/armnbsd-nat.c
+++ b/gdb/armnbsd-nat.c
@@ -52,7 +52,7 @@ arm_supply_gregset (struct regcache *regcache, struct reg *gregset)
regcache_raw_supply (regcache, ARM_LR_REGNUM,
(char *) &gregset->r_lr);
/* This is ok: we're running native... */
- r_pc = ADDR_BITS_REMOVE (gregset->r_pc);
+ r_pc = gdbarch_addr_bits_remove (current_gdbarch, gregset->r_pc);
regcache_raw_supply (regcache, ARM_PC_REGNUM, (char *) &r_pc);
if (arm_apcs_32)
@@ -105,7 +105,8 @@ fetch_register (struct regcache *regcache, int regno)
case ARM_PC_REGNUM:
/* This is ok: we're running native... */
- inferior_registers.r_pc = ADDR_BITS_REMOVE (inferior_registers.r_pc);
+ inferior_registers.r_pc = gdbarch_addr_bits_remove
+ (current_gdbarch, inferior_registers.r_pc);
regcache_raw_supply (regcache, ARM_PC_REGNUM,
(char *) &inferior_registers.r_pc);
break;
@@ -249,9 +250,10 @@ store_register (const struct regcache *regcache, int regno)
regcache_raw_collect (regcache, ARM_PC_REGNUM,
(char *) &pc_val);
- pc_val = ADDR_BITS_REMOVE (pc_val);
- inferior_registers.r_pc
- ^= ADDR_BITS_REMOVE (inferior_registers.r_pc);
+ pc_val = gdbarch_addr_bits_remove (current_gdbarch, pc_val);
+ inferior_registers.r_pc ^= gdbarch_addr_bits_remove
+ (current_gdbarch,
+ inferior_registers.r_pc);
inferior_registers.r_pc |= pc_val;
}
break;
@@ -267,8 +269,10 @@ store_register (const struct regcache *regcache, int regno)
regcache_raw_collect (regcache, ARM_PS_REGNUM,
(char *) &psr_val);
- psr_val ^= ADDR_BITS_REMOVE (psr_val);
- inferior_registers.r_pc = ADDR_BITS_REMOVE (inferior_registers.r_pc);
+ psr_val ^= gdbarch_addr_bits_remove (current_gdbarch, psr_val);
+ inferior_registers.r_pc = gdbarch_addr_bits_remove
+ (current_gdbarch,
+ inferior_registers.r_pc);
inferior_registers.r_pc |= psr_val;
}
break;
@@ -320,8 +324,8 @@ store_regs (const struct regcache *regcache)
regcache_raw_collect (regcache, ARM_PS_REGNUM,
(char *) &psr_val);
- pc_val = ADDR_BITS_REMOVE (pc_val);
- psr_val ^= ADDR_BITS_REMOVE (psr_val);
+ pc_val = gdbarch_addr_bits_remove (current_gdbarch, pc_val);
+ psr_val ^= gdbarch_addr_bits_remove (current_gdbarch, psr_val);
inferior_registers.r_pc = pc_val | psr_val;
}