mirror_zfs/lib/libspl/include/sys
Rob Norris 23d17f3587 libspl/random: add switch to force pseudo-random numbers for all calls
ztest wants to force all kernel random calls to use the pseudo-random
generator (/dev/urandom), to avoid depleting the system entropy pool
just for testing.

Up until the previous commit, it did this by switching the path that the
libzpool (now libspl) random API would use to get random data from; that
is, it took advantage of an implementation detail.

Now that that hole is closed to it, we need another method. This commit
introduces that; a simple API call to enable/disable "force pseudo"
mode.

Sponsored-by: https://despairlabs.com/sponsor/
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Rob Norris <robn@despairlabs.com>
Closes #17861
2025-11-12 10:04:30 -08:00
..
dktp SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
acl_impl.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
acl.h zfs_context: remove duplicated access control stuff; remove kernel gate 2025-11-12 10:00:52 -08:00
asm_linkage.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
backtrace.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
callb.h libspl: move callb stubs from zfs_context.h 2025-11-12 10:01:44 -08:00
cmn_err.h libspl: move cmn_err definitions from zfs_context.h 2025-11-12 09:59:09 -08:00
condvar.h libspl: move condvar definitions from zfs_context.h 2025-11-12 09:58:59 -08:00
cred.h libspl: move cred definitions from zfs_context.h 2025-11-12 09:59:51 -08:00
debug.h zfs_context: move empty __init/__exit macros to sys/debug.h 2025-11-12 10:02:42 -08:00
dkio.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
dklabel.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
feature_tests.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
inttypes.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
isa_defs.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
kmem.h libspl: move kmem definitions from zfs_context.h 2025-11-12 10:00:17 -08:00
kstat.h libspl: move kstat definitions from zfs_context.h, slim down to basics 2025-11-12 10:00:03 -08:00
list_impl.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
list.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
mhd.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
misc.h libspl: hide global data objects 2025-11-12 10:04:22 -08:00
mkdev.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
mod.h libspl: implement ZFS_MODULE_PARAM for userspace 2025-07-15 15:46:51 -07:00
mutex.h libspl: move mutex headers from zfs_context.h 2025-11-12 09:58:37 -08:00
policy.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
poll.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
priv.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
processor.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
procfs_list.h libspl: move procfs_list definitions from zfs_context.h 2025-11-12 10:00:10 -08:00
random.h libspl/random: add switch to force pseudo-random numbers for all calls 2025-11-12 10:04:30 -08:00
rwlock.h libspl: move rwlock definitions from zfs_context.h 2025-11-12 09:58:50 -08:00
sid.h libspl: move SID definitions from zfs_context.h; remove kernel gate 2025-11-12 10:01:48 -08:00
simd.h Backport AVX2 AES-GCM implementation from BoringSSL 2025-08-13 14:51:20 -07:00
stack.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
stdtypes.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
string.h libspl: add include guards for sys/string.h 2025-11-12 10:00:41 -08:00
sunddi.h libspl: move remaining ddi_* prototypes from zfs_context.h 2025-11-12 10:02:12 -08:00
sysmacros.h libspl: common sysmacros.h 2025-11-12 10:02:25 -08:00
systeminfo.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
systm.h libspl: hide global data objects 2025-11-12 10:04:22 -08:00
taskq.h libspl: hide global data objects 2025-11-12 10:04:22 -08:00
thread.h libspl: hide global data objects 2025-11-12 10:04:22 -08:00
time.h Detect a slow raidz child during reads 2025-09-10 15:25:03 -07:00
timer.h libspl: move time definitions from zfs_context_os.h 2025-11-12 09:58:31 -08:00
trace.h libspl: move DTRACE_PROBE macros from zfs_context.h 2025-11-12 10:02:20 -08:00
tsd.h libspl: move tsd definitions from zfs_context.h 2025-11-12 09:59:59 -08:00
tunables.h libspl: hide zfs_tunable_* symbols 2025-11-12 09:38:54 -08:00
types32.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
types.h libspl: move loff_t declaration from zfs_context.h 2025-11-12 10:02:46 -08:00
uio.h Add missing include statement 2025-10-07 09:21:03 -07:00
vnode.h libspl: move vattr and xvattr definitions from zfs_context.h 2025-11-12 10:00:24 -08:00
wmsum.h SPDX: license tags: CDDL-1.0 2025-03-13 17:56:27 -07:00
zone.h libspl: move zone definitions from zfs_context.h 2025-11-12 10:02:00 -08:00