* mips-tdep.c (deprecated_mips_set_processor_regs_hack): Read from
authorUlrich Weigand <uweigand@de.ibm.com>
Fri, 15 Jun 2007 22:29:52 +0000 (22:29 +0000)
committerUlrich Weigand <uweigand@de.ibm.com>
Fri, 15 Jun 2007 22:29:52 +0000 (22:29 +0000)
current regcache instead of calling read_register.

gdb/ChangeLog
gdb/mips-tdep.c

index 2bd14bf367bd0a8f2ef1c1f3d4b850f74749f534..808c9d47b1c7aa927621d15696fa794e50c7bb67 100644 (file)
@@ -1,3 +1,8 @@
+2007-06-15  Ulrich Weigand  <uweigand@de.ibm.com>
+
+       * mips-tdep.c (deprecated_mips_set_processor_regs_hack): Read from
+       current regcache instead of calling read_register.
+
 2007-06-15  Ulrich Weigand  <uweigand@de.ibm.com>
 
        * mep-tdep.c (current_me_module): Read from current regcache
index 288d9747fab5bc4d1ce20fb8e344527f35aaad87..89e91c0f045acbb4866220ce7754ad287c29d21b 100644 (file)
@@ -4472,10 +4472,10 @@ void
 deprecated_mips_set_processor_regs_hack (void)
 {
   struct gdbarch_tdep *tdep = gdbarch_tdep (current_gdbarch);
-  CORE_ADDR prid;
-
-  prid = read_register (MIPS_PRID_REGNUM);
+  ULONGEST prid;
 
+  regcache_cooked_read_unsigned (current_regcache,
+                                MIPS_PRID_REGNUM, &prid);
   if ((prid & ~0xf) == 0x700)
     tdep->mips_processor_reg_names = mips_r3041_reg_names;
 }