From bf627e0c32241915108f66ad9738444e4d045b45 Mon Sep 17 00:00:00 2001 From: David Herrmann Date: Thu, 2 Aug 2018 18:58:24 +0200 Subject: [PATCH] test: skip ptrace if SINGLESTEP is not supported On armv7hl the PTRACE_SINGLESTEP call is no longer supported. Make sure we skip the test in this case. Signed-off-by: David Herrmann --- src/test-parallel.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/test-parallel.c b/src/test-parallel.c index 4f689cb..4513d9e 100644 --- a/src/test-parallel.c +++ b/src/test-parallel.c @@ -284,6 +284,15 @@ static int test_parallel(void) { /* step child */ r = ptrace(PTRACE_SINGLESTEP, pid, 0, 0); + + /* + * Some architectures (e.g., armv7hl) do not implement + * SINGLESTEP, but return EIO. Skip the entire test in + * this case. + */ + if (r < 0 && errno == EIO) + return 77; + assert(r >= 0); break;