diff options
author | 2013-12-28 03:12:56 +0000 | |
---|---|---|
committer | 2013-12-28 03:12:56 +0000 | |
commit | accc9fe1cf3a1377b4b6d17c3f8c3b85fc4a735e (patch) | |
tree | e3c44299e4fbbf5b9b1166b40425a164c5638fc1 | |
parent | We can random_start() earlier (not that it does too much) and call (diff) | |
download | wireguard-openbsd-accc9fe1cf3a1377b4b6d17c3f8c3b85fc4a735e.tar.xz wireguard-openbsd-accc9fe1cf3a1377b4b6d17c3f8c3b85fc4a735e.zip |
We can initialize the srandom/random system earlier from arc4random,
and do not need microtime.
-rw-r--r-- | sys/kern/init_main.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/sys/kern/init_main.c b/sys/kern/init_main.c index eb6415b145f..c26b9d4acef 100644 --- a/sys/kern/init_main.c +++ b/sys/kern/init_main.c @@ -1,4 +1,4 @@ -/* $OpenBSD: init_main.c,v 1.193 2013/12/28 03:04:20 deraadt Exp $ */ +/* $OpenBSD: init_main.c,v 1.194 2013/12/28 03:12:56 deraadt Exp $ */ /* $NetBSD: init_main.c,v 1.84.4.1 1996/06/02 09:08:06 mrg Exp $ */ /* @@ -192,7 +192,6 @@ main(void *framep) struct proc *p; struct process *pr; struct pdevinit *pdev; - struct timeval rtv; quad_t lim; int s, i; extern struct pdevinit pdevinit[]; @@ -347,8 +346,6 @@ main(void *framep) workq_init(); taskq_init(); - random_start(); - /* Initialize the interface/address trees */ ifinit(); @@ -535,9 +532,6 @@ main(void *framep) if (kthread_create(uvm_aiodone_daemon, NULL, NULL, "aiodoned")) panic("fork aiodoned"); - microtime(&rtv); - srandom((u_int32_t)(rtv.tv_sec ^ rtv.tv_usec) ^ arc4random()); - #if defined(MULTIPROCESSOR) /* Boot the secondary processors. */ cpu_boot_secondary_processors(); |