Branch is up on Github including two revisions not posted on phabricator: one to enable the option by default in amd64 GENERIC, and one to add some printf XXX style logging which would not be included in a "real" version of this algorithm but is useful to verify it is working as designed. (It could be left in as CTR or dtrace or something hooks, just not raw printf.)
https://github.com/cemeyer/freebsd/tree/201912_random4_fxrng
Design whitepaper: https://aka.ms/win10rng
See also more discussion of design in `fx_main.c`.
Some logging (with the entire patch stack, although I tested each piece individually while working on the stack):
```
Dec 16 11:14:41 testvm kernel: ---<<BOOT>>---
Dec 16 11:14:41 testvm kernel: Copyright (c) 1992-2019 The FreeBSD Project.
...
Dec 16 11:14:41 testvm kernel: subsystem ffffff
Dec 16 11:14:41 testvm kernel: parse_acpi_tables(0)... done.
...
Dec 16 11:14:41 testvm kernel: subsystem 2160000
Dec 16 11:14:41 testvm kernel: random_init(0)... done.
Dec 16 11:14:41 testvm kernel: random_harvestq_init(0)... done.
Dec 16 11:14:41 testvm kernel: random_alg_context_ra_init_alg(0)... done.
Dec 16 11:14:41 testvm kernel: module_register_init(&rdrand_mod)... random: registering fast source Intel Secure Key RNG
Dec 16 11:14:41 testvm kernel: random: fast provider: "Intel Secure Key RNG"
Dec 16 11:14:41 testvm kernel: done.
Dec 16 11:14:41 testvm kernel: module_register_init(&nehemiah_mod)... done.
Dec 16 11:14:41 testvm kernel: random_harvestq_prime(0)... XXXfxrng_event_processor: source 0 'first' time
Dec 16 11:14:41 testvm kernel: done.
Dec 16 11:14:41 testvm kernel: __stack_chk_init(0)... XXXfxrng_alg_seeded: seeded with 4096 bytes of high-quality entropy.
Dec 16 11:14:41 testvm kernel: random: unblocking device.
Dec 16 11:14:41 testvm kernel: done.
...
Dec 16 11:14:41 testvm kernel: subsystem 3100000
...
Dec 16 11:14:41 testvm kernel: module_register_init(&randomdev_mod)... random: entropy device external interface
Dec 16 11:14:41 testvm kernel: done.
...
Dec 16 11:14:41 testvm kernel: XXXfxrng_event_processor: source 1 'first' time
Dec 16 11:14:41 testvm kernel: cryptosoft0: <software crypto>
...
Dec 16 11:14:41 testvm kernel: subsystem a000000
...
Dec 16 11:14:41 testvm kernel: kproc_start(&random_proc_kp)... done.
Dec 16 11:14:41 testvm kernel: XXXfxrng_event_processor: source 7 'first' time
Dec 16 11:14:41 testvm kernel: mca_startup(0)... XXXfxrng_event_processor: source 8 'first' time
Dec 16 11:14:41 testvm kernel: done.
Dec 16 11:14:41 testvm kernel: acpi_taskq_init(0)... XXXfxrng_event_processor: source 16 'first' time
Dec 16 11:14:41 testvm kernel: done.
...
Dec 16 11:14:41 testvm kernel: subsystem fffffff
...
Dec 16 11:14:41 testvm kernel: oktousecallout(0)... done.
Dec 16 11:14:41 testvm kernel: XXXfxrng_event_processor: source 9 'first' time
Dec 16 11:14:41 testvm kernel: XXXfxent_timer_reseed_npools: Bumping generation due to timer reseed
Dec 16 11:14:41 testvm kernel: XXXfxent_timer_reseed: Did 1 sec reseed, queued the next in 3 sec.
...
Dec 16 11:14:41 testvm kernel: vtrnd0: <VirtIO Entropy Adapter> on virtio_pci0
Dec 16 11:14:41 testvm kernel: random: registering fast source VirtIO Entropy Adapter
Dec 16 11:14:41 testvm kernel: XXXfxrng_event_processor: source 19 'first' time
...
Dec 16 11:14:41 testvm kernel: XXXfxent_timer_reseed_npools: Bumping generation due to timer reseed
Dec 16 11:14:41 testvm kernel: XXXfxent_timer_reseed: Did 3 sec reseed, queued the next in 9 sec.
Dec 16 11:14:50 testvm kernel: XXXfxent_timer_reseed_npools: Bumping generation due to timer reseed
Dec 16 11:14:50 testvm kernel: XXXfxent_timer_reseed: Did 9 sec reseed, queued the next in 27 sec.
Dec 16 11:15:10 testvm arc4random_test_long[558]: XXX_rs_forkdetect: reseeding due to seed version 8 != 10
Dec 16 11:15:17 testvm kernel: XXXfxent_timer_reseed_npools: Bumping generation due to timer reseed
Dec 16 11:15:17 testvm kernel: XXXfxent_timer_reseed: Did 27 sec reseed, queued the next in 81 sec.
Dec 16 11:15:40 testvm arc4random_test_long[558]: XXX_rs_forkdetect: reseeding due to seed version 10 != 11
Dec 16 11:16:38 testvm kernel: XXXfxent_timer_reseed_npools: Bumping generation due to timer reseed
Dec 16 11:16:38 testvm kernel: XXXfxent_timer_reseed: Did 81 sec reseed, queued the next in 243 sec.
Dec 16 11:16:41 testvm arc4random_test_long[558]: XXX_rs_forkdetect: reseeding due to seed version 11 != 12
Dec 16 11:20:41 testvm kernel: XXXfxent_timer_reseed_npools: Bumping generation due to timer reseed
Dec 16 11:20:41 testvm kernel: XXXfxent_timer_reseed: Did 243 sec reseed, queued the next in 729 sec.
Dec 16 11:20:41 testvm arc4random_test_long[558]: XXX_rs_forkdetect: reseeding due to seed version 12 != 13
Dec 16 11:32:50 testvm kernel: XXXfxent_timer_reseed_npools: Bumping generation due to timer reseed
Dec 16 11:32:50 testvm kernel: XXXfxent_timer_reseed: Did 729 sec reseed, queued the next in 2187 sec.
Dec 16 11:33:13 testvm arc4random_test_long[558]: XXX_rs_forkdetect: reseeding due to seed version 13 != 14
```
```