diff options
author | 2014-01-19 00:22:58 +0000 | |
---|---|---|
committer | 2014-01-19 00:22:58 +0000 | |
commit | 6080d97de9231ffe2fb172c9f8ed927b45bec9f4 (patch) | |
tree | 8245918f6eb30664f4a81313cb36d6d77de66e75 | |
parent | Support a second -v on mandocdb(8) to show keys while they are being added; (diff) | |
download | wireguard-openbsd-6080d97de9231ffe2fb172c9f8ed927b45bec9f4.tar.xz wireguard-openbsd-6080d97de9231ffe2fb172c9f8ed927b45bec9f4.zip |
We can call random_start() immediately after cpu_startup, that is the
point at which everything it does is safe, including msg buffer access.
ok kettenis jsing
-rw-r--r-- | sys/kern/init_main.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/kern/init_main.c b/sys/kern/init_main.c index 185b9ba113c..809a592ddcc 100644 --- a/sys/kern/init_main.c +++ b/sys/kern/init_main.c @@ -1,4 +1,4 @@ -/* $OpenBSD: init_main.c,v 1.197 2014/01/01 07:08:10 fgsch Exp $ */ +/* $OpenBSD: init_main.c,v 1.198 2014/01/19 00:22:58 deraadt Exp $ */ /* $NetBSD: init_main.c,v 1.84.4.1 1996/06/02 09:08:06 mrg Exp $ */ /* @@ -225,6 +225,8 @@ main(void *framep) tty_init(); /* initialise tty's */ cpu_startup(); + random_start(); /* Start the flow */ + /* * Initialize mbuf's. Do this now because we might attempt to * allocate mbufs or mbuf clusters during autoconfiguration. @@ -335,8 +337,6 @@ main(void *framep) sched_init_runqueues(); sleep_queue_init(); sched_init_cpu(curcpu()); - - random_start(); srandom(arc4random()); /* Initialize work queues */ |