freebsd-nq/sys
Colin Percival 0811ce5723 random: Ingest extra fast entropy when !seeded
We periodically ingest entropy from pollable entropy sources, but only
8 bytes at a time and only occasionally enough to feed all of Fortuna's
pools once per second.  This can result in Fortuna remaining unseeded
for a nontrivial amount of time when there is no entropy passed in from
the boot loader, even if RDRAND is available to quickly provide a large
amount of entropy.

Detect in random_sources_feed if we are not yet seeded, and increase the
amount of immediate entropy harvesting we perform, in order to "fill"
Fortuna's entropy pools and avoid having
  random: randomdev_wait_until_seeded unblock wait
stall the boot process when entropy is available.

This speeds up the FreeBSD boot in the Firecracker VM by 2.3 seconds.

Approved by:	csprng (delphij)
Sponsored by:	https://www.patreon.com/cperciva
Differential Revision:	https://reviews.freebsd.org/D35802
2022-07-19 23:59:40 -07:00
..
amd64 ddb: annotate some commands with DB_CMD_MEMSAFE 2022-07-18 22:06:09 +00:00
arm Rework how shared page related data is stored 2022-07-18 16:27:32 +02:00
arm64 Add experimental 16k page support on arm64 2022-07-19 10:57:03 +01:00
bsm
cam Delay GEOM disk_create() until CAM periph probe completes. 2022-07-14 16:17:36 -04:00
cddl Adjust dtrace_unload() definition to avoid clang 15 warning 2022-07-19 20:48:47 +02:00
compat Implement shared page address randomization 2022-07-18 16:27:37 +02:00
conf mac: add new mac_ddb(4) policy 2022-07-18 22:06:15 +00:00
contrib zfs: fixup build on powerpc64le 2022-07-08 18:52:14 -03:00
crypto OpenSSL: Regen assembly file for OpenSSSL 1.1.1q 2022-07-05 12:06:50 -04:00
ddb Adjust db_flush_line() definition to avoid clang 15 warning 2022-07-19 20:37:15 +02:00
dev random: Ingest extra fast entropy when !seeded 2022-07-19 23:59:40 -07:00
dts sys/dts: Remove MIPS files 2022-05-20 17:11:27 +01:00
fs Adjust dtnfsclient_unload() definition to avoid clang 15 warning 2022-07-19 20:41:24 +02:00
gdb ddb: use _FLAGS command macros where appropriate 2022-07-05 11:56:55 -03:00
geom Clarify when GEOM utilities exit with success or failure. 2022-07-16 10:26:51 -07:00
gnu bwn: eliminate dead writes in BWN_GPL_PHY 2022-05-04 09:32:59 -04:00
i386 ddb: annotate some commands with DB_CMD_MEMSAFE 2022-07-18 22:06:09 +00:00
isa isa: Remove unused devclass arguments to DRIVER_MODULE. 2022-05-06 15:46:59 -07:00
kern Add kern.reboot_wait_time sysctl 2022-07-18 17:23:25 -07:00
kgssapi
libkern libkern: Fix a typo in a source code comment 2022-06-05 08:57:26 +02:00
modules mac: add new mac_ddb(4) policy 2022-07-18 22:06:15 +00:00
net ddb: annotate some commands with DB_CMD_MEMSAFE 2022-07-18 22:06:09 +00:00
net80211 net80211 / LinuxKPI: 802.11: add Control Trigger Subframe information 2022-06-17 22:55:13 +00:00
netgraph ng_ubt(4): Probe USB Bluetooth per USB interface and not per USB device. 2022-06-03 10:49:17 +02:00
netinet tcp rack: fix switching to RACK when FIN has been sent 2022-07-19 20:28:25 +02:00
netinet6 netinet6: fix interface handling for loopback traffic 2022-07-10 12:47:47 +00:00
netipsec ipsec: replace SECASVAR mtx by rmlock 2022-07-19 05:27:20 +02:00
netpfil dummynet: check for ifp on all PROTO_LAYER2 packets 2022-07-11 22:07:11 +02:00
netsmb
nfs nfs: skip bootpc when vfs.root.mountfrom is other than nfs 2022-05-31 16:07:27 -03:00
nfsclient
nfsserver
nlm
ofed ofed/infiniband: fix ifdefs for new INET changes, fixing LINT-NOIP 2022-07-18 08:02:01 -05:00
opencrypto ddb: annotate some commands with DB_CMD_MEMSAFE 2022-07-18 22:06:09 +00:00
powerpc Rework how shared page related data is stored 2022-07-18 16:27:32 +02:00
riscv Rework how shared page related data is stored 2022-07-18 16:27:32 +02:00
rpc krpc: Fix NFS-over-TLS for KTLS1.3 2022-05-15 11:51:56 -07:00
security mac_ddb: add some validation functions 2022-07-18 22:06:22 +00:00
sys Implement shared page address randomization 2022-07-18 16:27:37 +02:00
teken
tests
tools firmware: Map '@' in filenames to '_' in symbols. 2022-06-14 10:50:51 -07:00
ufs Additional check for UFS/FFS superblock integrity checks. 2022-07-16 10:31:52 -07:00
vm swap_pager: Reduce the scope of the object lock in putpages 2022-07-18 22:35:49 -05:00
x86 x86/iommu: Shrink the critical section in dmar_qi_task() 2022-07-18 22:23:13 -05:00
xdr
xen xenbus: improve device tracking 2022-06-07 12:29:53 +02:00
Makefile