summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sys/kern/init_main.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/kern/init_main.c b/sys/kern/init_main.c
index 54d78e6..c0eac133 100644
--- a/sys/kern/init_main.c
+++ b/sys/kern/init_main.c
@@ -509,7 +509,9 @@ proc0_post(void *dummy __unused)
sx_slock(&allproc_lock);
FOREACH_PROC_IN_SYSTEM(p) {
microuptime(&p->p_stats->p_start);
+ PROC_SLOCK(p);
rufetch(p, &ru); /* Clears thread stats */
+ PROC_SUNLOCK(p);
p->p_rux.rux_runtime = 0;
p->p_rux.rux_uticks = 0;
p->p_rux.rux_sticks = 0;
OpenPOWER on IntegriCloud