2012-03-28 Pedro Alves <palves@redhat.com>
[deliverable/binutils-gdb.git] / gdb / gdbserver / linux-low.c
index 8becf78cceac2095c7b01dacea0dbb196debb470..aea8d36794337dd078de02e518d2916454742b11 100644 (file)
@@ -4271,11 +4271,19 @@ linux_fetch_registers (struct regcache *regcache, int regno)
 
   if (regno == -1)
     {
+      if (the_low_target.fetch_register != NULL)
+       for (regno = 0; regno < the_low_target.num_regs; regno++)
+         (*the_low_target.fetch_register) (regcache, regno);
+
       all = regsets_fetch_inferior_registers (regcache);
-      usr_fetch_inferior_registers (regcache, regno, all);
+      usr_fetch_inferior_registers (regcache, -1, all);
     }
   else
     {
+      if (the_low_target.fetch_register != NULL
+         && (*the_low_target.fetch_register) (regcache, regno))
+       return;
+
       use_regsets = linux_register_in_regsets (regno);
       if (use_regsets)
        all = regsets_fetch_inferior_registers (regcache);
This page took 0.025432 seconds and 4 git commands to generate.