]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
libkern: Bring in arc4random_uniform(9) from libc
authorcem <cem@FreeBSD.org>
Fri, 19 Apr 2019 20:05:47 +0000 (20:05 +0000)
committercem <cem@FreeBSD.org>
Fri, 19 Apr 2019 20:05:47 +0000 (20:05 +0000)
commit316c180eb7bb4c310ff0f134913c832a43b6ec91
tree36e0f3d5153a3824cc22071cb7a14c67ae8db8c9
parentdfe617c9908c44b38e61378673675a664fbb0f09
libkern: Bring in arc4random_uniform(9) from libc

It is a useful arc4random wrapper in the kernel for much the same reasons as
in userspace.  Move the source to libkern (because kernel build is
restricted to sys/, but userspace can include any file it likes) and build
kernel and libc versions from the same source file.

Copy the documentation from arc4random_uniform(3) to the section 9 page.

While here, add missing arc4random_buf(9) symlink.

Sponsored by: Dell EMC Isilon
lib/libc/gen/Makefile.inc
share/man/man9/Makefile
share/man/man9/random.9
sys/conf/files
sys/libkern/arc4random_uniform.c [moved from lib/libc/gen/arc4random_uniform.c with 97% similarity]
sys/sys/libkern.h