diff options
author | Andrei Vagin <avagin@google.com> | 2021-01-19 15:31:49 -0800 |
---|---|---|
committer | gVisor bot <gvisor-bot@google.com> | 2021-01-19 15:34:02 -0800 |
commit | 48ea2c34d1d3dead7727d9e2760b587c7609b14b (patch) | |
tree | 7b8e2c8bc3a2a1a8da7f780800e4d2aae674b943 /test/syscalls/linux/BUILD | |
parent | be17b94446b2f96c2a3d531fe20271537c77c8aa (diff) |
platform/ptrace: workaround a kernel ptrace issue on ARM64
On ARM64, when ptrace stops on a system call, it uses the x7 register to
indicate whether the stop has been signalled from syscall entry or syscall
exit. This means that we can't get a value of this register and we can't change
it. More details are in the comment for tracehook_report_syscall in
arch/arm64/kernel/ptrace.c.
This happens only if we stop on a system call, so let's queue a signal, resume
a stub thread and catch it on a signal handling.
Fixes: #5238
PiperOrigin-RevId: 352668695
Diffstat (limited to 'test/syscalls/linux/BUILD')
-rw-r--r-- | test/syscalls/linux/BUILD | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/syscalls/linux/BUILD b/test/syscalls/linux/BUILD index d184712e3..b37716c48 100644 --- a/test/syscalls/linux/BUILD +++ b/test/syscalls/linux/BUILD @@ -2191,11 +2191,11 @@ cc_binary( ) cc_binary( - name = "sigiret_test", + name = "sigreturn_test", testonly = 1, srcs = select_arch( - amd64 = ["sigiret.cc"], - arm64 = [], + amd64 = ["sigreturn_amd64.cc"], + arm64 = ["sigreturn_arm64.cc"], ), linkstatic = 1, deps = [ |