get_regs: define for all architectures
* defs.h (get_regs_error): Remove.
(clear_regs): Update prototype, declare unconditionally.
(get_regs): Declare unconditionally.
* syscall.c (clear_regs): New function.
(get_regs): Define unconditionally.
(get_regs_error): Define unconditionally, change scope to static.
diff --git a/syscall.c b/syscall.c
index a355367..8929a75 100644
--- a/syscall.c
+++ b/syscall.c
@@ -791,6 +791,8 @@
# define ARCH_REGS_FOR_GETREGSET arc_regs
#endif
+static long get_regs_error;
+
void
print_pc(struct tcb *tcp)
{
@@ -1017,8 +1019,11 @@
}
#endif
-#ifndef get_regs
-long get_regs_error;
+void
+clear_regs(void)
+{
+ get_regs_error = -1;
+}
#if defined ARCH_REGS_FOR_GETREGSET
static long
@@ -1116,7 +1121,6 @@
get_regs_error = 0;
#endif
}
-#endif /* !get_regs */
/* Returns:
* 0: "ignore this ptrace stop", bail out of trace_syscall_entering() silently.