Hi,
 
I am meeting a problem that orig_r0 is overwritten by gdbserver(gdb 6.3)
on ARM.
It is because store_register/store_regs (in arm-linux-nat.c) set
register with ptrace(PTRACE_SETREGS ...)
 
But as orig_r0 is not mapped by gdbserver, it will be overwritten.
This lost of orig_r0 will prevent the interrupted system call from being
restarted.
 
I am new to gdbserver, so not sure whether this patch is correct,
 
arm-linux-nat.c:
 
-#define arm_num_regs 26
+#define arm_num_regs 27
 
 static int arm_regmap[] = {
   0, 4, 8, 12, 16, 20, 24, 28,
   32, 36, 40, 44, 48, 52, 56, 60,
  -1, -1, -1, -1, -1, -1, -1, -1, -1,
-  64
+  64, 68
 };
 
Thanks,
Tom
_______________________________________________
bug-gdb mailing list
bug-gdb@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gdb

Reply via email to