[PATCH] tests: backtrace.c accept __libc_do_syscall as first frame symname.
Mark Wielaard
mjw at redhat.com
Fri Jun 13 23:11:16 UTC 2014
On some architectures (Debian armhl) system calls go through
__libc_do_syscall instead of __kernel_vsyscall. Accept either of
these symbol names for the first backtrace frame.
Signed-off-by: Mark Wielaard <mjw at redhat.com>
---
tests/ChangeLog | 5 +++++
tests/backtrace.c | 3 ++-
2 files changed, 7 insertions(+), 1 deletions(-)
diff --git a/tests/ChangeLog b/tests/ChangeLog
index 7c46428..90a2a0e 100644
--- a/tests/ChangeLog
+++ b/tests/ChangeLog
@@ -1,5 +1,10 @@
2014-06-13 Mark Wielaard <mjw at redhat.com>
+ * backtrace.c (callback_verify): Accept "__libc_do_syscall" as first
+ frame symname.
+
+2014-06-13 Mark Wielaard <mjw at redhat.com>
+
* backtrace-subr.sh (check_native_unsupported): New function.
(check_native): Call it.
(check_native_core): Likewise.
diff --git a/tests/backtrace.c b/tests/backtrace.c
index ce0bd17..1d3948e 100644
--- a/tests/backtrace.c
+++ b/tests/backtrace.c
@@ -98,7 +98,8 @@ callback_verify (pid_t tid, unsigned frameno, Dwarf_Addr pc,
{
case 0:
if (! reduce_frameno && symname
- && strcmp (symname, "__kernel_vsyscall") == 0)
+ && (strcmp (symname, "__kernel_vsyscall") == 0
+ || strcmp (symname, "__libc_do_syscall") == 0))
reduce_frameno = true;
else
assert (symname && strcmp (symname, "raise") == 0);
--
1.7.1
More information about the elfutils-devel
mailing list