Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/tests/kernel PT_GET_SIGINFO is no longer PT_SET_SIGINFO cond...



details:   https://anonhg.NetBSD.org/src/rev/478b0296ae60
branches:  trunk
changeset: 820430:478b0296ae60
user:      kamil <kamil%NetBSD.org@localhost>
date:      Mon Jan 09 22:09:20 2017 +0000

description:
PT_GET_SIGINFO is no longer PT_SET_SIGINFO conditional in ATF tests

This interface is MI.

Sponsored by <The NetBSD Foundation>

diffstat:

 tests/kernel/t_ptrace_wait.c |  26 +++++++++-----------------
 tests/kernel/t_ptrace_wait.h |  14 +-------------
 2 files changed, 10 insertions(+), 30 deletions(-)

diffs (117 lines):

diff -r 82a35938a0dc -r 478b0296ae60 tests/kernel/t_ptrace_wait.c
--- a/tests/kernel/t_ptrace_wait.c      Mon Jan 09 21:17:29 2017 +0000
+++ b/tests/kernel/t_ptrace_wait.c      Mon Jan 09 22:09:20 2017 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: t_ptrace_wait.c,v 1.50 2017/01/06 22:40:06 kamil Exp $ */
+/*     $NetBSD: t_ptrace_wait.c,v 1.51 2017/01/09 22:09:20 kamil Exp $ */
 
 /*-
  * Copyright (c) 2016 The NetBSD Foundation, Inc.
@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: t_ptrace_wait.c,v 1.50 2017/01/06 22:40:06 kamil Exp $");
+__RCSID("$NetBSD: t_ptrace_wait.c,v 1.51 2017/01/09 22:09:20 kamil Exp $");
 
 #include <sys/param.h>
 #include <sys/types.h>
@@ -4458,7 +4458,6 @@
 }
 #endif
 
-#if defined(HAVE_SIGINFO)
 ATF_TC(siginfo1);
 ATF_TC_HEAD(siginfo1, tc)
 {
@@ -4516,9 +4515,7 @@
        printf("Before calling %s() for the child\n", TWAIT_FNAME);
        TWAIT_REQUIRE_FAILURE(ECHILD, wpid = TWAIT_GENERIC(child, &status, 0));
 }
-#endif
-
-#if defined(HAVE_SIGINFO)
+
 ATF_TC(siginfo2);
 ATF_TC_HEAD(siginfo2, tc)
 {
@@ -4599,9 +4596,7 @@
        printf("Before calling %s() for the child\n", TWAIT_FNAME);
        TWAIT_REQUIRE_FAILURE(ECHILD, wpid = TWAIT_GENERIC(child, &status, 0));
 }
-#endif
-
-#if defined(HAVE_SIGINFO)
+
 ATF_TC(siginfo3);
 ATF_TC_HEAD(siginfo3, tc)
 {
@@ -4699,9 +4694,7 @@
        printf("Before calling %s() for the child\n", TWAIT_FNAME);
        TWAIT_REQUIRE_FAILURE(ECHILD, wpid = TWAIT_GENERIC(child, &status, 0));
 }
-#endif
-
-#if defined(HAVE_SIGINFO)
+
 ATF_TC(siginfo4);
 ATF_TC_HEAD(siginfo4, tc)
 {
@@ -4759,7 +4752,6 @@
        printf("Before calling %s() for the child\n", TWAIT_FNAME);
        TWAIT_REQUIRE_FAILURE(ECHILD, wpid = TWAIT_GENERIC(child, &status, 0));
 }
-#endif
 
 ATF_TP_ADD_TCS(tp)
 {
@@ -4843,10 +4835,10 @@
        ATF_TP_ADD_TC(tp, lwpinfo1);
        ATF_TP_ADD_TC_HAVE_PID(tp, lwpinfo2);
 
-       ATF_TP_ADD_TC_HAVE_SIGINFO(tp, siginfo1);
-       ATF_TP_ADD_TC_HAVE_SIGINFO(tp, siginfo2);
-       ATF_TP_ADD_TC_HAVE_SIGINFO(tp, siginfo3);
-       ATF_TP_ADD_TC_HAVE_SIGINFO(tp, siginfo4);
+       ATF_TP_ADD_TC(tp, siginfo1);
+       ATF_TP_ADD_TC(tp, siginfo2);
+       ATF_TP_ADD_TC(tp, siginfo3);
+       ATF_TP_ADD_TC(tp, siginfo4);
 
        return atf_no_error();
 }
diff -r 82a35938a0dc -r 478b0296ae60 tests/kernel/t_ptrace_wait.h
--- a/tests/kernel/t_ptrace_wait.h      Mon Jan 09 21:17:29 2017 +0000
+++ b/tests/kernel/t_ptrace_wait.h      Mon Jan 09 22:09:20 2017 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: t_ptrace_wait.h,v 1.6 2017/01/04 22:27:20 kamil Exp $  */
+/*     $NetBSD: t_ptrace_wait.h,v 1.7 2017/01/09 22:09:20 kamil Exp $  */
 
 /*-
  * Copyright (c) 2016 The NetBSD Foundation, Inc.
@@ -196,12 +196,6 @@
 #define HAVE_DBREGS
 #endif
 
-/* Add guards for siginfo_t accessors */
-#if defined(PT_GET_SIGINFO)            \
-    && defined(PT_SET_SIGINFO)
-#define HAVE_SIGINFO
-#endif
-
 /*
  * If waitid(2) returns because one or more processes have a state change to
  * report, 0 is returned.  If an error is detected, a value of -1 is returned
@@ -430,12 +424,6 @@
 #define ATF_TP_ADD_TC_PT_STEP(a,b)
 #endif
 
-#if defined(HAVE_SIGINFO)
-#define ATF_TP_ADD_TC_HAVE_SIGINFO(a,b)        ATF_TP_ADD_TC(a,b)
-#else
-#define ATF_TP_ADD_TC_HAVE_SIGINFO(a,b)
-#endif
-
 #if defined(__HAVE_PTRACE_WATCHPOINTS)
 #define ATF_TP_ADD_TC_HAVE_PTRACE_WATCHPOINTS(a,b)     ATF_TP_ADD_TC(a,b)
 #else



Home | Main Index | Thread Index | Old Index