summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--etc/mtree/BSD.tests.dist4
-rw-r--r--tests/freebsd_test_suite/macros.h53
-rw-r--r--tests/sys/Makefile2
-rw-r--r--tests/sys/aio/Makefile16
-rw-r--r--tests/sys/aio/aio_kqueue_test.c (renamed from tools/regression/aio/kqueue/aio_kqueue.c)36
-rw-r--r--tests/sys/aio/aio_test.c (renamed from tools/regression/aio/aiotest/aiotest.c)246
-rw-r--r--tests/sys/aio/lio_kqueue_test.c (renamed from tools/regression/aio/kqueue/lio/lio_kqueue.c)22
-rw-r--r--tests/sys/mqueue/Makefile22
-rw-r--r--tests/sys/mqueue/mqtest1.c (renamed from tools/regression/mqueue/mqtest1/mqtest1.c)7
-rw-r--r--tests/sys/mqueue/mqtest2.c (renamed from tools/regression/mqueue/mqtest2/mqtest2.c)18
-rw-r--r--tests/sys/mqueue/mqtest3.c (renamed from tools/regression/mqueue/mqtest3/mqtest3.c)23
-rw-r--r--tests/sys/mqueue/mqtest4.c (renamed from tools/regression/mqueue/mqtest4/mqtest4.c)25
-rw-r--r--tests/sys/mqueue/mqtest5.c (renamed from tools/regression/mqueue/mqtest5/mqtest5.c)18
-rwxr-xr-xtests/sys/mqueue/mqueue_test.sh81
-rw-r--r--tools/regression/aio/aiotest/Makefile11
-rw-r--r--tools/regression/aio/kqueue/Makefile10
-rw-r--r--tools/regression/aio/kqueue/lio/Makefile8
-rw-r--r--tools/regression/mqueue/Makefile5
-rw-r--r--tools/regression/mqueue/mqtest1/Makefile9
-rw-r--r--tools/regression/mqueue/mqtest2/Makefile9
-rw-r--r--tools/regression/mqueue/mqtest3/Makefile9
-rw-r--r--tools/regression/mqueue/mqtest4/Makefile9
-rw-r--r--tools/regression/mqueue/mqtest5/Makefile9
23 files changed, 371 insertions, 281 deletions
diff --git a/etc/mtree/BSD.tests.dist b/etc/mtree/BSD.tests.dist
index e575efe..26afe34 100644
--- a/etc/mtree/BSD.tests.dist
+++ b/etc/mtree/BSD.tests.dist
@@ -178,6 +178,8 @@
..
..
sys
+ aio
+ ..
fifo
..
file
@@ -186,6 +188,8 @@
..
kqueue
..
+ mqueue
+ ..
netinet
..
pjdfstest
diff --git a/tests/freebsd_test_suite/macros.h b/tests/freebsd_test_suite/macros.h
new file mode 100644
index 0000000..755a994
--- /dev/null
+++ b/tests/freebsd_test_suite/macros.h
@@ -0,0 +1,53 @@
+/*-
+ * Copyright (c) 2015 EMC / Isilon Storage Division
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * $FreeBSD$
+ */
+
+#ifndef _FREEBSD_TEST_MACROS_H_
+#define _FREEBSD_TEST_MACROS_H_
+
+#include <sys/param.h>
+#include <sys/module.h>
+#include <string.h>
+#include <err.h>
+#include <errno.h>
+
+#include <atf-c.h>
+
+#define ATF_REQUIRE_KERNEL_MODULE(_mod_name) do { \
+ ATF_REQUIRE_MSG(modfind(_mod_name) != -1, \
+ "module %s could not be resolved: %s", \
+ _mod_name, strerror(errno)); \
+} while(0)
+
+#define PLAIN_REQUIRE_KERNEL_MODULE(_mod_name, _exit_code) do { \
+ if (modfind(_mod_name) == -1) { \
+ err(_exit_code, "module %s could not be resolved", \
+ _mod_name); \
+ } \
+} while(0)
+
+#endif
diff --git a/tests/sys/Makefile b/tests/sys/Makefile
index a1a8239..3f621ea 100644
--- a/tests/sys/Makefile
+++ b/tests/sys/Makefile
@@ -4,10 +4,12 @@
TESTSDIR= ${TESTSBASE}/sys
+TESTS_SUBDIRS+= aio
TESTS_SUBDIRS+= fifo
TESTS_SUBDIRS+= file
TESTS_SUBDIRS+= kern
TESTS_SUBDIRS+= kqueue
+TESTS_SUBDIRS+= mqueue
TESTS_SUBDIRS+= netinet
TESTS_SUBDIRS+= vm
diff --git a/tests/sys/aio/Makefile b/tests/sys/aio/Makefile
new file mode 100644
index 0000000..851252d
--- /dev/null
+++ b/tests/sys/aio/Makefile
@@ -0,0 +1,16 @@
+# $FreeBSD$
+
+TESTSDIR= ${TESTSBASE}/sys/aio
+
+PLAIN_TESTS_C+= aio_kqueue_test
+PLAIN_TESTS_C+= lio_kqueue_test
+ATF_TESTS_C+= aio_test
+
+DPADD.aio_test+= ${LIBUTIL}
+LDADD.aio_test+= -lutil
+
+CFLAGS+= -I${.CURDIR:H:H}
+
+WARNS?= 6
+
+.include <bsd.test.mk>
diff --git a/tools/regression/aio/kqueue/aio_kqueue.c b/tests/sys/aio/aio_kqueue_test.c
index 87b4125..14e4729 100644
--- a/tools/regression/aio/kqueue/aio_kqueue.c
+++ b/tests/sys/aio/aio_kqueue_test.c
@@ -46,25 +46,29 @@
#include <string.h>
#include <unistd.h>
-#define PATH_TEMPLATE "/tmp/aio.XXXXXXXXXX"
+#include "freebsd_test_suite/macros.h"
-#define MAX 128
+#define PATH_TEMPLATE "aio.XXXXXXXXXX"
+
+#define MAX_IOCBS 128
#define MAX_RUNS 300
/* #define DEBUG */
int
main (int argc, char *argv[])
{
- int fd;
- struct aiocb *iocb[MAX], *kq_iocb;
- int i, result, run, error, j;
- char buffer[32768];
- int kq = kqueue();
+ struct aiocb *iocb[MAX_IOCBS], *kq_iocb;
+ char *file, pathname[sizeof(PATH_TEMPLATE)+1];
struct kevent ke, kq_returned;
struct timespec ts;
- int cancel, pending, tmp_file = 0, failed = 0;
- char *file, pathname[sizeof(PATH_TEMPLATE)+1];
+ char buffer[32768];
+ int cancel, error, failed = 0, fd, kq, pending, result, run;
+ int tmp_file = 0;
+ unsigned i, j;
+
+ PLAIN_REQUIRE_KERNEL_MODULE("aio", 0);
+ kq = kqueue();
if (kq < 0) {
perror("No kqeueue\n");
exit(1);
@@ -86,7 +90,7 @@ main (int argc, char *argv[])
#ifdef DEBUG
printf("Run %d\n", run);
#endif
- for (i = 0; i < MAX; i++) {
+ for (i = 0; i < nitems(iocb); i++) {
iocb[i] = (struct aiocb *)calloc(1,
sizeof(struct aiocb));
if (iocb[i] == NULL)
@@ -94,7 +98,7 @@ main (int argc, char *argv[])
}
pending = 0;
- for (i = 0; i < MAX; i++) {
+ for (i = 0; i < nitems(iocb); i++) {
pending++;
iocb[i]->aio_nbytes = sizeof(buffer);
iocb[i]->aio_buf = buffer;
@@ -129,8 +133,8 @@ main (int argc, char *argv[])
}
}
}
- cancel = MAX - pending;
-
+ cancel = nitems(iocb) - pending;
+
i = 0;
while (pending) {
@@ -159,11 +163,11 @@ main (int argc, char *argv[])
break;
#ifdef DEBUG
printf("Try again left %d out of %d %d\n",
- pending, MAX, cancel);
+ pending, nitems(iocb), cancel);
#endif
}
- for (j = 0; j < MAX && iocb[j] != kq_iocb;
+ for (j = 0; j < nitems(iocb) && iocb[j] != kq_iocb;
j++) ;
#ifdef DEBUG
printf("kq_iocb %p\n", kq_iocb);
@@ -190,7 +194,7 @@ main (int argc, char *argv[])
i++;
}
- for (i = 0; i < MAX; i++)
+ for (i = 0; i < nitems(iocb); i++)
free(iocb[i]);
}
diff --git a/tools/regression/aio/aiotest/aiotest.c b/tests/sys/aio/aio_test.c
index 6a3d612..4134e78 100644
--- a/tools/regression/aio/aiotest/aiotest.c
+++ b/tests/sys/aio/aio_test.c
@@ -57,7 +57,11 @@
#include <termios.h>
#include <unistd.h>
-#define PATH_TEMPLATE "/tmp/aio.XXXXXXXXXX"
+#include <atf-c.h>
+
+#include "freebsd_test_suite/macros.h"
+
+#define PATH_TEMPLATE "aio.XXXXXXXXXX"
/*
* GLOBAL_MAX sets the largest usable buffer size to be read and written, as
@@ -69,7 +73,6 @@
#define BUFFER_MAX GLOBAL_MAX
struct aio_context {
- const char *ac_test;
int ac_read_fd, ac_write_fd;
long ac_seed;
char ac_buffer[GLOBAL_MAX];
@@ -81,16 +84,6 @@ struct aio_context {
static int aio_timedout;
-static void
-aio_available(void)
-{
-
- if (modfind("aio") == -1)
- errx(0,
- "aio support not available in the kernel; skipping "
- "testcases");
-}
-
/*
* Each test run specifies a timeout in seconds. Use the somewhat obsoleted
* signal(3) and alarm(3) APIs to set this up.
@@ -103,23 +96,21 @@ aio_timeout_signal(int sig __unused)
}
static void
-aio_timeout_start(const char *string1, const char *string2, int seconds)
+aio_timeout_start(int seconds)
{
aio_timedout = 0;
- if (signal(SIGALRM, aio_timeout_signal) == SIG_ERR)
- errx(1, "FAIL: %s: %s: aio_timeout_set: signal(SIGALRM): %s",
- string1, string2, strerror(errno));
+ ATF_REQUIRE_MSG(signal(SIGALRM, aio_timeout_signal) != SIG_ERR,
+ "failed to set SIGALRM handler: %s", strerror(errno));
alarm(seconds);
}
static void
-aio_timeout_stop(const char *string1, const char *string2)
+aio_timeout_stop(void)
{
- if (signal(SIGALRM, NULL) == SIG_ERR)
- errx(1, "FAIL: %s: %s: aio_timeout_stop: signal(NULL): %s",
- string1, string2, strerror(errno));
+ ATF_REQUIRE_MSG(signal(SIGALRM, NULL) != SIG_ERR,
+ "failed to reset SIGALRM handler to default: %s", strerror(errno));
alarm(0);
}
@@ -164,25 +155,23 @@ aio_test_buffer(char *buffer, int len, long seed)
* test setup.
*/
static void
-aio_context_init(struct aio_context *ac, const char *test, int read_fd,
+aio_context_init(struct aio_context *ac, int read_fd,
int write_fd, int buflen, int seconds, void (*cleanup)(void *),
void *cleanup_arg)
{
- if (buflen > BUFFER_MAX)
- errx(1, "FAIL: %s: aio_context_init: buffer too large",
- test);
+ ATF_REQUIRE_MSG(buflen <= BUFFER_MAX,
+ "aio_context_init: buffer too large (%d > %d)",
+ buflen, BUFFER_MAX);
bzero(ac, sizeof(*ac));
- ac->ac_test = test;
ac->ac_read_fd = read_fd;
ac->ac_write_fd = write_fd;
ac->ac_buflen = buflen;
srandomdev();
ac->ac_seed = random();
aio_fill_buffer(ac->ac_buffer, buflen, ac->ac_seed);
- if (aio_test_buffer(ac->ac_buffer, buflen, ac->ac_seed) == 0)
- errx(1, "%s: aio_context_init: aio_test_buffer: internal "
- "error", test);
+ ATF_REQUIRE_MSG(aio_test_buffer(ac->ac_buffer, buflen,
+ ac->ac_seed) != 0, "aio_test_buffer: internal error");
ac->ac_seconds = seconds;
ac->ac_cleanup = cleanup;
ac->ac_cleanup_arg = cleanup_arg;
@@ -215,7 +204,7 @@ aio_write_test(struct aio_context *ac)
struct aiocb aio, *aiop;
ssize_t len;
- aio_available();
+ ATF_REQUIRE_KERNEL_MODULE("aio");
bzero(&aio, sizeof(aio));
aio.aio_buf = ac->ac_buffer;
@@ -223,19 +212,17 @@ aio_write_test(struct aio_context *ac)
aio.aio_fildes = ac->ac_write_fd;
aio.aio_offset = 0;
- aio_timeout_start(ac->ac_test, "aio_write_test", ac->ac_seconds);
+ aio_timeout_start(ac->ac_seconds);
if (aio_write(&aio) < 0) {
if (errno == EINTR) {
if (aio_timedout) {
aio_cleanup(ac);
- errx(1, "FAIL: %s: aio_write_test: "
- "aio_write: timed out", ac->ac_test);
+ atf_tc_fail("aio_write timed out");
}
}
aio_cleanup(ac);
- errx(1, "FAIL: %s: aio_write_test: aio_write: %s",
- ac->ac_test, strerror(errno));
+ atf_tc_fail("aio_write failed: %s", strerror(errno));
}
len = aio_waitcomplete(&aiop, NULL);
@@ -243,22 +230,19 @@ aio_write_test(struct aio_context *ac)
if (errno == EINTR) {
if (aio_timedout) {
aio_cleanup(ac);
- errx(1, "FAIL: %s: aio_write_test: "
- "aio_waitcomplete: timed out",
- ac->ac_test);
+ atf_tc_fail("aio_waitcomplete timed out");
}
}
aio_cleanup(ac);
- errx(1, "FAIL: %s: aio_write_test: aio_waitcomplete: %s",
- ac->ac_test, strerror(errno));
+ atf_tc_fail("aio_waitcomplete failed: %s", strerror(errno));
}
- aio_timeout_stop(ac->ac_test, "aio_write_test");
+ aio_timeout_stop();
if (len != ac->ac_buflen) {
aio_cleanup(ac);
- errx(1, "FAIL: %s: aio_write_test: aio_waitcomplete: short "
- "write (%jd)", ac->ac_test, (intmax_t)len);
+ atf_tc_fail("aio_waitcomplete short write (%jd)",
+ (intmax_t)len);
}
}
@@ -272,7 +256,7 @@ aio_read_test(struct aio_context *ac)
struct aiocb aio, *aiop;
ssize_t len;
- aio_available();
+ ATF_REQUIRE_KERNEL_MODULE("aio");
bzero(ac->ac_buffer, ac->ac_buflen);
bzero(&aio, sizeof(aio));
@@ -281,19 +265,17 @@ aio_read_test(struct aio_context *ac)
aio.aio_fildes = ac->ac_read_fd;
aio.aio_offset = 0;
- aio_timeout_start(ac->ac_test, "aio_read_test", ac->ac_seconds);
+ aio_timeout_start(ac->ac_seconds);
if (aio_read(&aio) < 0) {
if (errno == EINTR) {
if (aio_timedout) {
aio_cleanup(ac);
- errx(1, "FAIL: %s: aio_read_test: "
- "aio_read: timed out", ac->ac_test);
+ atf_tc_fail("aio_write timed out");
}
}
aio_cleanup(ac);
- errx(1, "FAIL: %s: aio_read_test: aio_read %s", ac->ac_test,
- strerror(errno));
+ atf_tc_fail("aio_read failed: %s", strerror(errno));
}
len = aio_waitcomplete(&aiop, NULL);
@@ -301,28 +283,24 @@ aio_read_test(struct aio_context *ac)
if (errno == EINTR) {
if (aio_timedout) {
aio_cleanup(ac);
- errx(1, "FAIL: %s: aio_read_test: "
- "aio_waitcomplete: timed out",
- ac->ac_test);
+ atf_tc_fail("aio_waitcomplete timed out");
}
}
aio_cleanup(ac);
- errx(1, "FAIL: %s: aio_read_test: aio_waitcomplete: %s",
- ac->ac_test, strerror(errno));
+ atf_tc_fail("aio_waitcomplete failed: %s", strerror(errno));
}
- aio_timeout_stop(ac->ac_test, "aio_read_test");
+ aio_timeout_stop();
if (len != ac->ac_buflen) {
aio_cleanup(ac);
- errx(1, "FAIL: %s: aio_read_test: aio_waitcomplete: short "
- "read (%jd)", ac->ac_test, (intmax_t)len);
+ atf_tc_fail("aio_waitcomplete short read (%jd)",
+ (intmax_t)len);
}
if (aio_test_buffer(ac->ac_buffer, ac->ac_buflen, ac->ac_seed) == 0) {
aio_cleanup(ac);
- errx(1, "FAIL: %s: aio_read_test: buffer mismatch",
- ac->ac_test);
+ atf_tc_fail("buffer mismatched");
}
}
@@ -353,33 +331,29 @@ aio_file_cleanup(void *arg)
#define FILE_LEN GLOBAL_MAX
#define FILE_TIMEOUT 30
-static void
-aio_file_test(void)
+ATF_TC_WITHOUT_HEAD(aio_file_test);
+ATF_TC_BODY(aio_file_test, tc)
{
char pathname[PATH_MAX];
struct aio_file_arg arg;
struct aio_context ac;
int fd;
- aio_available();
+ ATF_REQUIRE_KERNEL_MODULE("aio");
strcpy(pathname, PATH_TEMPLATE);
fd = mkstemp(pathname);
- if (fd == -1)
- errx(1, "FAIL: aio_file_test: mkstemp: %s",
- strerror(errno));
+ ATF_REQUIRE_MSG(fd != -1, "mkstemp failed: %s", strerror(errno));
arg.afa_fd = fd;
arg.afa_pathname = pathname;
- aio_context_init(&ac, "aio_file_test", fd, fd, FILE_LEN,
+ aio_context_init(&ac, fd, fd, FILE_LEN,
FILE_TIMEOUT, aio_file_cleanup, &arg);
aio_write_test(&ac);
aio_read_test(&ac);
aio_file_cleanup(&arg);
-
- fprintf(stderr, "PASS: aio_file_test\n");
}
struct aio_fifo_arg {
@@ -403,15 +377,15 @@ aio_fifo_cleanup(void *arg)
#define FIFO_LEN 256
#define FIFO_TIMEOUT 30
-static void
-aio_fifo_test(void)
+ATF_TC_WITHOUT_HEAD(aio_fifo_test);
+ATF_TC_BODY(aio_fifo_test, tc)
{
int error, read_fd = -1, write_fd = -1;
struct aio_fifo_arg arg;
char pathname[PATH_MAX];
struct aio_context ac;
- aio_available();
+ ATF_REQUIRE_KERNEL_MODULE("aio");
/*
* In theory, mkstemp() can return a name that is then collided with.
@@ -419,12 +393,12 @@ aio_fifo_test(void)
* rather than retrying.
*/
strcpy(pathname, PATH_TEMPLATE);
- if (mkstemp(pathname) == -1)
- err(1, "FAIL: aio_fifo_test: mkstemp failed");
- if (unlink(pathname) == -1)
- err(1, "FAIL: aio_fifo_test: unlink failed");
- if (mkfifo(pathname, 0600) == -1)
- errx(1, "FAIL: aio_fifo_test: mkfifo: %s", strerror(errno));
+ ATF_REQUIRE_MSG(mkstemp(pathname) != -1,
+ "mkstemp failed: %s", strerror(errno));
+ ATF_REQUIRE_MSG(unlink(pathname) == 0,
+ "unlink failed: %s", strerror(errno));
+ ATF_REQUIRE_MSG(mkfifo(pathname, 0600) != -1,
+ "mkfifo failed: %s", strerror(errno));
arg.afa_pathname = pathname;
arg.afa_read_fd = -1;
arg.afa_write_fd = -1;
@@ -434,7 +408,7 @@ aio_fifo_test(void)
error = errno;
aio_fifo_cleanup(&arg);
errno = error;
- errx(1, "FAIL: aio_fifo_test: read_fd open: %s",
+ atf_tc_fail("read_fd open failed: %s",
strerror(errno));
}
arg.afa_read_fd = read_fd;
@@ -444,19 +418,17 @@ aio_fifo_test(void)
error = errno;
aio_fifo_cleanup(&arg);
errno = error;
- errx(1, "FAIL: aio_fifo_test: write_fd open: %s",
+ atf_tc_fail("write_fd open failed: %s",
strerror(errno));
}
arg.afa_write_fd = write_fd;
- aio_context_init(&ac, "aio_fifo_test", read_fd, write_fd, FIFO_LEN,
+ aio_context_init(&ac, read_fd, write_fd, FIFO_LEN,
FIFO_TIMEOUT, aio_fifo_cleanup, &arg);
aio_write_test(&ac);
aio_read_test(&ac);
aio_fifo_cleanup(&arg);
-
- fprintf(stderr, "PASS: aio_fifo_test\n");
}
struct aio_unix_socketpair_arg {
@@ -475,30 +447,27 @@ aio_unix_socketpair_cleanup(void *arg)
#define UNIX_SOCKETPAIR_LEN 256
#define UNIX_SOCKETPAIR_TIMEOUT 30
-static void
-aio_unix_socketpair_test(void)
+ATF_TC_WITHOUT_HEAD(aio_unix_socketpair_test);
+ATF_TC_BODY(aio_unix_socketpair_test, tc)
{
struct aio_unix_socketpair_arg arg;
struct aio_context ac;
int sockets[2];
- aio_available();
+ ATF_REQUIRE_KERNEL_MODULE("aio");
- if (socketpair(PF_UNIX, SOCK_STREAM, 0, sockets) < 0)
- errx(1, "FAIL: aio_socketpair_test: socketpair: %s",
- strerror(errno));
+ ATF_REQUIRE_MSG(socketpair(PF_UNIX, SOCK_STREAM, 0, sockets) != -1,
+ "socketpair failed: %s", strerror(errno));
arg.asa_sockets[0] = sockets[0];
arg.asa_sockets[1] = sockets[1];
- aio_context_init(&ac, "aio_unix_socketpair_test", sockets[0],
+ aio_context_init(&ac, sockets[0],
sockets[1], UNIX_SOCKETPAIR_LEN, UNIX_SOCKETPAIR_TIMEOUT,
aio_unix_socketpair_cleanup, &arg);
aio_write_test(&ac);
aio_read_test(&ac);
aio_unix_socketpair_cleanup(&arg);
-
- fprintf(stderr, "PASS: aio_unix_socketpair_test\n");
}
struct aio_pty_arg {
@@ -518,8 +487,8 @@ aio_pty_cleanup(void *arg)
#define PTY_LEN 256
#define PTY_TIMEOUT 30
-static void
-aio_pty_test(void)
+ATF_TC_WITHOUT_HEAD(aio_pty_test);
+ATF_TC_BODY(aio_pty_test, tc)
{
struct aio_pty_arg arg;
struct aio_context ac;
@@ -527,10 +496,10 @@ aio_pty_test(void)
struct termios ts;
int error;
- aio_available();
+ ATF_REQUIRE_KERNEL_MODULE("aio");
- if (openpty(&read_fd, &write_fd, NULL, NULL, NULL) < 0)
- errx(1, "FAIL: aio_pty_test: openpty: %s", strerror(errno));
+ ATF_REQUIRE_MSG(openpty(&read_fd, &write_fd, NULL, NULL, NULL) == 0,
+ "openpty failed: %s", strerror(errno));
arg.apa_read_fd = read_fd;
arg.apa_write_fd = write_fd;
@@ -539,26 +508,22 @@ aio_pty_test(void)
error = errno;
aio_pty_cleanup(&arg);
errno = error;
- errx(1, "FAIL: aio_pty_test: tcgetattr: %s",
- strerror(errno));
+ atf_tc_fail("tcgetattr failed: %s", strerror(errno));
}
cfmakeraw(&ts);
if (tcsetattr(write_fd, TCSANOW, &ts) < 0) {
error = errno;
aio_pty_cleanup(&arg);
errno = error;
- errx(1, "FAIL: aio_pty_test: tcsetattr: %s",
- strerror(errno));
+ atf_tc_fail("tcsetattr failed: %s", strerror(errno));
}
-
- aio_context_init(&ac, "aio_pty_test", read_fd, write_fd, PTY_LEN,
+ aio_context_init(&ac, read_fd, write_fd, PTY_LEN,
PTY_TIMEOUT, aio_pty_cleanup, &arg);
+
aio_write_test(&ac);
aio_read_test(&ac);
aio_pty_cleanup(&arg);
-
- fprintf(stderr, "PASS: aio_pty_test\n");
}
static void
@@ -572,25 +537,23 @@ aio_pipe_cleanup(void *arg)
#define PIPE_LEN 256
#define PIPE_TIMEOUT 30
-static void
-aio_pipe_test(void)
-{
+ATF_TC_WITHOUT_HEAD(aio_pipe_test);
+ATF_TC_BODY(aio_pipe_test, tc)
+{
struct aio_context ac;
int pipes[2];
- aio_available();
+ ATF_REQUIRE_KERNEL_MODULE("aio");
- if (pipe(pipes) < 0)
- errx(1, "FAIL: aio_pipe_test: pipe: %s", strerror(errno));
+ ATF_REQUIRE_MSG(pipe(pipes) != -1,
+ "pipe failed: %s", strerror(errno));
- aio_context_init(&ac, "aio_file_test", pipes[0], pipes[1], PIPE_LEN,
+ aio_context_init(&ac, pipes[0], pipes[1], PIPE_LEN,
PIPE_TIMEOUT, aio_pipe_cleanup, pipes);
aio_write_test(&ac);
aio_read_test(&ac);
aio_pipe_cleanup(pipes);
-
- fprintf(stderr, "PASS: aio_pipe_test\n");
}
struct aio_md_arg {
@@ -615,11 +578,11 @@ aio_md_cleanup(void *arg)
bzero(&mdio, sizeof(mdio));
mdio.md_version = MDIOVERSION;
mdio.md_unit = ama->ama_unit;
- if (ioctl(ama->ama_mdctl_fd, MDIOCDETACH, &mdio) < 0) {
+ if (ioctl(ama->ama_mdctl_fd, MDIOCDETACH, &mdio) == -1) {
error = errno;
close(ama->ama_mdctl_fd);
errno = error;
- warnx("FAIL: aio_md_test: MDIOCDETACH: %s",
+ atf_tc_fail("ioctl MDIOCDETACH failed: %s",
strerror(errno));
}
}
@@ -629,8 +592,13 @@ aio_md_cleanup(void *arg)
#define MD_LEN GLOBAL_MAX
#define MD_TIMEOUT 30
-static void
-aio_md_test(void)
+ATF_TC(aio_md_test);
+ATF_TC_HEAD(aio_md_test, tc)
+{
+
+ atf_tc_set_md_var(tc, "require.user", "root");
+}
+ATF_TC_BODY(aio_md_test, tc)
{
int error, fd, mdctl_fd, unit;
char pathname[PATH_MAX];
@@ -638,18 +606,11 @@ aio_md_test(void)
struct aio_context ac;
struct md_ioctl mdio;
- aio_available();
-
- if (geteuid() != 0) {
- fprintf(stderr, "WARNING: aio_md_test: skipped as euid "
- "!= 0\n");
- return;
- }
+ ATF_REQUIRE_KERNEL_MODULE("aio");
mdctl_fd = open("/dev/" MDCTL_NAME, O_RDWR, 0);
- if (mdctl_fd < 0)
- errx(1, "FAIL: aio_md_test: open(/dev/%s): %s", MDCTL_NAME,
- strerror(errno));
+ ATF_REQUIRE_MSG(mdctl_fd != -1,
+ "opening /dev/%s failed: %s", MDCTL_NAME, strerror(errno));
bzero(&mdio, sizeof(mdio));
mdio.md_version = MDIOVERSION;
@@ -665,42 +626,33 @@ aio_md_test(void)
error = errno;
aio_md_cleanup(&arg);
errno = error;
- errx(1, "FAIL: aio_md_test: MDIOCATTACH: %s",
- strerror(errno));
+ atf_tc_fail("ioctl MDIOCATTACH failed: %s", strerror(errno));
}
arg.ama_unit = unit = mdio.md_unit;
snprintf(pathname, PATH_MAX, "/dev/md%d", unit);
fd = open(pathname, O_RDWR);
- if (fd < 0) {
- error = errno;
- aio_md_cleanup(&arg);
- errno = error;
- errx(1, "FAIL: aio_md_test: open(%s): %s", pathname,
- strerror(errno));
- }
+ ATF_REQUIRE_MSG(fd != -1,
+ "opening %s failed: %s", pathname, strerror(errno));
arg.ama_fd = fd;
- aio_context_init(&ac, "aio_md_test", fd, fd, MD_LEN, MD_TIMEOUT,
+ aio_context_init(&ac, fd, fd, MD_LEN, MD_TIMEOUT,
aio_md_cleanup, &arg);
aio_write_test(&ac);
aio_read_test(&ac);
aio_md_cleanup(&arg);
-
- fprintf(stderr, "PASS: aio_md_test\n");
}
-int
-main(void)
+ATF_TP_ADD_TCS(tp)
{
- aio_file_test();
- aio_fifo_test();
- aio_unix_socketpair_test();
- aio_pty_test();
- aio_pipe_test();
- aio_md_test();
+ ATF_TP_ADD_TC(tp, aio_file_test);
+ ATF_TP_ADD_TC(tp, aio_fifo_test);
+ ATF_TP_ADD_TC(tp, aio_unix_socketpair_test);
+ ATF_TP_ADD_TC(tp, aio_pty_test);
+ ATF_TP_ADD_TC(tp, aio_pipe_test);
+ ATF_TP_ADD_TC(tp, aio_md_test);
- return (0);
+ return (atf_no_error());
}
diff --git a/tools/regression/aio/kqueue/lio/lio_kqueue.c b/tests/sys/aio/lio_kqueue_test.c
index ad7fc68..5cc87b3 100644
--- a/tools/regression/aio/kqueue/lio/lio_kqueue.c
+++ b/tests/sys/aio/lio_kqueue_test.c
@@ -48,16 +48,18 @@
#include <string.h>
#include <unistd.h>
-#define PATH_TEMPLATE "/tmp/aio.XXXXXXXXXX"
+#include "freebsd_test_suite/macros.h"
+
+#define PATH_TEMPLATE "aio.XXXXXXXXXX"
#define LIO_MAX 5
-#define MAX LIO_MAX * 16
+#define MAX_IOCBS LIO_MAX * 16
#define MAX_RUNS 300
int
main(int argc, char *argv[]){
int fd;
- struct aiocb *iocb[MAX];
+ struct aiocb *iocb[MAX_IOCBS];
struct aiocb **lio[LIO_MAX], **lio_element, **kq_lio;
int i, result, run, error, j, k;
char buffer[32768];
@@ -69,6 +71,8 @@ main(int argc, char *argv[]){
char *file, pathname[sizeof(PATH_TEMPLATE)-1];
int tmp_file = 0, failed = 0;
+ PLAIN_REQUIRE_KERNEL_MODULE("aio", 0);
+
if (kq < 0) {
perror("No kqeueue\n");
exit(1);
@@ -99,9 +103,9 @@ main(int argc, char *argv[]){
#endif
for (j = 0; j < LIO_MAX; j++) {
lio[j] = (struct aiocb **)
- malloc(sizeof(struct aiocb *) * MAX/LIO_MAX);
- for(i = 0; i < MAX / LIO_MAX; i++) {
- k = (MAX / LIO_MAX * j) + i;
+ malloc(sizeof(struct aiocb *) * MAX_IOCBS/LIO_MAX);
+ for(i = 0; i < MAX_IOCBS / LIO_MAX; i++) {
+ k = (MAX_IOCBS / LIO_MAX * j) + i;
lio_element = lio[j];
lio[j][i] = iocb[k] = (struct aiocb *)
malloc(sizeof(struct aiocb));
@@ -123,7 +127,7 @@ main(int argc, char *argv[]){
sig.sigev_notify = SIGEV_KEVENT;
time(&time1);
result = lio_listio(LIO_NOWAIT, lio[j],
- MAX / LIO_MAX, &sig);
+ MAX_IOCBS / LIO_MAX, &sig);
error = errno;
time(&time2);
#ifdef DEBUG
@@ -203,7 +207,7 @@ main(int argc, char *argv[]){
} else {
printf("PASS: run %d, operation %d result %d \n", run, LIO_MAX - i -1, result);
}
- for(k = 0; k < MAX / LIO_MAX; k++){
+ for(k = 0; k < MAX_IOCBS / LIO_MAX; k++){
result = aio_return(kq_lio[k]);
#ifdef DEBUG
printf("Return Resulto for %d %d is %d\n", j, k, result);
@@ -220,7 +224,7 @@ main(int argc, char *argv[]){
printf("\n");
#endif
- for(k = 0; k < MAX / LIO_MAX; k++) {
+ for(k = 0; k < MAX_IOCBS / LIO_MAX; k++) {
free(lio[j][k]);
}
free(lio[j]);
diff --git a/tests/sys/mqueue/Makefile b/tests/sys/mqueue/Makefile
new file mode 100644
index 0000000..5af8b25
--- /dev/null
+++ b/tests/sys/mqueue/Makefile
@@ -0,0 +1,22 @@
+# $FreeBSD$
+
+TESTSDIR= ${TESTSBASE}/sys/mqueue
+
+ATF_TESTS_SH= mqueue_test
+
+BINDIR= ${TESTSDIR}
+
+CFLAGS+= -I${.CURDIR:H:H}
+
+PROGS+= mqtest1
+PROGS+= mqtest2
+PROGS+= mqtest3
+PROGS+= mqtest4
+PROGS+= mqtest5
+
+LDADD+= -lrt
+DPADD+= ${LIBRT}
+
+WARNS?= 6
+
+.include <bsd.test.mk>
diff --git a/tools/regression/mqueue/mqtest1/mqtest1.c b/tests/sys/mqueue/mqtest1.c
index 25fc1ba..3accb28 100644
--- a/tools/regression/mqueue/mqtest1/mqtest1.c
+++ b/tests/sys/mqueue/mqtest1.c
@@ -7,15 +7,20 @@
#include <signal.h>
#include <stdio.h>
+#include "freebsd_test_suite/macros.h"
+
#define MQNAME "/mytstqueue1"
-int main()
+int
+main(void)
{
struct mq_attr attr, attr2;
struct sigevent sigev;
mqd_t mq;
int status;
+ PLAIN_REQUIRE_KERNEL_MODULE("mqueuefs", 0);
+
attr.mq_maxmsg = 2;
attr.mq_msgsize = 100;
mq = mq_open(MQNAME, O_CREAT | O_RDWR | O_EXCL, 0666, &attr);
diff --git a/tools/regression/mqueue/mqtest2/mqtest2.c b/tests/sys/mqueue/mqtest2.c
index bfe6d97..067e619 100644
--- a/tools/regression/mqueue/mqtest2/mqtest2.c
+++ b/tests/sys/mqueue/mqtest2.c
@@ -10,21 +10,28 @@
#include <stdlib.h>
#include <unistd.h>
+#include "freebsd_test_suite/macros.h"
+
#define MQNAME "/mytstqueue2"
#define LOOPS 1000
#define PRIO 10
-void alarmhandler(int sig)
+static void
+alarmhandler(int sig __unused)
{
write(1, "timeout\n", 8);
_exit(1);
}
-int main()
+int
+main(void)
{
struct mq_attr attr;
mqd_t mq;
- int status, pid;
+ int status;
+ pid_t pid;
+
+ PLAIN_REQUIRE_KERNEL_MODULE("mqueuefs", 0);
mq_unlink(MQNAME);
@@ -38,8 +45,9 @@ int main()
err(1, "mq_getattr");
pid = fork();
if (pid == 0) { /* child */
- int prio, j, i;
char *buf;
+ int j, i;
+ unsigned int prio;
mq_close(mq);
@@ -69,7 +77,7 @@ int main()
err(1, "fork()");
} else {
char *buf;
- int i, j, prio;
+ int i, j;
signal(SIGALRM, alarmhandler);
buf = malloc(attr.mq_msgsize);
diff --git a/tools/regression/mqueue/mqtest3/mqtest3.c b/tests/sys/mqueue/mqtest3.c
index aa47ffa..c4b849e 100644
--- a/tools/regression/mqueue/mqtest3/mqtest3.c
+++ b/tests/sys/mqueue/mqtest3.c
@@ -11,23 +11,29 @@
#include <stdlib.h>
#include <unistd.h>
+#include "freebsd_test_suite/macros.h"
+
#define MQNAME "/mytstqueue3"
#define LOOPS 1000
#define PRIO 10
-void sighandler(int sig)
+static void
+sighandler(int sig __unused)
{
write(1, "timeout\n", 8);
_exit(1);
}
-int main()
+int
+main(void)
{
- mqd_t mq;
- int status;
- struct mq_attr attr;
- int pid;
fd_set set;
+ struct mq_attr attr;
+ int status;
+ mqd_t mq;
+ pid_t pid;
+
+ PLAIN_REQUIRE_KERNEL_MODULE("mqueuefs", 0);
mq_unlink(MQNAME);
@@ -42,8 +48,9 @@ int main()
pid = fork();
if (pid == 0) { /* child */
- int prio, j, i;
char *buf;
+ int j, i;
+ unsigned int prio;
mq_close(mq);
@@ -77,7 +84,7 @@ int main()
err(1, "fork()");
} else {
char *buf;
- int i, j, prio;
+ int i, j;
signal(SIGALRM, sighandler);
buf = malloc(attr.mq_msgsize);
diff --git a/tools/regression/mqueue/mqtest4/mqtest4.c b/tests/sys/mqueue/mqtest4.c
index 80a7f88..474d212 100644
--- a/tools/regression/mqueue/mqtest4/mqtest4.c
+++ b/tests/sys/mqueue/mqtest4.c
@@ -12,25 +12,29 @@
#include <stdlib.h>
#include <unistd.h>
+#include "freebsd_test_suite/macros.h"
+
#define MQNAME "/mytstqueue4"
#define LOOPS 1000
#define PRIO 10
-void sighandler(int sig)
+static void
+sighandler(int sig __unused)
{
write(1, "timeout\n", 8);
_exit(1);
}
-int main()
+int
+main(void)
{
- mqd_t mq;
- int status;
- struct mq_attr attr;
- int pid;
- fd_set set;
- int kq;
struct kevent kev;
+ struct mq_attr attr;
+ mqd_t mq;
+ int kq, status;
+ pid_t pid;
+
+ PLAIN_REQUIRE_KERNEL_MODULE("mqueuefs", 0);
mq_unlink(MQNAME);
@@ -44,8 +48,9 @@ int main()
err(1, "mq_getattr()");
pid = fork();
if (pid == 0) { /* child */
- int prio, j, i;
char *buf;
+ int j, i;
+ unsigned int prio;
mq_close(mq);
kq = kqueue();
@@ -80,7 +85,7 @@ int main()
err(1, "fork()");
} else {
char *buf;
- int i, j, prio;
+ int i, j;
signal(SIGALRM, sighandler);
kq = kqueue();
diff --git a/tools/regression/mqueue/mqtest5/mqtest5.c b/tests/sys/mqueue/mqtest5.c
index 354a7bb..0c8aa89 100644
--- a/tools/regression/mqueue/mqtest5/mqtest5.c
+++ b/tests/sys/mqueue/mqtest5.c
@@ -12,25 +12,31 @@
#include <stdlib.h>
#include <unistd.h>
+#include "freebsd_test_suite/macros.h"
+
#define MQNAME "/mytstqueue5"
#define LOOPS 1000
#define PRIO 10
-void sighandler(int sig)
+static void
+sighandler(int sig __unused)
{
write(1, "timeout\n", 8);
_exit(1);
}
-int main()
+int
+main(void)
{
- mqd_t mq;
int status;
struct mq_attr attr;
- int pid;
- sigset_t set;
struct sigaction sa;
+ sigset_t set;
siginfo_t info;
+ mqd_t mq;
+ pid_t pid;
+
+ PLAIN_REQUIRE_KERNEL_MODULE("mqueuefs", 0);
mq_unlink(MQNAME);
@@ -95,7 +101,7 @@ int main()
err(1, "fork()");
} else {
char *buf;
- int i, j, prio;
+ int i, j;
signal(SIGALRM, sighandler);
buf = malloc(attr.mq_msgsize);
diff --git a/tests/sys/mqueue/mqueue_test.sh b/tests/sys/mqueue/mqueue_test.sh
new file mode 100755
index 0000000..4841418
--- /dev/null
+++ b/tests/sys/mqueue/mqueue_test.sh
@@ -0,0 +1,81 @@
+#
+# Copyright (c) 2015 EMC / Isilon Storage Division
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+# 1. Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+# SUCH DAMAGE.
+#
+# $FreeBSD$
+#
+
+mqtest1_head()
+{
+ :
+}
+mqtest1_body()
+{
+ atf_check -s exit:0 -x $(atf_get_srcdir)/mqtest1
+}
+
+mqtest2_head()
+{
+ :
+}
+mqtest2_body()
+{
+ atf_check -s exit:0 -x $(atf_get_srcdir)/mqtest2
+}
+
+mqtest3_head()
+{
+ :
+}
+mqtest3_body()
+{
+ atf_check -s exit:0 -x $(atf_get_srcdir)/mqtest3
+}
+
+mqtest4_head()
+{
+ :
+}
+mqtest4_body()
+{
+ atf_check -s exit:0 -x $(atf_get_srcdir)/mqtest4
+}
+
+mqtest5_head()
+{
+ :
+}
+mqtest5_body()
+{
+ atf_check -s exit:0 -x $(atf_get_srcdir)/mqtest5
+}
+
+atf_init_test_cases()
+{
+ atf_add_test_case mqtest1
+ atf_add_test_case mqtest2
+ atf_add_test_case mqtest3
+ atf_add_test_case mqtest4
+ atf_add_test_case mqtest5
+}
diff --git a/tools/regression/aio/aiotest/Makefile b/tools/regression/aio/aiotest/Makefile
deleted file mode 100644
index 59d4316..0000000
--- a/tools/regression/aio/aiotest/Makefile
+++ /dev/null
@@ -1,11 +0,0 @@
-# $FreeBSD$
-
-PROG= aiotest
-MAN=
-
-DPADD= ${LIBUTIL}
-LDADD= -lutil
-
-WARNS?= 6
-
-.include <bsd.prog.mk>
diff --git a/tools/regression/aio/kqueue/Makefile b/tools/regression/aio/kqueue/Makefile
deleted file mode 100644
index 39c1aa1..0000000
--- a/tools/regression/aio/kqueue/Makefile
+++ /dev/null
@@ -1,10 +0,0 @@
-# $FreeBSD$
-
-PROG= aio_kqueue
-MAN=
-
-WARNS?= 6
-
-SUBDIR+= lio
-
-.include <bsd.prog.mk>
diff --git a/tools/regression/aio/kqueue/lio/Makefile b/tools/regression/aio/kqueue/lio/Makefile
deleted file mode 100644
index da054e4..0000000
--- a/tools/regression/aio/kqueue/lio/Makefile
+++ /dev/null
@@ -1,8 +0,0 @@
-# $FreeBSD$
-
-PROG= lio_kqueue
-MAN=
-
-WARNS?= 6
-
-.include <bsd.prog.mk>
diff --git a/tools/regression/mqueue/Makefile b/tools/regression/mqueue/Makefile
deleted file mode 100644
index a4f386b..0000000
--- a/tools/regression/mqueue/Makefile
+++ /dev/null
@@ -1,5 +0,0 @@
-# $FreeBSD$
-
-SUBDIR=mqtest1 mqtest2 mqtest3 mqtest4 mqtest5
-
-.include <bsd.subdir.mk>
diff --git a/tools/regression/mqueue/mqtest1/Makefile b/tools/regression/mqueue/mqtest1/Makefile
deleted file mode 100644
index 3a50cee..0000000
--- a/tools/regression/mqueue/mqtest1/Makefile
+++ /dev/null
@@ -1,9 +0,0 @@
-# $FreeBSD$
-
-PROG=mqtest1
-DPADD= ${LIBRT}
-LDADD= -lrt
-MAN=
-DEBUG_FLAGS=-g
-
-.include <bsd.prog.mk>
diff --git a/tools/regression/mqueue/mqtest2/Makefile b/tools/regression/mqueue/mqtest2/Makefile
deleted file mode 100644
index 0709854..0000000
--- a/tools/regression/mqueue/mqtest2/Makefile
+++ /dev/null
@@ -1,9 +0,0 @@
-# $FreeBSD$
-
-PROG=mqtest2
-DPADD= ${LIBRT}
-LDADD= -lrt
-MAN=
-DEBUG_FLAGS=-g
-
-.include <bsd.prog.mk>
diff --git a/tools/regression/mqueue/mqtest3/Makefile b/tools/regression/mqueue/mqtest3/Makefile
deleted file mode 100644
index 514cbac..0000000
--- a/tools/regression/mqueue/mqtest3/Makefile
+++ /dev/null
@@ -1,9 +0,0 @@
-# $FreeBSD$
-
-PROG=mqtest3
-DPADD= ${LIBRT}
-LDADD= -lrt
-MAN=
-DEBUG_FLAGS=-g
-
-.include <bsd.prog.mk>
diff --git a/tools/regression/mqueue/mqtest4/Makefile b/tools/regression/mqueue/mqtest4/Makefile
deleted file mode 100644
index 781d76d..0000000
--- a/tools/regression/mqueue/mqtest4/Makefile
+++ /dev/null
@@ -1,9 +0,0 @@
-# $FreeBSD$
-
-PROG=mqtest4
-DPADD= ${LIBRT}
-LDADD= -lrt
-MAN=
-DEBUG_FLAGS=-g
-
-.include <bsd.prog.mk>
diff --git a/tools/regression/mqueue/mqtest5/Makefile b/tools/regression/mqueue/mqtest5/Makefile
deleted file mode 100644
index d94e541..0000000
--- a/tools/regression/mqueue/mqtest5/Makefile
+++ /dev/null
@@ -1,9 +0,0 @@
-# $FreeBSD$
-
-PROG=mqtest5
-DPADD= ${LIBRT}
-LDADD= -lrt
-MAN=
-DEBUG_FLAGS=-g
-
-.include <bsd.prog.mk>
OpenPOWER on IntegriCloud