This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [rfc] [04/20] Get rid of current_gdbarch in arm-linux-nat.c


Ulrich Weigand schrieb:
Markus Deuling wrote:

this patch gets rid of some of the current_gdbarch's in arm-linux-nat.c

No patch attached ;-)

Oh, really :-) I attached the ChangeLog. Sorry, here is the patch. Ok to commit?




--
Markus Deuling
GNU Toolchain for Linux on Cell BE
deuling@de.ibm.com

diff -urpN src/gdb/arm-linux-nat.c dev/gdb/arm-linux-nat.c
--- src/gdb/arm-linux-nat.c	2007-10-15 21:19:17.000000000 +0200
+++ dev/gdb/arm-linux-nat.c	2007-10-30 06:05:38.000000000 +0100
@@ -255,7 +255,8 @@ fetch_register (struct regcache *regcach
   if (ARM_PC_REGNUM == regno)
     { 
       regs[ARM_PC_REGNUM] = gdbarch_addr_bits_remove
-			      (current_gdbarch, regs[ARM_PC_REGNUM]);
+			      (get_regcache_arch (regcache),
+			       regs[ARM_PC_REGNUM]);
       regcache_raw_supply (regcache, ARM_PC_REGNUM,
 			   (char *) &regs[ARM_PC_REGNUM]);
     }
@@ -291,7 +292,7 @@ fetch_regs (struct regcache *regcache)
 			 (char *) &regs[ARM_PC_REGNUM]);
 
   regs[ARM_PC_REGNUM] = gdbarch_addr_bits_remove
-			  (current_gdbarch, regs[ARM_PC_REGNUM]);
+			  (get_regcache_arch (regcache), regs[ARM_PC_REGNUM]);
   regcache_raw_supply (regcache, ARM_PC_REGNUM,
 		       (char *) &regs[ARM_PC_REGNUM]);
 }

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]