summaryrefslogtreecommitdiffstats
path: root/testsuites/libtests
diff options
context:
space:
mode:
authorChris Johns <chrisj@rtems.org>2017-10-19 16:39:16 +1100
committerChris Johns <chrisj@rtems.org>2017-10-23 16:25:45 +1100
commit98c6d501452f02264ff148a1b8479e420c81562d (patch)
tree8c6cd90ccd1df98f782396d94d6acdbfe5d042cb /testsuites/libtests
parentposix: Fix POSIX disabled build (diff)
downloadrtems-98c6d501452f02264ff148a1b8479e420c81562d.tar.bz2
testsuite: Use printk for all test output where possible.
- Remove the printf support leaving the direct printk support configured with TESTS_USE_PRINTK and all other output goes via a buffered vsniprintf call to printk. - Control the test's single init for functions and global data with TEST_INIT and not CONFIGURE_INIT. They are now separate. Updates #3170.
Diffstat (limited to 'testsuites/libtests')
-rw-r--r--testsuites/libtests/block01/init.c2
-rw-r--r--testsuites/libtests/block02/init.c2
-rw-r--r--testsuites/libtests/block03/init.c2
-rw-r--r--testsuites/libtests/block04/init.c2
-rw-r--r--testsuites/libtests/block05/init.c2
-rw-r--r--testsuites/libtests/block06/init.c150
-rw-r--r--testsuites/libtests/block07/init.c36
-rw-r--r--testsuites/libtests/block08/bdbuf_test3_2.c4
-rw-r--r--testsuites/libtests/block08/bdbuf_test3_3.c4
-rw-r--r--testsuites/libtests/block08/bdbuf_tests.c27
-rw-r--r--testsuites/libtests/block08/init.c2
-rw-r--r--testsuites/libtests/block08/test_disk.c12
-rw-r--r--testsuites/libtests/block09/init.c2
-rw-r--r--testsuites/libtests/block10/init.c36
-rw-r--r--testsuites/libtests/block11/init.c2
-rw-r--r--testsuites/libtests/block12/init.c2
-rw-r--r--testsuites/libtests/block13/init.c2
-rw-r--r--testsuites/libtests/block14/init.c2
-rw-r--r--testsuites/libtests/block15/init.c2
-rw-r--r--testsuites/libtests/block16/init.c2
-rw-r--r--testsuites/libtests/block17/init.c2
-rw-r--r--testsuites/libtests/bspcmdline01/init.c2
-rw-r--r--testsuites/libtests/capture01/init.c2
-rw-r--r--testsuites/libtests/cpuuse/init.c2
-rw-r--r--testsuites/libtests/crypt01/init.c2
-rw-r--r--testsuites/libtests/debugger01/init.c2
-rw-r--r--testsuites/libtests/defaultconfig01/init.c2
-rw-r--r--testsuites/libtests/devfs01/init.c2
-rw-r--r--testsuites/libtests/devfs02/init.c2
-rw-r--r--testsuites/libtests/devfs03/init.c2
-rw-r--r--testsuites/libtests/devfs04/init.c2
-rw-r--r--testsuites/libtests/deviceio01/init.c2
-rw-r--r--testsuites/libtests/dl01/init.c2
-rw-r--r--testsuites/libtests/dl02/init.c2
-rw-r--r--testsuites/libtests/dl03/init.c2
-rw-r--r--testsuites/libtests/dl04/init.c2
-rw-r--r--testsuites/libtests/dl05/init.c2
-rw-r--r--testsuites/libtests/dumpbuf01/init.c2
-rw-r--r--testsuites/libtests/exit01/init.c2
-rw-r--r--testsuites/libtests/exit02/init.c2
-rw-r--r--testsuites/libtests/flashdisk01/init.c2
-rw-r--r--testsuites/libtests/ftp01/init.c2
-rw-r--r--testsuites/libtests/gxx01/init.c2
-rw-r--r--testsuites/libtests/heapwalk/init.c2
-rw-r--r--testsuites/libtests/i2c01/init.c2
-rw-r--r--testsuites/libtests/libfdt01/init.c2
-rw-r--r--testsuites/libtests/malloc02/init.c2
-rw-r--r--testsuites/libtests/malloc03/init.c2
-rw-r--r--testsuites/libtests/malloc04/init.c2
-rw-r--r--testsuites/libtests/malloctest/init.c2
-rw-r--r--testsuites/libtests/md501/init.c2
-rw-r--r--testsuites/libtests/mghttpd01/init.c2
-rw-r--r--testsuites/libtests/monitor/init.c2
-rw-r--r--testsuites/libtests/monitor02/init.c2
-rw-r--r--testsuites/libtests/mouse01/init.c2
-rw-r--r--testsuites/libtests/networking01/init.c2
-rw-r--r--testsuites/libtests/newlib01/init.c2
-rw-r--r--testsuites/libtests/putenvtest/init.c2
-rw-r--r--testsuites/libtests/pwdgrp01/init.c2
-rw-r--r--testsuites/libtests/pwdgrp02/init.c2
-rw-r--r--testsuites/libtests/rbheap01/init.c2
-rw-r--r--testsuites/libtests/rtmonuse/init.c2
-rw-r--r--testsuites/libtests/sha/init.c2
-rw-r--r--testsuites/libtests/shell01/init.c2
-rw-r--r--testsuites/libtests/sparsedisk01/init.c2
-rw-r--r--testsuites/libtests/spi01/init.c2
-rw-r--r--testsuites/libtests/stackchk/init.c2
-rw-r--r--testsuites/libtests/stackchk01/init.c2
-rw-r--r--testsuites/libtests/stringto01/init.c2
-rw-r--r--testsuites/libtests/syscall01/init.c2
-rw-r--r--testsuites/libtests/tar01/init.c2
-rw-r--r--testsuites/libtests/tar02/init.c2
-rw-r--r--testsuites/libtests/tar03/init.c2
-rw-r--r--testsuites/libtests/termios/init.c2
-rw-r--r--testsuites/libtests/termios01/init.c2
-rw-r--r--testsuites/libtests/termios02/init.c2
-rw-r--r--testsuites/libtests/termios03/init.c2
-rw-r--r--testsuites/libtests/termios04/init.c2
-rw-r--r--testsuites/libtests/termios05/init.c2
-rw-r--r--testsuites/libtests/termios06/init.c2
-rw-r--r--testsuites/libtests/termios07/init.c2
-rw-r--r--testsuites/libtests/termios08/init.c2
-rw-r--r--testsuites/libtests/termios09/init.c2
-rw-r--r--testsuites/libtests/top/init.c2
-rw-r--r--testsuites/libtests/tztest/init.c2
-rw-r--r--testsuites/libtests/uid01/init.c2
-rw-r--r--testsuites/libtests/utf8proc01/init.c2
87 files changed, 288 insertions, 141 deletions
diff --git a/testsuites/libtests/block01/init.c b/testsuites/libtests/block01/init.c
index b7eaa2b91f..c1a20693bd 100644
--- a/testsuites/libtests/block01/init.c
+++ b/testsuites/libtests/block01/init.c
@@ -24,6 +24,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <sys/stat.h>
#include <stdio.h>
#include <fcntl.h>
diff --git a/testsuites/libtests/block02/init.c b/testsuites/libtests/block02/init.c
index 863064109b..f7dc3efd0d 100644
--- a/testsuites/libtests/block02/init.c
+++ b/testsuites/libtests/block02/init.c
@@ -24,6 +24,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define TESTS_USE_PRINTK
#include "tmacros.h"
diff --git a/testsuites/libtests/block03/init.c b/testsuites/libtests/block03/init.c
index f2a18b9a7c..f2f6bd9ee4 100644
--- a/testsuites/libtests/block03/init.c
+++ b/testsuites/libtests/block03/init.c
@@ -24,6 +24,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define TESTS_USE_PRINTK
#include "tmacros.h"
diff --git a/testsuites/libtests/block04/init.c b/testsuites/libtests/block04/init.c
index 3f448c7605..3d674c1107 100644
--- a/testsuites/libtests/block04/init.c
+++ b/testsuites/libtests/block04/init.c
@@ -24,6 +24,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define TESTS_USE_PRINTK
#include "tmacros.h"
diff --git a/testsuites/libtests/block05/init.c b/testsuites/libtests/block05/init.c
index 7cce2acfd0..7a40b50b3c 100644
--- a/testsuites/libtests/block05/init.c
+++ b/testsuites/libtests/block05/init.c
@@ -24,6 +24,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define TESTS_USE_PRINTK
#include "tmacros.h"
#include <stdarg.h>
diff --git a/testsuites/libtests/block06/init.c b/testsuites/libtests/block06/init.c
index 1b91ad7ab2..e1544118f5 100644
--- a/testsuites/libtests/block06/init.c
+++ b/testsuites/libtests/block06/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <errno.h>
#include <setjmp.h>
#include <stdio.h>
@@ -128,24 +130,6 @@ typedef struct bdbuf_task_control
#define BDBUF_SECONDS(msec) ((msec) * 1000UL)
/**
- * Print a message to output and flush it.
- *
- * @param format The format string. See printf for details.
- * @param ... The arguments for the format text.
- * @return int The number of bytes written to the output.
- */
-static int
-bdbuf_test_printf (const char *format, ...)
-{
- int ret = 0;
- va_list args;
- va_start (args, format);
- ret = vfprintf (stdout, format, args);
- fflush (stdout);
- return ret;
-}
-
-/**
* Print the status code description and return true if true.
*
* @param sc The RTEMS status code.
@@ -172,7 +156,7 @@ bdbuf_disk_lock (bdbuf_disk* bdd)
sc = rtems_semaphore_obtain (bdd->lock, RTEMS_WAIT, 0);
if (sc != RTEMS_SUCCESSFUL)
{
- bdbuf_test_printf ("disk ioctl: lock failed: ");
+ printf ("disk ioctl: lock failed: ");
bdbuf_test_print_sc (sc, true);
return false;
}
@@ -189,7 +173,7 @@ bdbuf_disk_unlock (bdbuf_disk* bdd)
sc = rtems_semaphore_release (bdd->lock);
if (sc != RTEMS_SUCCESSFUL)
{
- bdbuf_test_printf ("disk ioctl: unlock failed: ");
+ printf ("disk ioctl: unlock failed: ");
bdbuf_test_print_sc (sc, true);
return false;
}
@@ -210,12 +194,12 @@ bdbuf_wait (const char* who, unsigned long timeout)
&out);
if (sc != RTEMS_SUCCESSFUL)
{
- bdbuf_test_printf ("%s: wait: receive failed: ", who);
+ printf ("%s: wait: receive failed: ", who);
bdbuf_test_print_sc (sc, true);
}
else if ((out & RTEMS_EVENT_0) == 0)
{
- bdbuf_test_printf ("%s: wait: received wrong event: %08x", who, out);
+ printf ("%s: wait: received wrong event: %08x", who, out);
}
return sc;
}
@@ -226,7 +210,7 @@ bdbuf_wait (const char* who, unsigned long timeout)
static bool
bdbuf_send_wait_event (const char* task, const char* msg, rtems_id id)
{
- bdbuf_test_printf ("%s: %s: %08x: ", task, msg, id);
+ printf ("%s: %s: %08x: ", task, msg, id);
return bdbuf_test_print_sc (rtems_event_send (id, RTEMS_EVENT_0), true);
}
@@ -244,12 +228,12 @@ bdbuf_watch (unsigned long timeout)
&out);
if (sc != RTEMS_SUCCESSFUL)
{
- bdbuf_test_printf ("watch: receive failed: ");
+ printf ("watch: receive failed: ");
bdbuf_test_print_sc (sc, true);
}
else if ((out & RTEMS_EVENT_1) == 0)
{
- bdbuf_test_printf ("watch: received wrong event: %08x", out);
+ printf ("watch: received wrong event: %08x", out);
}
return sc;
}
@@ -260,7 +244,7 @@ bdbuf_watch (unsigned long timeout)
static bool
bdbuf_send_watch_event (const char* task, const char* msg, rtems_id id)
{
- bdbuf_test_printf ("%s: %s: %08x: ", task, msg, id);
+ printf ("%s: %s: %08x: ", task, msg, id);
return bdbuf_test_print_sc (rtems_event_send (id, RTEMS_EVENT_1), true);
}
@@ -306,7 +290,7 @@ bdbuf_disk_driver_watch_wait (bdbuf_task_control* tc, unsigned long msecs)
rtems_status_code sc = bdbuf_watch (msecs);
if (sc != RTEMS_SUCCESSFUL)
{
- bdbuf_test_printf ("%s: driver watch: driver wait: ", tc->name);
+ printf ("%s: driver watch: driver wait: ", tc->name);
passed = bdbuf_test_print_sc (sc, true);
}
bdbuf_clear_disk_driver_watch (tc);
@@ -337,7 +321,7 @@ bdbuf_sleep (unsigned long msecs)
sc = rtems_task_wake_after (RTEMS_MICROSECONDS_TO_TICKS (msecs * 1000));
if (sc != RTEMS_SUCCESSFUL)
{
- bdbuf_test_printf ("sleep wake after failed: ");
+ printf ("sleep wake after failed: ");
bdbuf_test_print_sc (sc, true);
return false;
}
@@ -413,7 +397,7 @@ bdbuf_disk_ioctl_process (bdbuf_disk* bdd, rtems_blkdev_request* req)
case BDBUF_DISK_WAIT:
if (bdd->waiting)
- bdbuf_test_printf ("disk ioctl: bad waiter: %s:%08x\n",
+ printf ("disk ioctl: bad waiter: %s:%08x\n",
bdd->waiting_name, bdd->waiting);
bdd->waiting_name = "bdd";
@@ -431,22 +415,22 @@ bdbuf_disk_ioctl_process (bdbuf_disk* bdd, rtems_blkdev_request* req)
break;
case BDBUF_DISK_SLEEP:
- bdbuf_test_printf ("disk ioctl: sleeping: %d msecs\n",
+ printf ("disk ioctl: sleeping: %d msecs\n",
bdd->driver_sleep);
result = bdbuf_sleep (bdd->driver_sleep);
break;
case BDBUF_DISK_BLOCKS_INORDER:
- bdbuf_test_printf ("disk ioctl: multi-block order check: count = %d\n",
+ printf ("disk ioctl: multi-block order check: count = %d\n",
req->bufnum);
for (b = 0; b < (req->bufnum - 1); b++)
if (req->bufs[b].block >= req->bufs[b + 1].block)
- bdbuf_test_printf ("disk ioctl: out of order: index:%d (%d >= %d\n",
+ printf ("disk ioctl: out of order: index:%d (%d >= %d\n",
b, req->bufs[b].block, req->bufs[b + 1].block);
break;
default:
- bdbuf_test_printf ("disk ioctl: invalid action: %d\n",
+ printf ("disk ioctl: invalid action: %d\n",
bdd->driver_action);
result = false;
break;
@@ -563,7 +547,7 @@ bdbuf_disk_initialize (rtems_device_major_number major,
{
rtems_status_code sc;
- bdbuf_test_printf ("disk io init: ");
+ printf ("disk io init: ");
sc = rtems_disk_io_initialize ();
if (!bdbuf_test_print_sc (sc, true))
return sc;
@@ -579,8 +563,8 @@ bdbuf_disk_initialize (rtems_device_major_number major,
bdd->name = strdup (name);
- bdbuf_test_printf ("disk init: %s\n", bdd->name);
- bdbuf_test_printf ("disk lock: ");
+ printf ("disk init: %s\n", bdd->name);
+ printf ("disk lock: ");
sc = rtems_semaphore_create (rtems_build_name ('B', 'D', 'D', 'K'), 1,
RTEMS_PRIORITY | RTEMS_BINARY_SEMAPHORE |
@@ -596,7 +580,7 @@ bdbuf_disk_initialize (rtems_device_major_number major,
bdbuf_disk_ioctl, bdd, name);
if (sc != RTEMS_SUCCESSFUL)
{
- bdbuf_test_printf ("disk init: create phys failed: ");
+ printf ("disk init: create phys failed: ");
bdbuf_test_print_sc (sc, true);
return sc;
}
@@ -631,7 +615,7 @@ bdbuf_tests_setup_disk (rtems_device_major_number *major,
/*
* Register the disk driver.
*/
- bdbuf_test_printf ("register disk driver\n");
+ printf ("register disk driver\n");
sc = rtems_io_register_driver (RTEMS_DRIVER_AUTO_MAJOR,
&bdbuf_disk_io_ops,
@@ -653,7 +637,7 @@ bdbuf_tests_create_task (bdbuf_task_control* tc,
{
rtems_status_code sc;
- bdbuf_test_printf ("creating task: %s: priority: %d: ",
+ printf ("creating task: %s: priority: %d: ",
tc->name, priority);
sc = rtems_task_create (rtems_build_name (tc->name[0], tc->name[1],
@@ -666,7 +650,7 @@ bdbuf_tests_create_task (bdbuf_task_control* tc,
if (!bdbuf_test_print_sc (sc, true))
return false;
- bdbuf_test_printf ("starting task: %s: ", tc->name);
+ printf ("starting task: %s: ", tc->name);
sc = rtems_task_start (tc->task, entry_point, (rtems_task_argument) tc);
@@ -694,7 +678,7 @@ bdbuf_tests_task_0_test_1 (bdbuf_task_control* tc)
for (i = 0; (i < 2) && passed; i++)
{
- bdbuf_test_printf ("%s: rtems_bdbuf_get[0]: ", tc->name);
+ printf ("%s: rtems_bdbuf_get[0]: ", tc->name);
sc = rtems_bdbuf_get (tc->dd, 0, &bd);
if (!bdbuf_test_print_sc (sc, true))
{
@@ -702,7 +686,7 @@ bdbuf_tests_task_0_test_1 (bdbuf_task_control* tc)
break;
}
- bdbuf_test_printf ("%s: rtems_bdbuf_release[0]: ", tc->name);
+ printf ("%s: rtems_bdbuf_release[0]: ", tc->name);
sc = rtems_bdbuf_release (bd);
if (!bdbuf_test_print_sc (sc, true))
{
@@ -742,7 +726,7 @@ bdbuf_tests_task_0_test_2 (bdbuf_task_control* tc)
for (i = 0; (i < 5) && passed; i++)
{
- bdbuf_test_printf ("%s: rtems_bdbuf_get[%d]: ", tc->name, i);
+ printf ("%s: rtems_bdbuf_get[%d]: ", tc->name, i);
sc = rtems_bdbuf_get (tc->dd, i, &bd);
if (!bdbuf_test_print_sc (sc, true))
passed = false;
@@ -767,18 +751,18 @@ bdbuf_tests_task_0_test_2 (bdbuf_task_control* tc)
sc = bdbuf_wait (tc->name, BDBUF_SECONDS (5));
if (sc != RTEMS_SUCCESSFUL)
{
- bdbuf_test_printf ("%s: wait failed: ", tc->name);
+ printf ("%s: wait failed: ", tc->name);
bdbuf_test_print_sc (sc, true);
passed = false;
break;
}
else
{
- bdbuf_test_printf ("%s: rtems_bdbuf_release[%d]: unblocks task 1\n",
+ printf ("%s: rtems_bdbuf_release[%d]: unblocks task 1\n",
tc->name, i);
bd = (rtems_bdbuf_buffer*) rtems_chain_get (&buffers);
sc = rtems_bdbuf_release (bd);
- bdbuf_test_printf ("%s: rtems_bdbuf_release[%d]: ", tc->name, i);
+ printf ("%s: rtems_bdbuf_release[%d]: ", tc->name, i);
if (!bdbuf_test_print_sc (sc, true))
{
passed = false;
@@ -815,11 +799,11 @@ bdbuf_tests_task_0_test_3 (bdbuf_task_control* tc)
/*
* Read the buffer and then release it.
*/
- bdbuf_test_printf ("%s: rtems_bdbuf_read[5]: ", tc->name);
+ printf ("%s: rtems_bdbuf_read[5]: ", tc->name);
sc = rtems_bdbuf_read (tc->dd, 5, &bd);
if ((passed = bdbuf_test_print_sc (sc, true)))
{
- bdbuf_test_printf ("%s: rtems_bdbuf_release_modified[5]: ", tc->name);
+ printf ("%s: rtems_bdbuf_release_modified[5]: ", tc->name);
sc = rtems_bdbuf_release_modified (bd);
passed = bdbuf_test_print_sc (sc, true);
}
@@ -828,11 +812,11 @@ bdbuf_tests_task_0_test_3 (bdbuf_task_control* tc)
* Read the buffer again and then just release. The buffer should
* be maintained as modified.
*/
- bdbuf_test_printf ("%s: rtems_bdbuf_read[5]: ", tc->name);
+ printf ("%s: rtems_bdbuf_read[5]: ", tc->name);
sc = rtems_bdbuf_read (tc->dd, 5, &bd);
if ((passed = bdbuf_test_print_sc (sc, true)))
{
- bdbuf_test_printf ("%s: rtems_bdbuf_release[5]: ", tc->name);
+ printf ("%s: rtems_bdbuf_release[5]: ", tc->name);
sc = rtems_bdbuf_release (bd);
passed = bdbuf_test_print_sc (sc, true);
}
@@ -886,7 +870,7 @@ bdbuf_tests_task_0_test_4 (bdbuf_task_control* tc)
for (i = 0; (i < num) && passed; i++)
{
- bdbuf_test_printf ("%s: rtems_bdbuf_read[%d]: ", tc->name, i);
+ printf ("%s: rtems_bdbuf_read[%d]: ", tc->name, i);
sc = rtems_bdbuf_read (tc->dd, i, &bd);
if (!bdbuf_test_print_sc (sc, true))
passed = false;
@@ -909,21 +893,21 @@ bdbuf_tests_task_0_test_4 (bdbuf_task_control* tc)
* Release half the buffers, wait 500msecs then release the
* remainder. This tests the swap out timer on each buffer.
*/
- bdbuf_test_printf ("%s: rtems_bdbuf_release_modified[0]: unblocks task 1\n",
+ printf ("%s: rtems_bdbuf_release_modified[0]: unblocks task 1\n",
tc->name);
bd = (rtems_bdbuf_buffer*) rtems_chain_get (&buffers);
sc = rtems_bdbuf_release_modified (bd);
- bdbuf_test_printf ("%s: rtems_bdbuf_release_modified[0]: ", tc->name);
+ printf ("%s: rtems_bdbuf_release_modified[0]: ", tc->name);
passed = bdbuf_test_print_sc (sc, true);
if (passed)
{
for (i = 1; (i < (num / 2)) && passed; i++)
{
- bdbuf_test_printf ("%s: rtems_bdbuf_release_modified[%d]: " \
+ printf ("%s: rtems_bdbuf_release_modified[%d]: " \
"unblocks task 1\n", tc->name, i);
bd = (rtems_bdbuf_buffer*) rtems_chain_get (&buffers);
sc = rtems_bdbuf_release_modified (bd);
- bdbuf_test_printf ("%s: rtems_bdbuf_release_modified[%d]: ",
+ printf ("%s: rtems_bdbuf_release_modified[%d]: ",
tc->name, i);
passed = bdbuf_test_print_sc (sc, true);
if (!passed)
@@ -942,7 +926,7 @@ bdbuf_tests_task_0_test_4 (bdbuf_task_control* tc)
for (i = 0; (i < (num / 2)) && passed; i++)
{
- bdbuf_test_printf ("%s: rtems_bdbuf_release_modified[%d]: ",
+ printf ("%s: rtems_bdbuf_release_modified[%d]: ",
tc->name, i + (num / 2));
bd = (rtems_bdbuf_buffer*) rtems_chain_get (&buffers);
passed = bdbuf_test_print_sc (rtems_bdbuf_release_modified (bd),
@@ -958,7 +942,7 @@ bdbuf_tests_task_0_test_4 (bdbuf_task_control* tc)
if (!rtems_chain_is_empty (&buffers))
{
passed = false;
- bdbuf_test_printf ("%s: buffer chain not empty\n", tc->name);
+ printf ("%s: buffer chain not empty\n", tc->name);
}
}
}
@@ -1004,7 +988,7 @@ bdbuf_tests_task_0_test_6 (bdbuf_task_control* tc)
for (i = 0; (i < 5) && passed; i++)
{
- bdbuf_test_printf ("%s: rtems_bdbuf_read[%d]: ", tc->name, i);
+ printf ("%s: rtems_bdbuf_read[%d]: ", tc->name, i);
sc = rtems_bdbuf_get (tc->dd, i, &bd);
if (!bdbuf_test_print_sc (sc, true))
passed = false;
@@ -1014,7 +998,7 @@ bdbuf_tests_task_0_test_6 (bdbuf_task_control* tc)
for (i = 0; (i < 4) && passed; i++)
{
- bdbuf_test_printf ("%s: rtems_bdbuf_release_modified[%d]: ",
+ printf ("%s: rtems_bdbuf_release_modified[%d]: ",
tc->name, i);
bd = (rtems_bdbuf_buffer*) rtems_chain_get (&buffers);
passed = bdbuf_test_print_sc (rtems_bdbuf_release_modified (bd),
@@ -1023,7 +1007,7 @@ bdbuf_tests_task_0_test_6 (bdbuf_task_control* tc)
if (passed)
{
- bdbuf_test_printf ("%s: rtems_bdbuf_sync[%d]: ", tc->name, i);
+ printf ("%s: rtems_bdbuf_sync[%d]: ", tc->name, i);
bd = (rtems_bdbuf_buffer*) rtems_chain_get (&buffers);
passed = bdbuf_test_print_sc (rtems_bdbuf_sync (bd), true);
@@ -1061,7 +1045,7 @@ bdbuf_tests_task_0_test_7 (bdbuf_task_control* tc)
for (i = 0; (i < 5) && passed; i++)
{
- bdbuf_test_printf ("%s: rtems_bdbuf_read[%d]: ", tc->name, i);
+ printf ("%s: rtems_bdbuf_read[%d]: ", tc->name, i);
sc = rtems_bdbuf_get (tc->dd, i, &bd);
if (!bdbuf_test_print_sc (sc, true))
passed = false;
@@ -1071,7 +1055,7 @@ bdbuf_tests_task_0_test_7 (bdbuf_task_control* tc)
for (i = 0; (i < 5) && passed; i++)
{
- bdbuf_test_printf ("%s: rtems_bdbuf_release_modified[%d]: ",
+ printf ("%s: rtems_bdbuf_release_modified[%d]: ",
tc->name, i);
bd = (rtems_bdbuf_buffer*) rtems_chain_get (&buffers);
passed = bdbuf_test_print_sc (rtems_bdbuf_release_modified (bd),
@@ -1080,7 +1064,7 @@ bdbuf_tests_task_0_test_7 (bdbuf_task_control* tc)
if (passed)
{
- bdbuf_test_printf ("%s: rtems_bdbuf_syncdev[%d:%d]: ",
+ printf ("%s: rtems_bdbuf_syncdev[%d:%d]: ",
tc->name, i,
tc->major,
tc->minor);
@@ -1121,7 +1105,7 @@ bdbuf_tests_task_0_test_8 (bdbuf_task_control* tc)
for (i = 0; (i < 5) && passed; i++)
{
- bdbuf_test_printf ("%s: rtems_bdbuf_read[%d]: ", tc->name, i);
+ printf ("%s: rtems_bdbuf_read[%d]: ", tc->name, i);
sc = rtems_bdbuf_get (tc->dd, i, &bd);
if (!bdbuf_test_print_sc (sc, true))
passed = false;
@@ -1136,19 +1120,19 @@ bdbuf_tests_task_0_test_8 (bdbuf_task_control* tc)
pnode = node->previous;
rtems_chain_extract (node);
node = pnode;
- bdbuf_test_printf ("%s: rtems_bdbuf_release_modified[4]: ", tc->name);
+ printf ("%s: rtems_bdbuf_release_modified[4]: ", tc->name);
passed = bdbuf_test_print_sc (rtems_bdbuf_release_modified (bd), true);
bd = (rtems_bdbuf_buffer*) node;
pnode = node->previous;
rtems_chain_extract (node);
node = pnode;
- bdbuf_test_printf ("%s: rtems_bdbuf_release_modified[3]: ", tc->name);
+ printf ("%s: rtems_bdbuf_release_modified[3]: ", tc->name);
passed = bdbuf_test_print_sc (rtems_bdbuf_release_modified (bd), true);
for (i = 0; (i < 3) && passed; i++)
{
- bdbuf_test_printf ("%s: rtems_bdbuf_release_modified[%d]: ",
+ printf ("%s: rtems_bdbuf_release_modified[%d]: ",
tc->name, i);
bd = (rtems_bdbuf_buffer*) rtems_chain_get (&buffers);
passed = bdbuf_test_print_sc (rtems_bdbuf_release_modified (bd),
@@ -1162,12 +1146,12 @@ bdbuf_tests_task_0_test_8 (bdbuf_task_control* tc)
*/
bdbuf_set_disk_driver_action (tc, BDBUF_DISK_BLOCKS_INORDER);
- bdbuf_test_printf ("%s: rtems_bdbuf_syncdev[%d:%d]: checking order\n",
+ printf ("%s: rtems_bdbuf_syncdev[%d:%d]: checking order\n",
tc->name, i,
tc->major,
tc->minor);
sc = rtems_bdbuf_syncdev (tc->dd);
- bdbuf_test_printf ("%s: rtems_bdbuf_syncdev[%d:%d]: ",
+ printf ("%s: rtems_bdbuf_syncdev[%d:%d]: ",
tc->name, i,
tc->major,
tc->minor);
@@ -1230,14 +1214,14 @@ bdbuf_tests_task_0 (rtems_task_argument arg)
/*
* Invalid test for this task. An error.
*/
- bdbuf_test_printf ("%s: invalid test: %d\n", tc->name, tc->test);
+ printf ("%s: invalid test: %d\n", tc->name, tc->test);
tc->passed = false;
tc->test = 0;
break;
}
}
- bdbuf_test_printf ("%s: delete task\n", tc->name);
+ printf ("%s: delete task\n", tc->name);
rtems_task_delete (RTEMS_SELF);
}
@@ -1264,16 +1248,16 @@ bdbuf_tests_ranged_get_release (bdbuf_task_control* tc,
for (i = lower; (i < upper) && passed; i++)
{
- bdbuf_test_printf ("%s: rtems_bdbuf_get[%d]: blocking ...\n", tc->name, i);
+ printf ("%s: rtems_bdbuf_get[%d]: blocking ...\n", tc->name, i);
sc = rtems_bdbuf_get (tc->dd, i, &bd);
- bdbuf_test_printf ("%s: rtems_bdbuf_get[%d]: ", tc->name, i);
+ printf ("%s: rtems_bdbuf_get[%d]: ", tc->name, i);
if (!bdbuf_test_print_sc (sc, true))
{
passed = false;
break;
}
- bdbuf_test_printf ("%s: rtems_bdbuf_release[%d]: ", tc->name, i);
+ printf ("%s: rtems_bdbuf_release[%d]: ", tc->name, i);
sc = rtems_bdbuf_release (bd);
if (!bdbuf_test_print_sc (sc, true))
{
@@ -1324,14 +1308,14 @@ bdbuf_tests_task_1 (rtems_task_argument arg)
/*
* Invalid test for this task. An error.
*/
- bdbuf_test_printf ("%s: invalid test: %d\n", tc->name, tc->test);
+ printf ("%s: invalid test: %d\n", tc->name, tc->test);
tc->passed = false;
tc->test = 0;
break;
}
}
- bdbuf_test_printf ("%s: delete task\n", tc->name);
+ printf ("%s: delete task\n", tc->name);
rtems_task_delete (RTEMS_SELF);
}
@@ -1372,14 +1356,14 @@ bdbuf_tests_task_2 (rtems_task_argument arg)
/*
* Invalid test for this task. An error.
*/
- bdbuf_test_printf ("%s: invalid test: %d\n", tc->name, tc->test);
+ printf ("%s: invalid test: %d\n", tc->name, tc->test);
tc->passed = false;
tc->test = 0;
break;
}
}
- bdbuf_test_printf ("%s: delete task\n", tc->name);
+ printf ("%s: delete task\n", tc->name);
rtems_task_delete (RTEMS_SELF);
}
@@ -1426,7 +1410,7 @@ bdbuf_tests_finished (bdbuf_task_control* tasks)
}
if (!finished)
- bdbuf_test_printf ("master: test timed out\n");
+ printf ("master: test timed out\n");
else
{
int t;
@@ -1778,7 +1762,7 @@ bdbuf_tester (void)
/*
* Change priority to a lower one.
*/
- bdbuf_test_printf ("lower priority to %d: ", BDBUF_TESTS_PRI_HIGH + 1);
+ printf ("lower priority to %d: ", BDBUF_TESTS_PRI_HIGH + 1);
bdbuf_test_print_sc (rtems_task_set_priority (RTEMS_SELF,
BDBUF_TESTS_PRI_HIGH + 1,
&old_priority),
@@ -1789,7 +1773,7 @@ bdbuf_tester (void)
*/
if (!bdbuf_tests_setup_disk (&major, &dd))
{
- bdbuf_test_printf ("disk set up failed\n");
+ printf ("disk set up failed\n");
return;
}
@@ -1827,9 +1811,9 @@ bdbuf_tester (void)
*/
for (t = 0; (t < BDBUF_TEST_NUM) && passed; t++)
{
- bdbuf_test_printf ("test %d: %s\n", t + 1, bdbuf_tests[t].label);
+ printf ("test %d: %s\n", t + 1, bdbuf_tests[t].label);
passed = bdbuf_tests[t].test (tasks);
- bdbuf_test_printf ("test %d: %s\n", t + 1, passed ? "passed" : "failed");
+ printf ("test %d: %s\n", t + 1, passed ? "passed" : "failed");
}
}
diff --git a/testsuites/libtests/block07/init.c b/testsuites/libtests/block07/init.c
index cd1b64abae..727bb6f89d 100644
--- a/testsuites/libtests/block07/init.c
+++ b/testsuites/libtests/block07/init.c
@@ -23,12 +23,14 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <sys/ioctl.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
-#define TESTS_USE_PRINTK
+#define TESTS_USE_PRINTF
#include "tmacros.h"
#include <rtems.h>
@@ -88,21 +90,21 @@ static void task_low(rtems_task_argument arg)
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_bdbuf_buffer *bd = NULL;
- printk("L: try access: 0\n");
+ printf("L: try access: 0\n");
sc = rtems_bdbuf_get(dd, 0, &bd);
ASSERT_SC(sc);
- printk("L: access: 0\n");
+ printf("L: access: 0\n");
rtems_test_assert(bd->group->bds_per_group == 2);
- printk("L: release: 0\n");
+ printf("L: release: 0\n");
sc = rtems_bdbuf_release(bd);
ASSERT_SC(sc);
- printk("L: release done: 0\n");
+ printf("L: release done: 0\n");
TEST_END();
@@ -114,21 +116,21 @@ static void task_mid(rtems_task_argument arg)
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_bdbuf_buffer *bd = NULL;
- printk("M: try access: 0\n");
+ printf("M: try access: 0\n");
sc = rtems_bdbuf_get(dd, 0, &bd);
ASSERT_SC(sc);
- printk("M: access: 0\n");
+ printf("M: access: 0\n");
rtems_test_assert(bd->group->bds_per_group == 1);
- printk("M: release: 0\n");
+ printf("M: release: 0\n");
sc = rtems_bdbuf_release(bd);
ASSERT_SC(sc);
- printk("M: release done: 0\n");
+ printf("M: release done: 0\n");
rtems_task_delete(RTEMS_SELF);
}
@@ -140,21 +142,21 @@ static void task_high(rtems_task_argument arg)
change_block_size();
- printk("H: try access: 0\n");
+ printf("H: try access: 0\n");
sc = rtems_bdbuf_get(dd, 0, &bd);
ASSERT_SC(sc);
- printk("H: access: 0\n");
+ printf("H: access: 0\n");
rtems_test_assert(bd->group->bds_per_group == 1);
- printk("H: release: 0\n");
+ printf("H: release: 0\n");
sc = rtems_bdbuf_release(bd);
ASSERT_SC(sc);
- printk("H: release done: 0\n");
+ printf("H: release done: 0\n");
rtems_task_delete(RTEMS_SELF);
}
@@ -228,12 +230,12 @@ static rtems_task Init(rtems_task_argument argument)
sc = rtems_bdbuf_release(bd);
ASSERT_SC(sc);
- printk("I: try access: 0\n");
+ printf("I: try access: 0\n");
sc = rtems_bdbuf_get(dd, 0, &bd);
ASSERT_SC(sc);
- printk("I: access: 0\n");
+ printf("I: access: 0\n");
sc = rtems_task_set_priority(RTEMS_SELF, PRIORITY_IDLE, &cur_prio);
ASSERT_SC(sc);
@@ -247,12 +249,12 @@ static rtems_task Init(rtems_task_argument argument)
sc = rtems_task_set_priority(RTEMS_SELF, PRIORITY_INIT, &cur_prio);
ASSERT_SC(sc);
- printk("I: release: 0\n");
+ printf("I: release: 0\n");
sc = rtems_bdbuf_release(bd);
ASSERT_SC(sc);
- printk("I: release done: 0\n");
+ printf("I: release done: 0\n");
rtems_task_delete(RTEMS_SELF);
}
diff --git a/testsuites/libtests/block08/bdbuf_test3_2.c b/testsuites/libtests/block08/bdbuf_test3_2.c
index e9cfc9e1a2..aba2bea095 100644
--- a/testsuites/libtests/block08/bdbuf_test3_2.c
+++ b/testsuites/libtests/block08/bdbuf_test3_2.c
@@ -154,7 +154,7 @@ bdbuf_test3_2_thread2(rtems_task_argument arg)
TEST_FAILED();
}
- printk("Thread #2 DEBLOCK\n");
+ printf("Thread #2 DEBLOCK\n");
CONTINUE_MAIN(2);
rc = rtems_bdbuf_release_modified(bd);
@@ -184,7 +184,7 @@ bdbuf_test3_2_thread3(rtems_task_argument arg)
TEST_FAILED();
}
- printk("Thread #3 DEBLOCK\n");
+ printf("Thread #3 DEBLOCK\n");
CONTINUE_MAIN(3);
diff --git a/testsuites/libtests/block08/bdbuf_test3_3.c b/testsuites/libtests/block08/bdbuf_test3_3.c
index 9b3080b13e..562bb78ddb 100644
--- a/testsuites/libtests/block08/bdbuf_test3_3.c
+++ b/testsuites/libtests/block08/bdbuf_test3_3.c
@@ -165,7 +165,7 @@ bdbuf_test3_3_thread2(rtems_task_argument arg)
TEST_FAILED();
}
- printk("Thread #2 DEBLOCK\n");
+ printf("Thread #2 DEBLOCK\n");
CONTINUE_MAIN(2);
rc = rtems_bdbuf_release(bd);
@@ -195,7 +195,7 @@ bdbuf_test3_3_thread3(rtems_task_argument arg)
TEST_FAILED();
}
- printk("Thread #3 DEBLOCK\n");
+ printf("Thread #3 DEBLOCK\n");
CONTINUE_MAIN(3);
diff --git a/testsuites/libtests/block08/bdbuf_tests.c b/testsuites/libtests/block08/bdbuf_tests.c
index c918d937ba..66e69d4fbd 100644
--- a/testsuites/libtests/block08/bdbuf_tests.c
+++ b/testsuites/libtests/block08/bdbuf_tests.c
@@ -33,14 +33,14 @@ struct bdbuf_test_descr {
{ bdbuf_test1_3_main },
{ bdbuf_test1_4_main },
{ bdbuf_test1_5_main },
-
+
{ bdbuf_test2_1_main },
{ bdbuf_test2_2_main },
-
+
{ bdbuf_test3_1_main },
{ bdbuf_test3_2_main },
{ bdbuf_test3_3_main },
-
+
{ bdbuf_test4_1_main },
{ bdbuf_test4_2_main },
{ bdbuf_test4_3_main },
@@ -88,7 +88,7 @@ bdbuf_test_start_aux_task(rtems_name name,
printf("Failed to create task\n");
return rc;
}
-
+
rc = rtems_task_start(task_id, entry_point, arg);
if (rc != RTEMS_SUCCESSFUL)
{
@@ -126,7 +126,7 @@ run_bdbuf_tests()
if (sc != RTEMS_SUCCESSFUL)
{
- printk("Failed to create message queue for test task: %u\n", sc);
+ printf("Failed to create message queue for test task: %u\n", sc);
return;
}
@@ -134,14 +134,14 @@ run_bdbuf_tests()
sc = rtems_io_register_driver(0, &testdisk, &major);
if (sc != RTEMS_SUCCESSFUL)
{
- printk("Failed to register TEST DEVICE: %d\n", sc);
+ printf("Failed to register TEST DEVICE: %d\n", sc);
return;
}
test_dev = -1;
while ((disk = rtems_disk_next(dev)) != NULL)
{
- printk(
+ printf(
"DEV: %s [%" PRIdrtems_blkdev_bnum "]\n",
disk->name,
disk->size
@@ -185,7 +185,7 @@ run_bdbuf_tests()
&g_test_ctx.test_sync_main[i]);
if (sc != RTEMS_SUCCESSFUL)
{
- printk("Failed to create sync sem for test task: %u\n", sc);
+ printf("Failed to create sync sem for test task: %u\n", sc);
return;
}
}
@@ -197,17 +197,17 @@ run_bdbuf_tests()
&g_test_ctx.test_sync[i]);
if (sc != RTEMS_SUCCESSFUL)
{
- printk("Failed to create sync sem for test task #%d: %u\n", i + 1, sc);
+ printf("Failed to create sync sem for test task #%d: %u\n", i + 1, sc);
return;
}
}
-
+
sc = rtems_semaphore_create(rtems_build_name('T', 'S', 'M', 'E'),
0, TEST_SEM_ATTRIBS, 0,
&g_test_ctx.test_end_main);
if (sc != RTEMS_SUCCESSFUL)
{
- printk("Failed to create end sync sem for test task: %u\n", sc);
+ printf("Failed to create end sync sem for test task: %u\n", sc);
return;
}
@@ -249,7 +249,7 @@ bdbuf_test_start_thread(unsigned int idx, rtems_task_entry func)
sc = rtems_task_delete(g_test_ctx.test_task[idx]);
if (sc != RTEMS_SUCCESSFUL)
{
- printk("Failed to delete test thread %u in test %s\n",
+ printf("Failed to delete test thread %u in test %s\n",
idx + 1, g_test_ctx.test_name);
return sc;
}
@@ -275,11 +275,10 @@ bdbuf_test_end()
RTEMS_WAIT, RTEMS_NO_TIMEOUT);
if (sc != RTEMS_SUCCESSFUL)
{
- printk("Failed to get a thread stopped\n");
+ printf("Failed to get a thread stopped\n");
}
g_test_ctx.test_task[i] = OBJECTS_ID_NONE;
}
}
return RTEMS_SUCCESSFUL;
}
-
diff --git a/testsuites/libtests/block08/init.c b/testsuites/libtests/block08/init.c
index 83eaf6d534..e712b07f42 100644
--- a/testsuites/libtests/block08/init.c
+++ b/testsuites/libtests/block08/init.c
@@ -19,6 +19,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#define CONFIGURE_INIT
diff --git a/testsuites/libtests/block08/test_disk.c b/testsuites/libtests/block08/test_disk.c
index 9a4c5bf2b1..aa33803b23 100644
--- a/testsuites/libtests/block08/test_disk.c
+++ b/testsuites/libtests/block08/test_disk.c
@@ -46,19 +46,19 @@ test_disk_ioctl(rtems_disk_device *dd, uint32_t req, void *argp)
r = argp;
- printk("DISK_DRV: %s ",
+ printf("DISK_DRV: %s ",
r->req == RTEMS_BLKDEV_REQ_READ ? "R" :
r->req == RTEMS_BLKDEV_REQ_WRITE ? "W" : "?");
for (i = 0, sg = r->bufs; i < r->bufnum; i++, sg++)
{
- printk("[%" PRIu32 "] ", sg->block);
+ printf("[%" PRIu32 "] ", sg->block);
}
- printk("\n");
+ printf("\n");
break;
}
default:
- printk("%s() Unexpected request comes %" PRIu32 "\n",
+ printf("%s() Unexpected request comes %" PRIu32 "\n",
__FUNCTION__, req);
return -1;
}
@@ -135,7 +135,7 @@ test_disk_initialize(
rc = bdbuf_test_create_drv_rx_queue(&drvq_id);
if (rc != RTEMS_SUCCESSFUL)
{
- printk("%s() Failed to create Msg Queue for RX: %u\n",
+ printf("%s() Failed to create Msg Queue for RX: %u\n",
__FUNCTION__, rc);
return rc;
}
@@ -148,6 +148,6 @@ test_disk_initialize(
return rc;
}
- printk("TEST DISK - OK\n");
+ printf("TEST DISK - OK\n");
return RTEMS_SUCCESSFUL;
}
diff --git a/testsuites/libtests/block09/init.c b/testsuites/libtests/block09/init.c
index 45e3b7ad39..3ad283ec59 100644
--- a/testsuites/libtests/block09/init.c
+++ b/testsuites/libtests/block09/init.c
@@ -24,6 +24,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define TESTS_USE_PRINTK
#include "tmacros.h"
diff --git a/testsuites/libtests/block10/init.c b/testsuites/libtests/block10/init.c
index 1cdc91ebb1..98277444e2 100644
--- a/testsuites/libtests/block10/init.c
+++ b/testsuites/libtests/block10/init.c
@@ -23,7 +23,9 @@
#include "config.h"
#endif
-#define TESTS_USE_PRINTK
+#define TEST_INIT
+
+#define TESTS_USE_PRINTF
#include "tmacros.h"
#include <assert.h>
@@ -157,12 +159,12 @@ static rtems_bdbuf_buffer *do_get(char task)
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_bdbuf_buffer *bd = NULL;
- printk("%c: try get\n", task);
+ printf("%c: try get\n", task);
sc = rtems_bdbuf_get(dd, 0, &bd);
ASSERT_SC(sc);
- printk("%c: get\n", task);
+ printf("%c: get\n", task);
return bd;
}
@@ -172,7 +174,7 @@ static rtems_bdbuf_buffer *do_get_mod(char task)
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_bdbuf_buffer *bd = NULL;
- printk("%c: try get modified\n", task);
+ printf("%c: try get modified\n", task);
sc = rtems_bdbuf_get(dd, 0, &bd);
ASSERT_SC(sc);
@@ -183,7 +185,7 @@ static rtems_bdbuf_buffer *do_get_mod(char task)
sc = rtems_bdbuf_get(dd, 0, &bd);
ASSERT_SC(sc);
- printk("%c: get modified\n", task);
+ printf("%c: get modified\n", task);
return bd;
}
@@ -193,12 +195,12 @@ static rtems_bdbuf_buffer *do_read(char task)
rtems_status_code sc = RTEMS_SUCCESSFUL;
rtems_bdbuf_buffer *bd = NULL;
- printk("%c: try read\n", task);
+ printf("%c: try read\n", task);
sc = rtems_bdbuf_read(dd, 0, &bd);
ASSERT_SC(sc);
- printk("%c: read\n", task);
+ printf("%c: read\n", task);
return bd;
}
@@ -207,41 +209,41 @@ static void do_rel(char task, rtems_bdbuf_buffer *bd)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
- printk("%c: release\n", task);
+ printf("%c: release\n", task);
sc = rtems_bdbuf_release(bd);
ASSERT_SC(sc);
- printk("%c: release done\n", task);
+ printf("%c: release done\n", task);
}
static void do_rel_mod(char task, rtems_bdbuf_buffer *bd)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
- printk("%c: release modified\n", task);
+ printf("%c: release modified\n", task);
sc = rtems_bdbuf_release_modified(bd);
ASSERT_SC(sc);
- printk("%c: release modified done\n", task);
+ printf("%c: release modified done\n", task);
}
static void do_sync(char task, rtems_bdbuf_buffer *bd)
{
rtems_status_code sc = RTEMS_SUCCESSFUL;
- printk("%c: sync\n", task);
+ printf("%c: sync\n", task);
sc = rtems_bdbuf_sync(bd);
ASSERT_SC(sc);
- printk("%c: sync done\n", task);
+ printf("%c: sync done\n", task);
}
static void purge(char task)
{
- printk("%c: purge\n", task);
+ printf("%c: purge\n", task);
rtems_bdbuf_purge_dev(dd);
}
@@ -449,7 +451,7 @@ static rtems_task Init(rtems_task_argument argument)
for (i_ac = 0; i_ac < ACCESS_COUNT; ++i_ac) {
for (i_rel = 0; i_rel < RELEASE_COUNT; ++i_rel) {
for (i_w = 0; i_w < WAITER_COUNT; ++i_w) {
- printk("test case [access]: %s and %s %s\n", access_assoc_table [i_ac], release_assoc_table [i_rel], waiter_assoc_table [i_w]);
+ printf("test case [access]: %s and %s %s\n", access_assoc_table [i_ac], release_assoc_table [i_rel], waiter_assoc_table [i_w]);
check_access(access_table [i_ac], release_table [i_rel], waiter_table [i_w]);
}
}
@@ -457,14 +459,14 @@ static rtems_task Init(rtems_task_argument argument)
for (i_rel = 0; i_rel < RELEASE_COUNT; ++i_rel) {
for (i_w = 0; i_w < WAITER_COUNT; ++i_w) {
- printk("test case [intermediate]: %s %s\n", release_assoc_table [i_rel], waiter_assoc_table [i_w]);
+ printf("test case [intermediate]: %s %s\n", release_assoc_table [i_rel], waiter_assoc_table [i_w]);
check_intermediate(release_table [i_rel], waiter_table [i_w]);
}
}
for (i_p = 0; i_p < PURGER_COUNT; ++i_p) {
for (i_w = 0; i_w < WAITER_COUNT; ++i_w) {
- printk("test case [transfer]: %s %s\n", purger_assoc_table [i_p], waiter_assoc_table [i_w]);
+ printf("test case [transfer]: %s %s\n", purger_assoc_table [i_p], waiter_assoc_table [i_w]);
check_transfer(purger_table [i_p], waiter_table [i_w]);
}
}
diff --git a/testsuites/libtests/block11/init.c b/testsuites/libtests/block11/init.c
index 4d19d1917b..68f962f5e7 100644
--- a/testsuites/libtests/block11/init.c
+++ b/testsuites/libtests/block11/init.c
@@ -24,6 +24,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <sys/stat.h>
diff --git a/testsuites/libtests/block12/init.c b/testsuites/libtests/block12/init.c
index 5b749773dc..c7a409d6a6 100644
--- a/testsuites/libtests/block12/init.c
+++ b/testsuites/libtests/block12/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <errno.h>
diff --git a/testsuites/libtests/block13/init.c b/testsuites/libtests/block13/init.c
index 82c9b3a4a9..c936e0c26b 100644
--- a/testsuites/libtests/block13/init.c
+++ b/testsuites/libtests/block13/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <errno.h>
diff --git a/testsuites/libtests/block14/init.c b/testsuites/libtests/block14/init.c
index 0c2bed7bee..fcbb1b5f66 100644
--- a/testsuites/libtests/block14/init.c
+++ b/testsuites/libtests/block14/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <errno.h>
diff --git a/testsuites/libtests/block15/init.c b/testsuites/libtests/block15/init.c
index 19d30d17bf..fa2f1dd83f 100644
--- a/testsuites/libtests/block15/init.c
+++ b/testsuites/libtests/block15/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <errno.h>
diff --git a/testsuites/libtests/block16/init.c b/testsuites/libtests/block16/init.c
index c7d41480a9..0c83f05b28 100644
--- a/testsuites/libtests/block16/init.c
+++ b/testsuites/libtests/block16/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <sys/ioctl.h>
diff --git a/testsuites/libtests/block17/init.c b/testsuites/libtests/block17/init.c
index 384cb95a48..43dcde066e 100644
--- a/testsuites/libtests/block17/init.c
+++ b/testsuites/libtests/block17/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <rtems/bdbuf.h>
#include "tmacros.h"
diff --git a/testsuites/libtests/bspcmdline01/init.c b/testsuites/libtests/bspcmdline01/init.c
index bea50211e2..64d70bce07 100644
--- a/testsuites/libtests/bspcmdline01/init.c
+++ b/testsuites/libtests/bspcmdline01/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <tmacros.h>
#include <rtems/bspcmdline.h>
diff --git a/testsuites/libtests/capture01/init.c b/testsuites/libtests/capture01/init.c
index 7a2491594b..8062cbbd75 100644
--- a/testsuites/libtests/capture01/init.c
+++ b/testsuites/libtests/capture01/init.c
@@ -13,6 +13,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "system.h"
#include <ctype.h>
#include <stdlib.h>
diff --git a/testsuites/libtests/cpuuse/init.c b/testsuites/libtests/cpuuse/init.c
index 11fb273733..899b7db262 100644
--- a/testsuites/libtests/cpuuse/init.c
+++ b/testsuites/libtests/cpuuse/init.c
@@ -19,6 +19,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define CONFIGURE_INIT
#include "system.h"
diff --git a/testsuites/libtests/crypt01/init.c b/testsuites/libtests/crypt01/init.c
index 545c533feb..7c9dca0f8d 100644
--- a/testsuites/libtests/crypt01/init.c
+++ b/testsuites/libtests/crypt01/init.c
@@ -39,6 +39,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <crypt.h>
#include <string.h>
diff --git a/testsuites/libtests/debugger01/init.c b/testsuites/libtests/debugger01/init.c
index e243d424a5..e7db8fe15d 100644
--- a/testsuites/libtests/debugger01/init.c
+++ b/testsuites/libtests/debugger01/init.c
@@ -12,6 +12,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define CONFIGURE_INIT
#include "system.h"
diff --git a/testsuites/libtests/defaultconfig01/init.c b/testsuites/libtests/defaultconfig01/init.c
index 21c326dcbd..66bb9d39a1 100644
--- a/testsuites/libtests/defaultconfig01/init.c
+++ b/testsuites/libtests/defaultconfig01/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <stdio.h>
#include <bsp.h>
diff --git a/testsuites/libtests/devfs01/init.c b/testsuites/libtests/devfs01/init.c
index 1bfae95e97..66e702f61a 100644
--- a/testsuites/libtests/devfs01/init.c
+++ b/testsuites/libtests/devfs01/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define TESTS_USE_PRINTK
#include <tmacros.h>
#include "test_support.h"
diff --git a/testsuites/libtests/devfs02/init.c b/testsuites/libtests/devfs02/init.c
index 95ea10ddd6..740407202c 100644
--- a/testsuites/libtests/devfs02/init.c
+++ b/testsuites/libtests/devfs02/init.c
@@ -14,6 +14,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "test_support.h"
#define TESTS_USE_PRINTK
diff --git a/testsuites/libtests/devfs03/init.c b/testsuites/libtests/devfs03/init.c
index 147deeb424..34d488b892 100644
--- a/testsuites/libtests/devfs03/init.c
+++ b/testsuites/libtests/devfs03/init.c
@@ -14,6 +14,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <tmacros.h>
#include "test_support.h"
#include <rtems/devfs.h>
diff --git a/testsuites/libtests/devfs04/init.c b/testsuites/libtests/devfs04/init.c
index 707deeccbe..96b68df0f8 100644
--- a/testsuites/libtests/devfs04/init.c
+++ b/testsuites/libtests/devfs04/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define TESTS_USE_PRINTK
#include <tmacros.h>
#include "test_support.h"
diff --git a/testsuites/libtests/deviceio01/init.c b/testsuites/libtests/deviceio01/init.c
index 519719d546..6271463407 100644
--- a/testsuites/libtests/deviceio01/init.c
+++ b/testsuites/libtests/deviceio01/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <tmacros.h>
#include "test_support.h"
#include <rtems/devfs.h>
diff --git a/testsuites/libtests/dl01/init.c b/testsuites/libtests/dl01/init.c
index ec7ae1a413..d511c198d1 100644
--- a/testsuites/libtests/dl01/init.c
+++ b/testsuites/libtests/dl01/init.c
@@ -10,6 +10,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <errno.h>
diff --git a/testsuites/libtests/dl02/init.c b/testsuites/libtests/dl02/init.c
index bf2d1a9717..b796b9ed95 100644
--- a/testsuites/libtests/dl02/init.c
+++ b/testsuites/libtests/dl02/init.c
@@ -10,6 +10,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <errno.h>
diff --git a/testsuites/libtests/dl03/init.c b/testsuites/libtests/dl03/init.c
index ae8272294c..ddfda7a767 100644
--- a/testsuites/libtests/dl03/init.c
+++ b/testsuites/libtests/dl03/init.c
@@ -10,6 +10,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <errno.h>
diff --git a/testsuites/libtests/dl04/init.c b/testsuites/libtests/dl04/init.c
index eb3018e393..d8655a6607 100644
--- a/testsuites/libtests/dl04/init.c
+++ b/testsuites/libtests/dl04/init.c
@@ -10,6 +10,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <errno.h>
diff --git a/testsuites/libtests/dl05/init.c b/testsuites/libtests/dl05/init.c
index 0c58204139..a224f9a216 100644
--- a/testsuites/libtests/dl05/init.c
+++ b/testsuites/libtests/dl05/init.c
@@ -10,6 +10,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <errno.h>
diff --git a/testsuites/libtests/dumpbuf01/init.c b/testsuites/libtests/dumpbuf01/init.c
index e9671cd144..4d03ffcf78 100644
--- a/testsuites/libtests/dumpbuf01/init.c
+++ b/testsuites/libtests/dumpbuf01/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <tmacros.h>
#include "test_support.h"
#include <rtems/dumpbuf.h>
diff --git a/testsuites/libtests/exit01/init.c b/testsuites/libtests/exit01/init.c
index 0fd8d356f0..3592644319 100644
--- a/testsuites/libtests/exit01/init.c
+++ b/testsuites/libtests/exit01/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define TESTS_USE_PRINTK
#include "tmacros.h"
diff --git a/testsuites/libtests/exit02/init.c b/testsuites/libtests/exit02/init.c
index 48248a569a..2aa3f33f30 100644
--- a/testsuites/libtests/exit02/init.c
+++ b/testsuites/libtests/exit02/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define TESTS_USE_PRINTK
#include "tmacros.h"
diff --git a/testsuites/libtests/flashdisk01/init.c b/testsuites/libtests/flashdisk01/init.c
index ea1b583895..276ba5d728 100644
--- a/testsuites/libtests/flashdisk01/init.c
+++ b/testsuites/libtests/flashdisk01/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <sys/stat.h>
diff --git a/testsuites/libtests/ftp01/init.c b/testsuites/libtests/ftp01/init.c
index ad166c3f77..af8dd0773a 100644
--- a/testsuites/libtests/ftp01/init.c
+++ b/testsuites/libtests/ftp01/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <sys/stat.h>
#include <fcntl.h>
#include <string.h>
diff --git a/testsuites/libtests/gxx01/init.c b/testsuites/libtests/gxx01/init.c
index a0debcdc91..c73e2b236e 100644
--- a/testsuites/libtests/gxx01/init.c
+++ b/testsuites/libtests/gxx01/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <errno.h>
#include <tmacros.h>
#include "test_support.h"
diff --git a/testsuites/libtests/heapwalk/init.c b/testsuites/libtests/heapwalk/init.c
index 3bd6c91ce4..7d221aa811 100644
--- a/testsuites/libtests/heapwalk/init.c
+++ b/testsuites/libtests/heapwalk/init.c
@@ -15,6 +15,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define CONFIGURE_INIT
#include "system.h"
diff --git a/testsuites/libtests/i2c01/init.c b/testsuites/libtests/i2c01/init.c
index 0d6fc839f3..9994a9cf70 100644
--- a/testsuites/libtests/i2c01/init.c
+++ b/testsuites/libtests/i2c01/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <dev/i2c/i2c.h>
#include <dev/i2c/eeprom.h>
#include <dev/i2c/gpio-nxp-pca9535.h>
diff --git a/testsuites/libtests/libfdt01/init.c b/testsuites/libtests/libfdt01/init.c
index a13fc82021..9324aa9d58 100644
--- a/testsuites/libtests/libfdt01/init.c
+++ b/testsuites/libtests/libfdt01/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <libfdt.h>
diff --git a/testsuites/libtests/malloc02/init.c b/testsuites/libtests/malloc02/init.c
index c333b22862..d3937ca721 100644
--- a/testsuites/libtests/malloc02/init.c
+++ b/testsuites/libtests/malloc02/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <tmacros.h>
const char rtems_test_name[] = "MALLOC 2";
diff --git a/testsuites/libtests/malloc03/init.c b/testsuites/libtests/malloc03/init.c
index 3b23a07c79..51d1c132aa 100644
--- a/testsuites/libtests/malloc03/init.c
+++ b/testsuites/libtests/malloc03/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <tmacros.h>
#include "test_support.h"
diff --git a/testsuites/libtests/malloc04/init.c b/testsuites/libtests/malloc04/init.c
index dabbf98e61..3fc690651b 100644
--- a/testsuites/libtests/malloc04/init.c
+++ b/testsuites/libtests/malloc04/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <tmacros.h>
#include "test_support.h"
#include <rtems/libcsupport.h>
diff --git a/testsuites/libtests/malloctest/init.c b/testsuites/libtests/malloctest/init.c
index 6be6c1c25d..59aa1a105b 100644
--- a/testsuites/libtests/malloctest/init.c
+++ b/testsuites/libtests/malloctest/init.c
@@ -13,6 +13,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define CONFIGURE_INIT
#include "system.h"
diff --git a/testsuites/libtests/md501/init.c b/testsuites/libtests/md501/init.c
index 124c2d7b9b..f743454fdf 100644
--- a/testsuites/libtests/md501/init.c
+++ b/testsuites/libtests/md501/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <md5.h>
diff --git a/testsuites/libtests/mghttpd01/init.c b/testsuites/libtests/mghttpd01/init.c
index 39071a8dfb..31f0972ff5 100644
--- a/testsuites/libtests/mghttpd01/init.c
+++ b/testsuites/libtests/mghttpd01/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <rtems.h>
#include <tmacros.h>
diff --git a/testsuites/libtests/monitor/init.c b/testsuites/libtests/monitor/init.c
index 15112285d9..e579d3c01d 100644
--- a/testsuites/libtests/monitor/init.c
+++ b/testsuites/libtests/monitor/init.c
@@ -15,6 +15,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define CONFIGURE_INIT
#include "system.h"
diff --git a/testsuites/libtests/monitor02/init.c b/testsuites/libtests/monitor02/init.c
index 22818cc441..105f1fd7c8 100644
--- a/testsuites/libtests/monitor02/init.c
+++ b/testsuites/libtests/monitor02/init.c
@@ -15,6 +15,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define CONFIGURE_INIT
#include "bsp.h"
#include "system.h"
diff --git a/testsuites/libtests/mouse01/init.c b/testsuites/libtests/mouse01/init.c
index 944551901c..145887a15a 100644
--- a/testsuites/libtests/mouse01/init.c
+++ b/testsuites/libtests/mouse01/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <bsp.h>
#include <stdlib.h>
diff --git a/testsuites/libtests/networking01/init.c b/testsuites/libtests/networking01/init.c
index f22b3328b1..00f0bd4351 100644
--- a/testsuites/libtests/networking01/init.c
+++ b/testsuites/libtests/networking01/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <sys/socket.h>
#include <netdb.h>
#include <string.h>
diff --git a/testsuites/libtests/newlib01/init.c b/testsuites/libtests/newlib01/init.c
index 24dad1c4c5..bbe260e117 100644
--- a/testsuites/libtests/newlib01/init.c
+++ b/testsuites/libtests/newlib01/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <stdio.h>
#include <rtems.h>
diff --git a/testsuites/libtests/putenvtest/init.c b/testsuites/libtests/putenvtest/init.c
index 0c2ca664e5..a71ed42144 100644
--- a/testsuites/libtests/putenvtest/init.c
+++ b/testsuites/libtests/putenvtest/init.c
@@ -23,6 +23,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define CONFIGURE_INIT
#include <tmacros.h>
#include <stdio.h>
diff --git a/testsuites/libtests/pwdgrp01/init.c b/testsuites/libtests/pwdgrp01/init.c
index bc373672e5..af04cc8085 100644
--- a/testsuites/libtests/pwdgrp01/init.c
+++ b/testsuites/libtests/pwdgrp01/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <sys/stat.h>
#include <sys/types.h>
#include <errno.h>
diff --git a/testsuites/libtests/pwdgrp02/init.c b/testsuites/libtests/pwdgrp02/init.c
index ebc8d0b3fc..15939cdf8c 100644
--- a/testsuites/libtests/pwdgrp02/init.c
+++ b/testsuites/libtests/pwdgrp02/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <sys/stat.h>
#include <sys/types.h>
#include <errno.h>
diff --git a/testsuites/libtests/rbheap01/init.c b/testsuites/libtests/rbheap01/init.c
index a85d107510..c97f6771fd 100644
--- a/testsuites/libtests/rbheap01/init.c
+++ b/testsuites/libtests/rbheap01/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <rtems.h>
diff --git a/testsuites/libtests/rtmonuse/init.c b/testsuites/libtests/rtmonuse/init.c
index a3f2ee10ca..f6cb347b3e 100644
--- a/testsuites/libtests/rtmonuse/init.c
+++ b/testsuites/libtests/rtmonuse/init.c
@@ -23,6 +23,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define CONFIGURE_INIT
#include "system.h"
diff --git a/testsuites/libtests/sha/init.c b/testsuites/libtests/sha/init.c
index 797eec7794..c53f2f8f24 100644
--- a/testsuites/libtests/sha/init.c
+++ b/testsuites/libtests/sha/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <sha256.h>
#include <sha512.h>
#include <stdio.h>
diff --git a/testsuites/libtests/shell01/init.c b/testsuites/libtests/shell01/init.c
index b7ec2d1601..bf3b50dfae 100644
--- a/testsuites/libtests/shell01/init.c
+++ b/testsuites/libtests/shell01/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <sys/stat.h>
#include <sys/types.h>
#include <errno.h>
diff --git a/testsuites/libtests/sparsedisk01/init.c b/testsuites/libtests/sparsedisk01/init.c
index 7c556cd4cf..6d3a648029 100644
--- a/testsuites/libtests/sparsedisk01/init.c
+++ b/testsuites/libtests/sparsedisk01/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <fcntl.h>
#include <rtems/blkdev.h>
#include "rtems/sparse-disk.h"
diff --git a/testsuites/libtests/spi01/init.c b/testsuites/libtests/spi01/init.c
index 990d3ec2b4..e478d7b249 100644
--- a/testsuites/libtests/spi01/init.c
+++ b/testsuites/libtests/spi01/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <dev/spi/spi.h>
#include <sys/ioctl.h>
diff --git a/testsuites/libtests/stackchk/init.c b/testsuites/libtests/stackchk/init.c
index 72e3c23731..a88d01a418 100644
--- a/testsuites/libtests/stackchk/init.c
+++ b/testsuites/libtests/stackchk/init.c
@@ -23,6 +23,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define CONFIGURE_INIT
#include "system.h"
diff --git a/testsuites/libtests/stackchk01/init.c b/testsuites/libtests/stackchk01/init.c
index be0d494e08..cb72c9483e 100644
--- a/testsuites/libtests/stackchk01/init.c
+++ b/testsuites/libtests/stackchk01/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <tmacros.h>
#include <rtems/stackchk.h>
diff --git a/testsuites/libtests/stringto01/init.c b/testsuites/libtests/stringto01/init.c
index d36a4e543f..fd1c262fd6 100644
--- a/testsuites/libtests/stringto01/init.c
+++ b/testsuites/libtests/stringto01/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <rtems/stringto.h>
#include <limits.h>
diff --git a/testsuites/libtests/syscall01/init.c b/testsuites/libtests/syscall01/init.c
index 253b91fd47..b58f73c748 100644
--- a/testsuites/libtests/syscall01/init.c
+++ b/testsuites/libtests/syscall01/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <sys/select.h>
diff --git a/testsuites/libtests/tar01/init.c b/testsuites/libtests/tar01/init.c
index 3316982315..ffc49b68c1 100644
--- a/testsuites/libtests/tar01/init.c
+++ b/testsuites/libtests/tar01/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <bsp.h> /* for device driver prototypes */
#include "tmacros.h"
#include <rtems/untar.h>
diff --git a/testsuites/libtests/tar02/init.c b/testsuites/libtests/tar02/init.c
index 23c1187034..6d0c9a7fbe 100644
--- a/testsuites/libtests/tar02/init.c
+++ b/testsuites/libtests/tar02/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <bsp.h> /* for device driver prototypes */
#include "tmacros.h"
#include <rtems/imfs.h>
diff --git a/testsuites/libtests/tar03/init.c b/testsuites/libtests/tar03/init.c
index 72e95ecd2f..9a79222e4a 100644
--- a/testsuites/libtests/tar03/init.c
+++ b/testsuites/libtests/tar03/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <tmacros.h>
#include "test_support.h"
diff --git a/testsuites/libtests/termios/init.c b/testsuites/libtests/termios/init.c
index 558f095449..deb6a88d47 100644
--- a/testsuites/libtests/termios/init.c
+++ b/testsuites/libtests/termios/init.c
@@ -24,6 +24,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <bsp.h>
#include <rtems/shell.h>
diff --git a/testsuites/libtests/termios01/init.c b/testsuites/libtests/termios01/init.c
index a892762b03..865b55c6ce 100644
--- a/testsuites/libtests/termios01/init.c
+++ b/testsuites/libtests/termios01/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#define TTYDEFCHARS
#include <termios.h>
diff --git a/testsuites/libtests/termios02/init.c b/testsuites/libtests/termios02/init.c
index fe16150513..eead771b5d 100644
--- a/testsuites/libtests/termios02/init.c
+++ b/testsuites/libtests/termios02/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <termios.h>
#include <errno.h>
diff --git a/testsuites/libtests/termios03/init.c b/testsuites/libtests/termios03/init.c
index ab33ac82fd..d18c1c3f28 100644
--- a/testsuites/libtests/termios03/init.c
+++ b/testsuites/libtests/termios03/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <tmacros.h>
#include "test_support.h"
#include "termios_testdriver_polled.h"
diff --git a/testsuites/libtests/termios04/init.c b/testsuites/libtests/termios04/init.c
index dd9f653a7b..ed76962dad 100644
--- a/testsuites/libtests/termios04/init.c
+++ b/testsuites/libtests/termios04/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <tmacros.h>
#include "test_support.h"
#include "termios_testdriver_intr.h"
diff --git a/testsuites/libtests/termios05/init.c b/testsuites/libtests/termios05/init.c
index 72c9e81a37..d359165ee6 100644
--- a/testsuites/libtests/termios05/init.c
+++ b/testsuites/libtests/termios05/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <tmacros.h>
#include "test_support.h"
#include "termios_testdriver_intr.h"
diff --git a/testsuites/libtests/termios06/init.c b/testsuites/libtests/termios06/init.c
index 9b59ad2fb9..5c39dabacf 100644
--- a/testsuites/libtests/termios06/init.c
+++ b/testsuites/libtests/termios06/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <tmacros.h>
#include "test_support.h"
#include "termios_testdriver_polled.h"
diff --git a/testsuites/libtests/termios07/init.c b/testsuites/libtests/termios07/init.c
index bda570d706..d6a91ef8db 100644
--- a/testsuites/libtests/termios07/init.c
+++ b/testsuites/libtests/termios07/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <tmacros.h>
#include "test_support.h"
#include "termios_testdriver_intr.h"
diff --git a/testsuites/libtests/termios08/init.c b/testsuites/libtests/termios08/init.c
index 317ce7203d..7c290981da 100644
--- a/testsuites/libtests/termios08/init.c
+++ b/testsuites/libtests/termios08/init.c
@@ -11,6 +11,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <tmacros.h>
#include "test_support.h"
#include "termios_testdriver_polled.h"
diff --git a/testsuites/libtests/termios09/init.c b/testsuites/libtests/termios09/init.c
index 6feb521244..46b4c76181 100644
--- a/testsuites/libtests/termios09/init.c
+++ b/testsuites/libtests/termios09/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <sys/stat.h>
#include <fcntl.h>
#include <string.h>
diff --git a/testsuites/libtests/top/init.c b/testsuites/libtests/top/init.c
index 8a824ae194..ed33d8288a 100644
--- a/testsuites/libtests/top/init.c
+++ b/testsuites/libtests/top/init.c
@@ -21,6 +21,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#define CONFIGURE_INIT
#include "system.h"
diff --git a/testsuites/libtests/tztest/init.c b/testsuites/libtests/tztest/init.c
index 88799f5849..263bd8e25b 100644
--- a/testsuites/libtests/tztest/init.c
+++ b/testsuites/libtests/tztest/init.c
@@ -20,6 +20,8 @@
#define CONFIGURE_INIT
+#define TEST_INIT
+
#include <tmacros.h>
#include <time.h>
#include <stdlib.h>
diff --git a/testsuites/libtests/uid01/init.c b/testsuites/libtests/uid01/init.c
index 2e6fd635ed..56eba61a94 100644
--- a/testsuites/libtests/uid01/init.c
+++ b/testsuites/libtests/uid01/init.c
@@ -10,6 +10,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include <bsp.h>
#include <stdlib.h>
diff --git a/testsuites/libtests/utf8proc01/init.c b/testsuites/libtests/utf8proc01/init.c
index fda1444a37..142af2b748 100644
--- a/testsuites/libtests/utf8proc01/init.c
+++ b/testsuites/libtests/utf8proc01/init.c
@@ -16,6 +16,8 @@
#include "config.h"
#endif
+#define TEST_INIT
+
#include "tmacros.h"
#include <string.h>