aboutsummaryrefslogtreecommitdiffstats
path: root/tools/testing/selftests/mqueue/mq_open_tests.c (follow)
AgeCommit message (Collapse)AuthorFilesLines
2018-05-30selftests: mqueue: return Kselftest Skip code for skipped testsShuah Khan (Samsung OSG)1-4/+4
When mqueue test is skipped because of unmet dependencies and/or unsupported configuration, it exits with error which is treated as a fail by the Kselftest framework. This leads to false negative result even when the test could not be run. Change it to return kselftest skip code when a test gets skipped to clearly report that the test could not be run. Change it to use ksft_exit_skip() when the test is skipped. Signed-off-by: Shuah Khan (Samsung OSG) <shuah@kernel.org>
2018-05-30selftests: mqueue: delete RUN_TESTS and EMIT_TESTS overridesShuah Khan (Samsung OSG)1-14/+15
Delete RUN_TESTS and EMIT_TESTS overrides and use common defines in lib.mk. The overrides are in place to call mq_open_tests with queue name argument. The change to delete overrides is coupled with a change to mq_open_tests to use default queue name when it is called without one. Signed-off-by: Shuah Khan (Samsung OSG) <shuah@kernel.org> Reviewed-by: Anders Roxell <anders.roxell@linaro.org> Signed-off-by: Shuah Khan (Samsung OSG) <shuah@kernel.org>
2015-11-03selftests: Add missing #include directivesBen Hutchings1-0/+1
Several C programs fail to include the headers declaring all the functions they call, resulting in warnings or errors. After this, memfd_test.c is still missing some function declarations but can't easily get them because of a conflict between <linux/fcntl.h> and <sys/fcntl.h>. Signed-off-by: Ben Hutchings <ben@decadent.org.uk> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2014-07-11tools: fix mq_open_tests compile warningsShuah Khan1-6/+14
Fix several compile warnings - these are repeats like the ones below: gcc -O2 -lrt mq_open_tests.c -o mq_open_tests mq_open_tests.c: In function ‘main’: mq_open_tests.c:295:2: warning: format ‘%d’ expects argument of type ‘int’, but argument 2 has type ‘rlim_t’ [-Wformat=] printf("\tRLIMIT_MSGQUEUE(soft):\t\t%d\n", saved_limits.rlim_cur); ^ mq_open_tests.c: In function ‘shutdown’: mq_open_tests.c:83:9: warning: ignoring return value of ‘seteuid’, declared with attribute warn_unused_result [-Wunused-result] seteuid(0); Signed-off-by: Shuah Khan <shuah.kh@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-31selftests: add mq_open_testsDoug Ledford1-0/+492
Add a directory to house POSIX message queue subsystem specific tests. Add first test which checks the operation of mq_open() under various corner conditions. Signed-off-by: Doug Ledford <dledford@redhat.com> Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> Cc: Doug Ledford <dledford@redhat.com> Cc: Joe Korty <joe.korty@ccur.com> Cc: Amerigo Wang <amwang@redhat.com> Cc: Serge E. Hallyn <serue@us.ibm.com> Cc: Jiri Slaby <jslaby@suse.cz> Cc: Manfred Spraul <manfred@colorfullife.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>