2 * Copyright 2015, Michael Ellerman, IBM Corp.
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License
6 * as published by the Free Software Foundation; either version
7 * 2 of the License, or (at your option) any later version.
9 * This test simply tests that certain syscalls are implemented. It doesn't
10 * actually exercise their logic in any way.
17 #include <sys/syscall.h>
22 #define DO_TEST(_name, _num) \
23 static int test_##_name(void) \
26 printf("Testing " #_name); \
28 rc = syscall(_num, -1, 0, 0, 0, 0, 0); \
29 printf("\treturned %d, errno %d\n", rc, errno); \
30 return errno == ENOSYS; \
36 static int ipc_unmuxed(void)
40 #define DO_TEST(_name, _num) \
41 FAIL_IF(test_##_name()); \
48 * If we ran no tests then it means none of the syscall numbers were
49 * defined, possibly because we were built against old headers. But it
50 * means we didn't really test anything, so instead of passing mark it
51 * as a skip to give the user a clue.
53 SKIP_IF(tests_done
== 0);
60 return test_harness(ipc_unmuxed
, "ipc_unmuxed");