History log of /external/ltp/testcases/kernel/syscalls/getrandom/getrandom02.c
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
817d8095fbfe5ebe22b29f58b7483f3d8d5e3fcc 24-Jul-2017 Richard Palethorpe <rpalethorpe@suse.com> Rename linux_syscall_numbers.h to lapi/syscalls.h

Move testcases/kernel/include/linux_syscall_numbers.h to lapi/syscalls.h so
that it is easily accessible from the LTP library as well as the tests.

Signed-off-by: Richard Palethorpe <rpalethorpe@suse.com>
Acked-by: Cyril Hrubis <chrubis@suse.cz>
Acked-by: Jan Stancek <jstancek@redhat.com>
/external/ltp/testcases/kernel/syscalls/getrandom/getrandom02.c
a5bf5254ca94e0164af76d409224ea0764632d22 14-Mar-2017 Cyril Hrubis <chrubis@suse.cz> tst_test.c: set the test id automatically

Use the argv[0] to set the tst_test->tid automatically since we fail to
update it commonly and we end up with wrong tid due to copy&paste.

Now it's initialized in the test setup based on argv[0]. If argv[0] is a
path we take last element in it.

This patch is based on v1 by Li Wang but I've omitted moving the
parse_opts() up in the setup() since the setup() function expects
that tst_test sturcture is non-NULL and may segfault if that is not
true.

Signed-off-by: Li Wang <liwang@redhat.com>
Signed-off-by: Cyril Hrubis <chrubis@suse.cz>
Acked-by: Petr Vorel <pvorel@suse.cz>
/external/ltp/testcases/kernel/syscalls/getrandom/getrandom02.c
e0c1daf59ed138851dc91e4852b8c92d4c59af13 08-Feb-2017 Cyril Hrubis <chrubis@suse.cz> getrandom02: Convert to the new library.

Signed-off-by: Cyril Hrubis <chrubis@suse.cz>
/external/ltp/testcases/kernel/syscalls/getrandom/getrandom02.c
b94f958c4632aa2a9329e6c40607b8161142f0c9 08-Feb-2017 Jan Stancek <jstancek@redhat.com> getrandom02: relax check for returned data

"nb * 0.1" can easily fail for nb < 20, since all we need
are 2 identical bytes. Worst case (nb == 19) is almost
identical to "birthday problem", but with smaller pool.
Chance of hitting 2 identical bytes in pool of 19
is close to 50%.

Adjust formula to allow small repetitions in small pools.
Chance we fail now should be pretty unlikely, ~10^-16.

Signed-off-by: Jan Stancek <jstancek@redhat.com>
Acked-by: Cyril Hrubis <chrubis@suse.cz>
/external/ltp/testcases/kernel/syscalls/getrandom/getrandom02.c
17dce71b18834fc41275eb79b940a33046642947 13-Jul-2015 Jan Stancek <jstancek@redhat.com> syscalls/getrandom: add configure check for linux/random.h

Old distros (such as RHEL5.6) break, when they try to include
some kernel headers directly. Add configure check to make sure
linux/random.h kernel header can be compiled without errors.

Signed-off-by: Xiaoguang Wang <wangxg.fnst@cn.fujitsu.com>
Signed-off-by: Jan Stancek <jstancek@redhat.com>
Acked-by: Cyril Hrubis <chrubis@suse.cz>
/external/ltp/testcases/kernel/syscalls/getrandom/getrandom02.c
cc634814d1881137a19287eeaa0cf6fd15ecf4da 25-Jun-2015 Jan Stancek <jstancek@redhat.com> getrandom: fix compilation with older kernels

Add lapi/getrandom.h as fallback for GRND_* defines
Add getrandom to syscalls number list for common architectures
Replace syscall with ltp_syscall

Signed-off-by: Jan Stancek <jstancek@redhat.com>
Acked-by: Cyril Hrubis <chrubis@suse.cz>
/external/ltp/testcases/kernel/syscalls/getrandom/getrandom02.c
7f72a2c4fbfa4b4dd1c5e71f523eb4325297f97c 18-Jun-2015 Cédric Hnyda <ced.hnyda@gmail.com> syscall/getrandom: Add tests for getrandom

Signed-off-by: Cedric Hnyda <ced.hnyda@gmail.com>
/external/ltp/testcases/kernel/syscalls/getrandom/getrandom02.c