Blame SOURCES/0133-tests-check-decoding-of-tgkill-syscall.patch

097fad
From 9d4d64f6fdfcae908aec455888e92a69c9c81c64 Mon Sep 17 00:00:00 2001
097fad
From: "Dmitry V. Levin" <ldv@altlinux.org>
097fad
Date: Sat, 1 Aug 2020 08:00:00 +0000
097fad
Subject: [PATCH 133/138] tests: check decoding of tgkill syscall
097fad
097fad
* tests/tgkill.c: New file.
097fad
* tests/gen_tests.in (tgkill): New entry.
097fad
* tests/pure_executables.list: Add tgkill.
097fad
* tests/.gitignore: Likewise.
097fad
---
097fad
 tests/.gitignore            |  1 +
097fad
 tests/gen_tests.in          |  1 +
097fad
 tests/pure_executables.list |  1 +
097fad
 tests/tgkill.c              | 69 +++++++++++++++++++++++++++++++++++++++++++++
097fad
 4 files changed, 72 insertions(+)
097fad
 create mode 100644 tests/tgkill.c
097fad
097fad
Index: strace-5.7/tests/gen_tests.in
097fad
===================================================================
097fad
--- strace-5.7.orig/tests/gen_tests.in	2020-09-09 19:30:36.780885588 +0200
097fad
+++ strace-5.7/tests/gen_tests.in	2020-09-09 19:32:50.740965435 +0200
097fad
@@ -658,6 +658,7 @@
097fad
 sysinfo	-a14
097fad
 syslog	-a35
097fad
 tee
097fad
+tgkill	-a15 --signal='!cont'
097fad
 threads-execve--quiet-thread-execve +threads-execve.test -s40 --quiet=personality,thread-execve
097fad
 threads-execve-q +threads-execve.test -q
097fad
 threads-execve-qq +threads-execve.test -qq
097fad
Index: strace-5.7/tests/pure_executables.list
097fad
===================================================================
097fad
--- strace-5.7.orig/tests/pure_executables.list	2020-09-09 19:30:36.780885588 +0200
097fad
+++ strace-5.7/tests/pure_executables.list	2020-09-09 19:32:45.308962197 +0200
097fad
@@ -583,6 +583,7 @@
097fad
 sysinfo
097fad
 syslog
097fad
 tee
097fad
+tgkill
097fad
 time
097fad
 timer_create
097fad
 timer_xettime
097fad
Index: strace-5.7/tests/tgkill.c
097fad
===================================================================
097fad
--- /dev/null	1970-01-01 00:00:00.000000000 +0000
097fad
+++ strace-5.7/tests/tgkill.c	2020-09-09 19:32:50.740965435 +0200
097fad
@@ -0,0 +1,69 @@
097fad
+/*
097fad
+ * Check decoding of tgkill syscall.
097fad
+ *
097fad
+ * Copyright (c) 2020 Dmitry V. Levin <ldv@altlinux.org>
097fad
+ * All rights reserved.
097fad
+ *
097fad
+ * SPDX-License-Identifier: GPL-2.0-or-later
097fad
+ */
097fad
+
097fad
+#include "tests.h"
097fad
+#include "scno.h"
097fad
+
097fad
+#ifdef __NR_tgkill
097fad
+
097fad
+# include <signal.h>
097fad
+# include <stdio.h>
097fad
+# include <unistd.h>
097fad
+
097fad
+static const char *errstr;
097fad
+
097fad
+static long
097fad
+k_tgkill(const unsigned int tgid,
097fad
+	 const unsigned int tid,
097fad
+	 const unsigned int sig)
097fad
+{
097fad
+        const kernel_ulong_t fill = (kernel_ulong_t) 0xdefaced00000000ULL;
097fad
+        const kernel_ulong_t bad = (kernel_ulong_t) 0xbadc0dedbadc0dedULL;
097fad
+        const kernel_ulong_t arg1 = fill | tgid;
097fad
+        const kernel_ulong_t arg2 = fill | tid;
097fad
+        const kernel_ulong_t arg3 = fill | sig;
097fad
+        const long rc = syscall(__NR_tgkill, arg1, arg2, arg3, bad, bad, bad);
097fad
+        errstr = sprintrc(rc);
097fad
+        return rc;
097fad
+}
097fad
+
097fad
+int
097fad
+main(void)
097fad
+{
097fad
+	const int pid = getpid();
097fad
+	const int bad_pid = -1;
097fad
+	const int bad_sig = 0xface;
097fad
+
097fad
+	k_tgkill(pid, pid, 0);
097fad
+	printf("tgkill(%d, %d, 0) = %s\n", pid, pid, errstr);
097fad
+
097fad
+	k_tgkill(pid, bad_pid, 0);
097fad
+	printf("tgkill(%d, %d, 0) = %s\n", pid, bad_pid, errstr);
097fad
+
097fad
+	k_tgkill(bad_pid, pid, 0);
097fad
+	printf("tgkill(%d, %d, 0) = %s\n", bad_pid, pid, errstr);
097fad
+
097fad
+	k_tgkill(pid, pid, SIGCONT);
097fad
+	printf("tgkill(%d, %d, SIGCONT) = %s\n", pid, pid, errstr);
097fad
+
097fad
+	k_tgkill(pid, pid, bad_sig);
097fad
+	printf("tgkill(%d, %d, %d) = %s\n", pid, pid, bad_sig, errstr);
097fad
+
097fad
+	k_tgkill(pid, pid, -bad_sig);
097fad
+	printf("tgkill(%d, %d, %d) = %s\n", pid, pid, -bad_sig, errstr);
097fad
+
097fad
+	puts("+++ exited with 0 +++");
097fad
+	return 0;
097fad
+}
097fad
+
097fad
+#else
097fad
+
097fad
+SKIP_MAIN_UNDEFINED("__NR_tgkill")
097fad
+
097fad
+#endif
097fad
Index: strace-5.7/tests-m32/gen_tests.in
097fad
===================================================================
097fad
--- strace-5.7.orig/tests-m32/gen_tests.in	2020-09-09 19:30:36.780885588 +0200
097fad
+++ strace-5.7/tests-m32/gen_tests.in	2020-09-09 19:32:50.740965435 +0200
097fad
@@ -658,6 +658,7 @@
097fad
 sysinfo	-a14
097fad
 syslog	-a35
097fad
 tee
097fad
+tgkill	-a15 --signal='!cont'
097fad
 threads-execve--quiet-thread-execve +threads-execve.test -s40 --quiet=personality,thread-execve
097fad
 threads-execve-q +threads-execve.test -q
097fad
 threads-execve-qq +threads-execve.test -qq
097fad
Index: strace-5.7/tests-m32/pure_executables.list
097fad
===================================================================
097fad
--- strace-5.7.orig/tests-m32/pure_executables.list	2020-09-09 19:30:36.780885588 +0200
097fad
+++ strace-5.7/tests-m32/pure_executables.list	2020-09-09 19:32:45.309962197 +0200
097fad
@@ -583,6 +583,7 @@
097fad
 sysinfo
097fad
 syslog
097fad
 tee
097fad
+tgkill
097fad
 time
097fad
 timer_create
097fad
 timer_xettime
097fad
Index: strace-5.7/tests-m32/tgkill.c
097fad
===================================================================
097fad
--- /dev/null	1970-01-01 00:00:00.000000000 +0000
097fad
+++ strace-5.7/tests-m32/tgkill.c	2020-09-09 19:32:50.740965435 +0200
097fad
@@ -0,0 +1,69 @@
097fad
+/*
097fad
+ * Check decoding of tgkill syscall.
097fad
+ *
097fad
+ * Copyright (c) 2020 Dmitry V. Levin <ldv@altlinux.org>
097fad
+ * All rights reserved.
097fad
+ *
097fad
+ * SPDX-License-Identifier: GPL-2.0-or-later
097fad
+ */
097fad
+
097fad
+#include "tests.h"
097fad
+#include "scno.h"
097fad
+
097fad
+#ifdef __NR_tgkill
097fad
+
097fad
+# include <signal.h>
097fad
+# include <stdio.h>
097fad
+# include <unistd.h>
097fad
+
097fad
+static const char *errstr;
097fad
+
097fad
+static long
097fad
+k_tgkill(const unsigned int tgid,
097fad
+	 const unsigned int tid,
097fad
+	 const unsigned int sig)
097fad
+{
097fad
+        const kernel_ulong_t fill = (kernel_ulong_t) 0xdefaced00000000ULL;
097fad
+        const kernel_ulong_t bad = (kernel_ulong_t) 0xbadc0dedbadc0dedULL;
097fad
+        const kernel_ulong_t arg1 = fill | tgid;
097fad
+        const kernel_ulong_t arg2 = fill | tid;
097fad
+        const kernel_ulong_t arg3 = fill | sig;
097fad
+        const long rc = syscall(__NR_tgkill, arg1, arg2, arg3, bad, bad, bad);
097fad
+        errstr = sprintrc(rc);
097fad
+        return rc;
097fad
+}
097fad
+
097fad
+int
097fad
+main(void)
097fad
+{
097fad
+	const int pid = getpid();
097fad
+	const int bad_pid = -1;
097fad
+	const int bad_sig = 0xface;
097fad
+
097fad
+	k_tgkill(pid, pid, 0);
097fad
+	printf("tgkill(%d, %d, 0) = %s\n", pid, pid, errstr);
097fad
+
097fad
+	k_tgkill(pid, bad_pid, 0);
097fad
+	printf("tgkill(%d, %d, 0) = %s\n", pid, bad_pid, errstr);
097fad
+
097fad
+	k_tgkill(bad_pid, pid, 0);
097fad
+	printf("tgkill(%d, %d, 0) = %s\n", bad_pid, pid, errstr);
097fad
+
097fad
+	k_tgkill(pid, pid, SIGCONT);
097fad
+	printf("tgkill(%d, %d, SIGCONT) = %s\n", pid, pid, errstr);
097fad
+
097fad
+	k_tgkill(pid, pid, bad_sig);
097fad
+	printf("tgkill(%d, %d, %d) = %s\n", pid, pid, bad_sig, errstr);
097fad
+
097fad
+	k_tgkill(pid, pid, -bad_sig);
097fad
+	printf("tgkill(%d, %d, %d) = %s\n", pid, pid, -bad_sig, errstr);
097fad
+
097fad
+	puts("+++ exited with 0 +++");
097fad
+	return 0;
097fad
+}
097fad
+
097fad
+#else
097fad
+
097fad
+SKIP_MAIN_UNDEFINED("__NR_tgkill")
097fad
+
097fad
+#endif
097fad
Index: strace-5.7/tests-mx32/gen_tests.in
097fad
===================================================================
097fad
--- strace-5.7.orig/tests-mx32/gen_tests.in	2020-09-09 19:30:36.780885588 +0200
097fad
+++ strace-5.7/tests-mx32/gen_tests.in	2020-09-09 19:32:50.740965435 +0200
097fad
@@ -658,6 +658,7 @@
097fad
 sysinfo	-a14
097fad
 syslog	-a35
097fad
 tee
097fad
+tgkill	-a15 --signal='!cont'
097fad
 threads-execve--quiet-thread-execve +threads-execve.test -s40 --quiet=personality,thread-execve
097fad
 threads-execve-q +threads-execve.test -q
097fad
 threads-execve-qq +threads-execve.test -qq
097fad
Index: strace-5.7/tests-mx32/pure_executables.list
097fad
===================================================================
097fad
--- strace-5.7.orig/tests-mx32/pure_executables.list	2020-09-09 19:30:36.780885588 +0200
097fad
+++ strace-5.7/tests-mx32/pure_executables.list	2020-09-09 19:32:45.310962198 +0200
097fad
@@ -583,6 +583,7 @@
097fad
 sysinfo
097fad
 syslog
097fad
 tee
097fad
+tgkill
097fad
 time
097fad
 timer_create
097fad
 timer_xettime
097fad
Index: strace-5.7/tests-mx32/tgkill.c
097fad
===================================================================
097fad
--- /dev/null	1970-01-01 00:00:00.000000000 +0000
097fad
+++ strace-5.7/tests-mx32/tgkill.c	2020-09-09 19:32:50.740965435 +0200
097fad
@@ -0,0 +1,69 @@
097fad
+/*
097fad
+ * Check decoding of tgkill syscall.
097fad
+ *
097fad
+ * Copyright (c) 2020 Dmitry V. Levin <ldv@altlinux.org>
097fad
+ * All rights reserved.
097fad
+ *
097fad
+ * SPDX-License-Identifier: GPL-2.0-or-later
097fad
+ */
097fad
+
097fad
+#include "tests.h"
097fad
+#include "scno.h"
097fad
+
097fad
+#ifdef __NR_tgkill
097fad
+
097fad
+# include <signal.h>
097fad
+# include <stdio.h>
097fad
+# include <unistd.h>
097fad
+
097fad
+static const char *errstr;
097fad
+
097fad
+static long
097fad
+k_tgkill(const unsigned int tgid,
097fad
+	 const unsigned int tid,
097fad
+	 const unsigned int sig)
097fad
+{
097fad
+        const kernel_ulong_t fill = (kernel_ulong_t) 0xdefaced00000000ULL;
097fad
+        const kernel_ulong_t bad = (kernel_ulong_t) 0xbadc0dedbadc0dedULL;
097fad
+        const kernel_ulong_t arg1 = fill | tgid;
097fad
+        const kernel_ulong_t arg2 = fill | tid;
097fad
+        const kernel_ulong_t arg3 = fill | sig;
097fad
+        const long rc = syscall(__NR_tgkill, arg1, arg2, arg3, bad, bad, bad);
097fad
+        errstr = sprintrc(rc);
097fad
+        return rc;
097fad
+}
097fad
+
097fad
+int
097fad
+main(void)
097fad
+{
097fad
+	const int pid = getpid();
097fad
+	const int bad_pid = -1;
097fad
+	const int bad_sig = 0xface;
097fad
+
097fad
+	k_tgkill(pid, pid, 0);
097fad
+	printf("tgkill(%d, %d, 0) = %s\n", pid, pid, errstr);
097fad
+
097fad
+	k_tgkill(pid, bad_pid, 0);
097fad
+	printf("tgkill(%d, %d, 0) = %s\n", pid, bad_pid, errstr);
097fad
+
097fad
+	k_tgkill(bad_pid, pid, 0);
097fad
+	printf("tgkill(%d, %d, 0) = %s\n", bad_pid, pid, errstr);
097fad
+
097fad
+	k_tgkill(pid, pid, SIGCONT);
097fad
+	printf("tgkill(%d, %d, SIGCONT) = %s\n", pid, pid, errstr);
097fad
+
097fad
+	k_tgkill(pid, pid, bad_sig);
097fad
+	printf("tgkill(%d, %d, %d) = %s\n", pid, pid, bad_sig, errstr);
097fad
+
097fad
+	k_tgkill(pid, pid, -bad_sig);
097fad
+	printf("tgkill(%d, %d, %d) = %s\n", pid, pid, -bad_sig, errstr);
097fad
+
097fad
+	puts("+++ exited with 0 +++");
097fad
+	return 0;
097fad
+}
097fad
+
097fad
+#else
097fad
+
097fad
+SKIP_MAIN_UNDEFINED("__NR_tgkill")
097fad
+
097fad
+#endif
097fad
Index: strace-5.7/tests-m32/Makefile.in
097fad
===================================================================
097fad
--- strace-5.7.orig/tests-m32/Makefile.in	2020-09-09 19:32:14.800944013 +0200
097fad
+++ strace-5.7/tests-m32/Makefile.in	2020-09-09 19:49:34.530563739 +0200
097fad
@@ -493,8 +493,8 @@
097fad
 	strace-xx$(EXEEXT) swap$(EXEEXT) sxetmask$(EXEEXT) \
097fad
 	symlink$(EXEEXT) symlinkat$(EXEEXT) sync$(EXEEXT) \
097fad
 	sync_file_range$(EXEEXT) sync_file_range2$(EXEEXT) \
097fad
-	sysinfo$(EXEEXT) syslog$(EXEEXT) tee$(EXEEXT) time$(EXEEXT) \
097fad
-	timer_create$(EXEEXT) timer_xettime$(EXEEXT) \
097fad
+	sysinfo$(EXEEXT) syslog$(EXEEXT) tee$(EXEEXT) tgkill$(EXEEXT) \
097fad
+	time$(EXEEXT) timer_create$(EXEEXT) timer_xettime$(EXEEXT) \
097fad
 	timerfd_xettime$(EXEEXT) times$(EXEEXT) times-fail$(EXEEXT) \
097fad
 	tkill$(EXEEXT) truncate$(EXEEXT) truncate64$(EXEEXT) \
097fad
 	ugetrlimit$(EXEEXT) uio$(EXEEXT) umask$(EXEEXT) \
097fad
@@ -3444,6 +3444,10 @@
097fad
 tee_OBJECTS = tee.$(OBJEXT)
097fad
 tee_LDADD = $(LDADD)
097fad
 tee_DEPENDENCIES = libtests.a
097fad
+tgkill_SOURCES = tgkill.c
097fad
+tgkill_OBJECTS = tgkill.$(OBJEXT)
097fad
+tgkill_LDADD = $(LDADD)
097fad
+tgkill_DEPENDENCIES = libtests.a
097fad
 threads_execve_SOURCES = threads-execve.c
097fad
 threads_execve_OBJECTS = threads-execve.$(OBJEXT)
097fad
 threads_execve_DEPENDENCIES = $(am__DEPENDENCIES_1) $(LDADD)
097fad
@@ -4181,7 +4185,7 @@
097fad
 	./$(DEPDIR)/symlinkat.Po ./$(DEPDIR)/sync.Po \
097fad
 	./$(DEPDIR)/sync_file_range.Po ./$(DEPDIR)/sync_file_range2.Po \
097fad
 	./$(DEPDIR)/sysinfo.Po ./$(DEPDIR)/syslog-success.Po \
097fad
-	./$(DEPDIR)/syslog.Po ./$(DEPDIR)/tee.Po \
097fad
+	./$(DEPDIR)/syslog.Po ./$(DEPDIR)/tee.Po ./$(DEPDIR)/tgkill.Po \
097fad
 	./$(DEPDIR)/threads-execve--quiet-thread-execve.Po \
097fad
 	./$(DEPDIR)/threads-execve-q.Po \
097fad
 	./$(DEPDIR)/threads-execve-qq.Po \
097fad
@@ -4443,7 +4447,7 @@
097fad
 	strace--strings-in-hex-non-ascii.c strace-x.c strace-xx.c \
097fad
 	swap.c sxetmask.c symlink.c symlinkat.c sync.c \
097fad
 	sync_file_range.c sync_file_range2.c sysinfo.c syslog.c \
097fad
-	syslog-success.c tee.c threads-execve.c \
097fad
+	syslog-success.c tee.c tgkill.c threads-execve.c \
097fad
 	threads-execve--quiet-thread-execve.c threads-execve-q.c \
097fad
 	threads-execve-qq.c threads-execve-qqq.c time.c timer_create.c \
097fad
 	timer_xettime.c timerfd_xettime.c times.c times-fail.c tkill.c \
097fad
@@ -4669,7 +4673,7 @@
097fad
 	strace--strings-in-hex-non-ascii.c strace-x.c strace-xx.c \
097fad
 	swap.c sxetmask.c symlink.c symlinkat.c sync.c \
097fad
 	sync_file_range.c sync_file_range2.c sysinfo.c syslog.c \
097fad
-	syslog-success.c tee.c threads-execve.c \
097fad
+	syslog-success.c tee.c tgkill.c threads-execve.c \
097fad
 	threads-execve--quiet-thread-execve.c threads-execve-q.c \
097fad
 	threads-execve-qq.c threads-execve-qqq.c time.c timer_create.c \
097fad
 	timer_xettime.c timerfd_xettime.c times.c times-fail.c tkill.c \
097fad
@@ -5724,6 +5728,7 @@
097fad
   sysinfo \
097fad
   syslog \
097fad
   tee \
097fad
+  tgkill \
097fad
   time \
097fad
   timer_create \
097fad
   timer_xettime \
097fad
@@ -6133,7 +6138,7 @@
097fad
 	strace-xx.gen.test swap.gen.test sxetmask.gen.test \
097fad
 	symlink.gen.test symlinkat.gen.test sync.gen.test \
097fad
 	sync_file_range.gen.test sync_file_range2.gen.test \
097fad
-	sysinfo.gen.test syslog.gen.test tee.gen.test \
097fad
+	sysinfo.gen.test syslog.gen.test tee.gen.test tgkill.gen.test \
097fad
 	threads-execve--quiet-thread-execve.gen.test \
097fad
 	threads-execve-q.gen.test threads-execve-qq.gen.test \
097fad
 	threads-execve-qqq.gen.test time.gen.test \
097fad
@@ -9355,6 +9360,10 @@
097fad
 	@rm -f tee$(EXEEXT)
097fad
 	$(AM_V_CCLD)$(LINK) $(tee_OBJECTS) $(tee_LDADD) $(LIBS)
097fad
 
097fad
+tgkill$(EXEEXT): $(tgkill_OBJECTS) $(tgkill_DEPENDENCIES) $(EXTRA_tgkill_DEPENDENCIES) 
097fad
+	@rm -f tgkill$(EXEEXT)
097fad
+	$(AM_V_CCLD)$(LINK) $(tgkill_OBJECTS) $(tgkill_LDADD) $(LIBS)
097fad
+
097fad
 threads-execve$(EXEEXT): $(threads_execve_OBJECTS) $(threads_execve_DEPENDENCIES) $(EXTRA_threads_execve_DEPENDENCIES) 
097fad
 	@rm -f threads-execve$(EXEEXT)
097fad
 	$(AM_V_CCLD)$(LINK) $(threads_execve_OBJECTS) $(threads_execve_LDADD) $(LIBS)
097fad
@@ -10349,6 +10358,7 @@
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syslog-success.Po@am__quote@ # am--include-marker
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syslog.Po@am__quote@ # am--include-marker
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tee.Po@am__quote@ # am--include-marker
097fad
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tgkill.Po@am__quote@ # am--include-marker
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve--quiet-thread-execve.Po@am__quote@ # am--include-marker
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve-q.Po@am__quote@ # am--include-marker
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve-qq.Po@am__quote@ # am--include-marker
097fad
@@ -12170,6 +12180,7 @@
097fad
 	-rm -f ./$(DEPDIR)/syslog-success.Po
097fad
 	-rm -f ./$(DEPDIR)/syslog.Po
097fad
 	-rm -f ./$(DEPDIR)/tee.Po
097fad
+	-rm -f ./$(DEPDIR)/tgkill.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve--quiet-thread-execve.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve-q.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve-qq.Po
097fad
@@ -13026,6 +13037,7 @@
097fad
 	-rm -f ./$(DEPDIR)/syslog-success.Po
097fad
 	-rm -f ./$(DEPDIR)/syslog.Po
097fad
 	-rm -f ./$(DEPDIR)/tee.Po
097fad
+	-rm -f ./$(DEPDIR)/tgkill.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve--quiet-thread-execve.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve-q.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve-qq.Po
097fad
@@ -15085,6 +15097,9 @@
097fad
 $(srcdir)/tee.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
097fad
 	$(AM_V_GEN) $^ $@
097fad
 
097fad
+$(srcdir)/tgkill.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
097fad
+	$(AM_V_GEN) $^ $@
097fad
+
097fad
 $(srcdir)/threads-execve--quiet-thread-execve.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
097fad
 	$(AM_V_GEN) $^ $@
097fad
 
097fad
Index: strace-5.7/tests-mx32/Makefile.in
097fad
===================================================================
097fad
--- strace-5.7.orig/tests-mx32/Makefile.in	2020-09-09 19:32:39.854958946 +0200
097fad
+++ strace-5.7/tests-mx32/Makefile.in	2020-09-09 19:49:39.557566736 +0200
097fad
@@ -493,8 +493,8 @@
097fad
 	strace-xx$(EXEEXT) swap$(EXEEXT) sxetmask$(EXEEXT) \
097fad
 	symlink$(EXEEXT) symlinkat$(EXEEXT) sync$(EXEEXT) \
097fad
 	sync_file_range$(EXEEXT) sync_file_range2$(EXEEXT) \
097fad
-	sysinfo$(EXEEXT) syslog$(EXEEXT) tee$(EXEEXT) time$(EXEEXT) \
097fad
-	timer_create$(EXEEXT) timer_xettime$(EXEEXT) \
097fad
+	sysinfo$(EXEEXT) syslog$(EXEEXT) tee$(EXEEXT) tgkill$(EXEEXT) \
097fad
+	time$(EXEEXT) timer_create$(EXEEXT) timer_xettime$(EXEEXT) \
097fad
 	timerfd_xettime$(EXEEXT) times$(EXEEXT) times-fail$(EXEEXT) \
097fad
 	tkill$(EXEEXT) truncate$(EXEEXT) truncate64$(EXEEXT) \
097fad
 	ugetrlimit$(EXEEXT) uio$(EXEEXT) umask$(EXEEXT) \
097fad
@@ -3444,6 +3444,10 @@
097fad
 tee_OBJECTS = tee.$(OBJEXT)
097fad
 tee_LDADD = $(LDADD)
097fad
 tee_DEPENDENCIES = libtests.a
097fad
+tgkill_SOURCES = tgkill.c
097fad
+tgkill_OBJECTS = tgkill.$(OBJEXT)
097fad
+tgkill_LDADD = $(LDADD)
097fad
+tgkill_DEPENDENCIES = libtests.a
097fad
 threads_execve_SOURCES = threads-execve.c
097fad
 threads_execve_OBJECTS = threads-execve.$(OBJEXT)
097fad
 threads_execve_DEPENDENCIES = $(am__DEPENDENCIES_1) $(LDADD)
097fad
@@ -4181,7 +4185,7 @@
097fad
 	./$(DEPDIR)/symlinkat.Po ./$(DEPDIR)/sync.Po \
097fad
 	./$(DEPDIR)/sync_file_range.Po ./$(DEPDIR)/sync_file_range2.Po \
097fad
 	./$(DEPDIR)/sysinfo.Po ./$(DEPDIR)/syslog-success.Po \
097fad
-	./$(DEPDIR)/syslog.Po ./$(DEPDIR)/tee.Po \
097fad
+	./$(DEPDIR)/syslog.Po ./$(DEPDIR)/tee.Po ./$(DEPDIR)/tgkill.Po \
097fad
 	./$(DEPDIR)/threads-execve--quiet-thread-execve.Po \
097fad
 	./$(DEPDIR)/threads-execve-q.Po \
097fad
 	./$(DEPDIR)/threads-execve-qq.Po \
097fad
@@ -4443,7 +4447,7 @@
097fad
 	strace--strings-in-hex-non-ascii.c strace-x.c strace-xx.c \
097fad
 	swap.c sxetmask.c symlink.c symlinkat.c sync.c \
097fad
 	sync_file_range.c sync_file_range2.c sysinfo.c syslog.c \
097fad
-	syslog-success.c tee.c threads-execve.c \
097fad
+	syslog-success.c tee.c tgkill.c threads-execve.c \
097fad
 	threads-execve--quiet-thread-execve.c threads-execve-q.c \
097fad
 	threads-execve-qq.c threads-execve-qqq.c time.c timer_create.c \
097fad
 	timer_xettime.c timerfd_xettime.c times.c times-fail.c tkill.c \
097fad
@@ -4669,7 +4673,7 @@
097fad
 	strace--strings-in-hex-non-ascii.c strace-x.c strace-xx.c \
097fad
 	swap.c sxetmask.c symlink.c symlinkat.c sync.c \
097fad
 	sync_file_range.c sync_file_range2.c sysinfo.c syslog.c \
097fad
-	syslog-success.c tee.c threads-execve.c \
097fad
+	syslog-success.c tee.c tgkill.c threads-execve.c \
097fad
 	threads-execve--quiet-thread-execve.c threads-execve-q.c \
097fad
 	threads-execve-qq.c threads-execve-qqq.c time.c timer_create.c \
097fad
 	timer_xettime.c timerfd_xettime.c times.c times-fail.c tkill.c \
097fad
@@ -5724,6 +5728,7 @@
097fad
   sysinfo \
097fad
   syslog \
097fad
   tee \
097fad
+  tgkill \
097fad
   time \
097fad
   timer_create \
097fad
   timer_xettime \
097fad
@@ -6133,7 +6138,7 @@
097fad
 	strace-xx.gen.test swap.gen.test sxetmask.gen.test \
097fad
 	symlink.gen.test symlinkat.gen.test sync.gen.test \
097fad
 	sync_file_range.gen.test sync_file_range2.gen.test \
097fad
-	sysinfo.gen.test syslog.gen.test tee.gen.test \
097fad
+	sysinfo.gen.test syslog.gen.test tee.gen.test tgkill.gen.test \
097fad
 	threads-execve--quiet-thread-execve.gen.test \
097fad
 	threads-execve-q.gen.test threads-execve-qq.gen.test \
097fad
 	threads-execve-qqq.gen.test time.gen.test \
097fad
@@ -9355,6 +9360,10 @@
097fad
 	@rm -f tee$(EXEEXT)
097fad
 	$(AM_V_CCLD)$(LINK) $(tee_OBJECTS) $(tee_LDADD) $(LIBS)
097fad
 
097fad
+tgkill$(EXEEXT): $(tgkill_OBJECTS) $(tgkill_DEPENDENCIES) $(EXTRA_tgkill_DEPENDENCIES) 
097fad
+	@rm -f tgkill$(EXEEXT)
097fad
+	$(AM_V_CCLD)$(LINK) $(tgkill_OBJECTS) $(tgkill_LDADD) $(LIBS)
097fad
+
097fad
 threads-execve$(EXEEXT): $(threads_execve_OBJECTS) $(threads_execve_DEPENDENCIES) $(EXTRA_threads_execve_DEPENDENCIES) 
097fad
 	@rm -f threads-execve$(EXEEXT)
097fad
 	$(AM_V_CCLD)$(LINK) $(threads_execve_OBJECTS) $(threads_execve_LDADD) $(LIBS)
097fad
@@ -10349,6 +10358,7 @@
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syslog-success.Po@am__quote@ # am--include-marker
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syslog.Po@am__quote@ # am--include-marker
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tee.Po@am__quote@ # am--include-marker
097fad
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tgkill.Po@am__quote@ # am--include-marker
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve--quiet-thread-execve.Po@am__quote@ # am--include-marker
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve-q.Po@am__quote@ # am--include-marker
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve-qq.Po@am__quote@ # am--include-marker
097fad
@@ -12170,6 +12180,7 @@
097fad
 	-rm -f ./$(DEPDIR)/syslog-success.Po
097fad
 	-rm -f ./$(DEPDIR)/syslog.Po
097fad
 	-rm -f ./$(DEPDIR)/tee.Po
097fad
+	-rm -f ./$(DEPDIR)/tgkill.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve--quiet-thread-execve.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve-q.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve-qq.Po
097fad
@@ -13026,6 +13037,7 @@
097fad
 	-rm -f ./$(DEPDIR)/syslog-success.Po
097fad
 	-rm -f ./$(DEPDIR)/syslog.Po
097fad
 	-rm -f ./$(DEPDIR)/tee.Po
097fad
+	-rm -f ./$(DEPDIR)/tgkill.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve--quiet-thread-execve.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve-q.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve-qq.Po
097fad
@@ -15085,6 +15097,9 @@
097fad
 $(srcdir)/tee.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
097fad
 	$(AM_V_GEN) $^ $@
097fad
 
097fad
+$(srcdir)/tgkill.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
097fad
+	$(AM_V_GEN) $^ $@
097fad
+
097fad
 $(srcdir)/threads-execve--quiet-thread-execve.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
097fad
 	$(AM_V_GEN) $^ $@
097fad
 
097fad
Index: strace-5.7/tests/Makefile.in
097fad
===================================================================
097fad
--- strace-5.7.orig/tests/Makefile.in	2020-09-09 19:30:36.780885588 +0200
097fad
+++ strace-5.7/tests/Makefile.in	2020-09-09 19:46:24.904450714 +0200
097fad
@@ -493,8 +493,8 @@
097fad
 	strace-xx$(EXEEXT) swap$(EXEEXT) sxetmask$(EXEEXT) \
097fad
 	symlink$(EXEEXT) symlinkat$(EXEEXT) sync$(EXEEXT) \
097fad
 	sync_file_range$(EXEEXT) sync_file_range2$(EXEEXT) \
097fad
-	sysinfo$(EXEEXT) syslog$(EXEEXT) tee$(EXEEXT) time$(EXEEXT) \
097fad
-	timer_create$(EXEEXT) timer_xettime$(EXEEXT) \
097fad
+	sysinfo$(EXEEXT) syslog$(EXEEXT) tee$(EXEEXT) tgkill$(EXEEXT) \
097fad
+	time$(EXEEXT) timer_create$(EXEEXT) timer_xettime$(EXEEXT) \
097fad
 	timerfd_xettime$(EXEEXT) times$(EXEEXT) times-fail$(EXEEXT) \
097fad
 	tkill$(EXEEXT) truncate$(EXEEXT) truncate64$(EXEEXT) \
097fad
 	ugetrlimit$(EXEEXT) uio$(EXEEXT) umask$(EXEEXT) \
097fad
@@ -3444,6 +3444,10 @@
097fad
 tee_OBJECTS = tee.$(OBJEXT)
097fad
 tee_LDADD = $(LDADD)
097fad
 tee_DEPENDENCIES = libtests.a
097fad
+tgkill_SOURCES = tgkill.c
097fad
+tgkill_OBJECTS = tgkill.$(OBJEXT)
097fad
+tgkill_LDADD = $(LDADD)
097fad
+tgkill_DEPENDENCIES = libtests.a
097fad
 threads_execve_SOURCES = threads-execve.c
097fad
 threads_execve_OBJECTS = threads-execve.$(OBJEXT)
097fad
 threads_execve_DEPENDENCIES = $(am__DEPENDENCIES_1) $(LDADD)
097fad
@@ -4181,7 +4185,7 @@
097fad
 	./$(DEPDIR)/symlinkat.Po ./$(DEPDIR)/sync.Po \
097fad
 	./$(DEPDIR)/sync_file_range.Po ./$(DEPDIR)/sync_file_range2.Po \
097fad
 	./$(DEPDIR)/sysinfo.Po ./$(DEPDIR)/syslog-success.Po \
097fad
-	./$(DEPDIR)/syslog.Po ./$(DEPDIR)/tee.Po \
097fad
+	./$(DEPDIR)/syslog.Po ./$(DEPDIR)/tee.Po ./$(DEPDIR)/tgkill.Po \
097fad
 	./$(DEPDIR)/threads-execve--quiet-thread-execve.Po \
097fad
 	./$(DEPDIR)/threads-execve-q.Po \
097fad
 	./$(DEPDIR)/threads-execve-qq.Po \
097fad
@@ -4443,7 +4447,7 @@
097fad
 	strace--strings-in-hex-non-ascii.c strace-x.c strace-xx.c \
097fad
 	swap.c sxetmask.c symlink.c symlinkat.c sync.c \
097fad
 	sync_file_range.c sync_file_range2.c sysinfo.c syslog.c \
097fad
-	syslog-success.c tee.c threads-execve.c \
097fad
+	syslog-success.c tee.c tgkill.c threads-execve.c \
097fad
 	threads-execve--quiet-thread-execve.c threads-execve-q.c \
097fad
 	threads-execve-qq.c threads-execve-qqq.c time.c timer_create.c \
097fad
 	timer_xettime.c timerfd_xettime.c times.c times-fail.c tkill.c \
097fad
@@ -4669,7 +4673,7 @@
097fad
 	strace--strings-in-hex-non-ascii.c strace-x.c strace-xx.c \
097fad
 	swap.c sxetmask.c symlink.c symlinkat.c sync.c \
097fad
 	sync_file_range.c sync_file_range2.c sysinfo.c syslog.c \
097fad
-	syslog-success.c tee.c threads-execve.c \
097fad
+	syslog-success.c tee.c tgkill.c threads-execve.c \
097fad
 	threads-execve--quiet-thread-execve.c threads-execve-q.c \
097fad
 	threads-execve-qq.c threads-execve-qqq.c time.c timer_create.c \
097fad
 	timer_xettime.c timerfd_xettime.c times.c times-fail.c tkill.c \
097fad
@@ -5724,6 +5728,7 @@
097fad
   sysinfo \
097fad
   syslog \
097fad
   tee \
097fad
+  tgkill \
097fad
   time \
097fad
   timer_create \
097fad
   timer_xettime \
097fad
@@ -6133,7 +6138,7 @@
097fad
 	strace-xx.gen.test swap.gen.test sxetmask.gen.test \
097fad
 	symlink.gen.test symlinkat.gen.test sync.gen.test \
097fad
 	sync_file_range.gen.test sync_file_range2.gen.test \
097fad
-	sysinfo.gen.test syslog.gen.test tee.gen.test \
097fad
+	sysinfo.gen.test syslog.gen.test tee.gen.test tgkill.gen.test \
097fad
 	threads-execve--quiet-thread-execve.gen.test \
097fad
 	threads-execve-q.gen.test threads-execve-qq.gen.test \
097fad
 	threads-execve-qqq.gen.test time.gen.test \
097fad
@@ -9355,6 +9360,10 @@
097fad
 	@rm -f tee$(EXEEXT)
097fad
 	$(AM_V_CCLD)$(LINK) $(tee_OBJECTS) $(tee_LDADD) $(LIBS)
097fad
 
097fad
+tgkill$(EXEEXT): $(tgkill_OBJECTS) $(tgkill_DEPENDENCIES) $(EXTRA_tgkill_DEPENDENCIES) 
097fad
+	@rm -f tgkill$(EXEEXT)
097fad
+	$(AM_V_CCLD)$(LINK) $(tgkill_OBJECTS) $(tgkill_LDADD) $(LIBS)
097fad
+
097fad
 threads-execve$(EXEEXT): $(threads_execve_OBJECTS) $(threads_execve_DEPENDENCIES) $(EXTRA_threads_execve_DEPENDENCIES) 
097fad
 	@rm -f threads-execve$(EXEEXT)
097fad
 	$(AM_V_CCLD)$(LINK) $(threads_execve_OBJECTS) $(threads_execve_LDADD) $(LIBS)
097fad
@@ -10349,6 +10358,7 @@
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syslog-success.Po@am__quote@ # am--include-marker
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syslog.Po@am__quote@ # am--include-marker
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tee.Po@am__quote@ # am--include-marker
097fad
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tgkill.Po@am__quote@ # am--include-marker
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve--quiet-thread-execve.Po@am__quote@ # am--include-marker
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve-q.Po@am__quote@ # am--include-marker
097fad
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/threads-execve-qq.Po@am__quote@ # am--include-marker
097fad
@@ -12170,6 +12180,7 @@
097fad
 	-rm -f ./$(DEPDIR)/syslog-success.Po
097fad
 	-rm -f ./$(DEPDIR)/syslog.Po
097fad
 	-rm -f ./$(DEPDIR)/tee.Po
097fad
+	-rm -f ./$(DEPDIR)/tgkill.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve--quiet-thread-execve.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve-q.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve-qq.Po
097fad
@@ -13026,6 +13037,7 @@
097fad
 	-rm -f ./$(DEPDIR)/syslog-success.Po
097fad
 	-rm -f ./$(DEPDIR)/syslog.Po
097fad
 	-rm -f ./$(DEPDIR)/tee.Po
097fad
+	-rm -f ./$(DEPDIR)/tgkill.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve--quiet-thread-execve.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve-q.Po
097fad
 	-rm -f ./$(DEPDIR)/threads-execve-qq.Po
097fad
@@ -15085,6 +15097,9 @@
097fad
 $(srcdir)/tee.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
097fad
 	$(AM_V_GEN) $^ $@
097fad
 
097fad
+$(srcdir)/tgkill.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
097fad
+	$(AM_V_GEN) $^ $@
097fad
+
097fad
 $(srcdir)/threads-execve--quiet-thread-execve.gen.test: $(abs_srcdir)/gen_tests.sh $(srcdir)/gen_tests.in
097fad
 	$(AM_V_GEN) $^ $@
097fad