[LTP] [PATCH] linux_syscall_numbers: add syscall number to output

Jan Stancek jstancek@redhat.com
Mon Dec 7 10:37:37 CET 2015


Some tests don't pass __NR_* as argument directly, but use a variable.
Because ltp_syscall is a macro that stringifies "NR" argument we get
output such as: "syscall tests[i].syscall not supported on your arch".

Add syscall number to output as well.

Signed-off-by: Jan Stancek <jstancek@redhat.com>
---
 testcases/kernel/include/regen.sh | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/testcases/kernel/include/regen.sh b/testcases/kernel/include/regen.sh
index 9efc4f17cf88..f93f49b7753f 100755
--- a/testcases/kernel/include/regen.sh
+++ b/testcases/kernel/include/regen.sh
@@ -44,7 +44,8 @@ cat << EOF > "${output_pid}"
 	} \\
 	if (__ret == -1 && errno == ENOSYS) { \\
 		tst_brkm(TCONF, CLEANUP, \\
-			"syscall " #NR " not supported on your arch"); \\
+			"syscall(%d) " #NR " not supported on your arch", \\
+			NR); \\
 		errno = ENOSYS; \\
 	} \\
 	__ret; \\
-- 
1.8.3.1



More information about the Ltp mailing list