syscalls/rt_sigqueueinfo01: rewrote testcase
PATCH v3 1/1 syscalls/rt_sigqueueinfo01: rewrote testcase
The previous implementation only tested if the syscall can be called at all. Now it also checks if the correct signal and data is sent and received.
---
Notes:
Kept header file in case of future additions.
Other than that: included all suggestions from v2 of this patch.
+ added solution to avoid 'tst_brk(TFAIL, ...)'
testcases/kernel/syscalls/rt_sigqueueinfo/Makefile | 2 + .../syscalls/rt_sigqueueinfo/rt_sigqueueinfo.h | 17 ++ .../syscalls/rt_sigqueueinfo/rt_sigqueueinfo01.c | 189 +++++++++++---------- 3 files changed, 121 insertions(+), 87 deletions(-) create mode 100644 testcases/kernel/syscalls/rt_sigqueueinfo/rt_sigqueueinfo.h
testcases/kernel/syscalls/rt_sigqueueinfo/Makefile +2 -0
@@ -21,3 +21,5 @@ top_srcdir ?= ../../../.. include $(top_srcdir)/include/mk/testcases.mk include $(top_srcdir)/include/mk/generic_leaf_target.mk + +rt_sigqueueinfo01: CFLAGS += -pthread
testcases/kernel/syscalls/rt_sigqueueinfo/rt_sigqueueinfo.h new file +17 -0
@@ -0,0 +1,17 @@ +// SPDX-License-Identifier: GPL-2.0-or-later +/* +* Copyright (c) 2019 SUSE LLC +* Author: Christian Amann <[email protected]> +*/ + +#ifndef __RT_SIGQUEUEINFO_H__ +#define __RT_SIGQUEUEINFO_H__ + +#include "lapi/syscalls.h" + +static int sys_rt_sigqueueinfo (pid_t tgid,int sig,siginfo_t *uinfo) +{ +return tst_syscall (__NR_rt_sigqueueinfo, tgid, sig, uinfo); +} + +#endif /* __RT_SIGQUEUEINFO_H__ */
testcases/kernel/syscalls/rt_sigqueueinfo/rt_sigqueueinfo01.c +102 -87
204 lines not on this page · raw message
Signature · 1 line
2.16.4
PATCH v3 1/1 syscalls/rt_sigqueueinfo01: rewrote testcase
Hi Christian,
Quoted 5 lines
The previous implementation only tested if the syscall can be called at all. Now it also checks if the correct signal and data is sent and received.
Signed-off-by Christian Amann <[email protected]>
Kind regards,
Petr
Petr Vorel
AppliedPATCH v3 1/1 syscalls/rt_sigqueueinfo01: rewrote testcase
Hi Christian,
Quoted 6 lines
Quoted 5 lines
The previous implementation only tested if the syscall can be called at all. Now it also checks if the correct signal and data is sent and received.
Signed-off-by Christian Amann <[email protected]>Acked-by Petr Vorel <[email protected]>
Merged, thanks for your work!
Kind regards,
Petr