diff -r 19af679e3b3c sys/kern/kern_entropy.c --- a/sys/kern/kern_entropy.c Tue May 05 04:32:59 2020 +0000 +++ b/sys/kern/kern_entropy.c Wed May 06 17:48:35 2020 +0000 @@ -545,7 +545,7 @@ entropy_seed(rndsave_t *seed) if (E->stage >= ENTROPY_WARM) mutex_enter(&E->lock); seeded = E->seeded; - E->seeded = true; + E->seeded = (seed->entropy > 0); if (E->stage >= ENTROPY_WARM) mutex_exit(&E->lock); @@ -558,7 +558,8 @@ entropy_seed(rndsave_t *seed) printf("entropy: double-seeded by bootloader\n"); seed->entropy = 0; } else { - printf("entropy: entering seed from bootloader\n"); + printf("entropy: entering seed from bootloader" + " with %u bits of entropy\n", (unsigned)seed->entropy); } /* Enter it into the pool and promptly zero it. */ @@ -2163,7 +2164,7 @@ entropy_ioctl(unsigned long cmd, void *d * load a seed from disk that we have already loaded * from the bootloader, so we don't double-count it. */ - if (privileged) { + if (privileged && rdata->entropy && rdata->len) { mutex_enter(&E->lock); if (!E->seeded) { entropybits = MIN(rdata->entropy,