]> git.baikalelectronics.ru Git - kernel.git/commit
selftests/timens: Add a test for timerfd
authorAndrei Vagin <avagin@gmail.com>
Tue, 12 Nov 2019 01:27:18 +0000 (01:27 +0000)
committerThomas Gleixner <tglx@linutronix.de>
Tue, 14 Jan 2020 11:21:00 +0000 (12:21 +0100)
commitd3e9bd5fd0cfa7374006bb826e872eeb1f3fa094
tree35976b953038f40d7c7c4cb1d8e1775af7de6158
parentd7eb632dad481c91af023fc7106870626bbc88c3
selftests/timens: Add a test for timerfd

Check that timerfd_create() takes into account clock offsets.

Output on success:
 1..3
 ok 1 clockid=7
 ok 2 clockid=1
 ok 3 clockid=9
 # Pass 3 Fail 0 Xfail 0 Xpass 0 Skip 0 Error 0

Output on failure:
 1..3
 not ok 1 clockid: 7 elapsed: 0
 not ok 2 clockid: 1 elapsed: 0
 not ok 3 clockid: 9 elapsed: 0
 Bail out!

Output with lack of permissions:
 1..3
 not ok 1 # SKIP need to run as root

Output without support of time namespaces:
 1..3
 not ok 1 # SKIP Time namespaces are not supported

Co-developed-by: Dmitry Safonov <dima@arista.com>
Signed-off-by: Andrei Vagin <avagin@gmail.com>
Signed-off-by: Dmitry Safonov <dima@arista.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Link: https://lore.kernel.org/r/20191112012724.250792-30-dima@arista.com
tools/testing/selftests/timens/.gitignore
tools/testing/selftests/timens/Makefile
tools/testing/selftests/timens/timerfd.c [new file with mode: 0644]