summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/kern/kern_exit.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/sys/kern/kern_exit.c b/sys/kern/kern_exit.c
index 08cbb28e280c..81cbdb99b06e 100644
--- a/sys/kern/kern_exit.c
+++ b/sys/kern/kern_exit.c
@@ -118,7 +118,6 @@ exit1(p, rv)
register struct proc *q, *nq;
register struct vmspace *vm;
struct exitlist *ep;
- struct timeval new_switchtime;
if (p->p_pid == 1) {
printf("init died (signal %d, exit %d)\n",
@@ -327,10 +326,9 @@ exit1(p, rv)
* counted somewhere if possible.
*/
mtx_lock_spin(&sched_lock);
- microuptime(&new_switchtime);
- PCPU_SET(switchtime, new_switchtime);
- mtx_unlock_spin(&sched_lock);
+ microuptime(PCPU_PTR(switchtime));
PCPU_SET(switchticks, ticks);
+ mtx_unlock_spin(&sched_lock);
/*
* notify interested parties of our demise.