summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordavidxu <davidxu@FreeBSD.org>2003-07-08 00:14:30 +0000
committerdavidxu <davidxu@FreeBSD.org>2003-07-08 00:14:30 +0000
commit79e1d9ec1ea281222db902b05f1dd7c7c04f0bfc (patch)
treeacbf78d52c23a6706f8e33a88d19e2150afce7a2
parent748dd1c088b22b6a427aa54cbff144ba0d766cd4 (diff)
downloadFreeBSD-src-79e1d9ec1ea281222db902b05f1dd7c7c04f0bfc.zip
FreeBSD-src-79e1d9ec1ea281222db902b05f1dd7c7c04f0bfc.tar.gz
Fix LOR between scheduler lock and SMP rendezvous lock.
Reviewed by: jhb
-rw-r--r--sys/i386/i386/sys_machdep.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/sys/i386/i386/sys_machdep.c b/sys/i386/i386/sys_machdep.c
index 2e4cd26..04fe24f 100644
--- a/sys/i386/i386/sys_machdep.c
+++ b/sys/i386/i386/sys_machdep.c
@@ -289,9 +289,7 @@ set_user_ldt_rv(struct thread *td)
if (td->td_proc != curthread->td_proc)
return;
- mtx_lock_spin(&sched_lock);
set_user_ldt(&td->td_proc->p_md);
- mtx_unlock_spin(&sched_lock);
}
#endif
@@ -462,9 +460,6 @@ i386_set_ldt(td, args)
#endif
} else {
mdp->md_ldt = pldt = new_ldt;
-#ifdef SMP
- mtx_unlock_spin(&sched_lock);
-#endif
}
#ifdef SMP
/* signal other cpus to reload ldt */
@@ -472,8 +467,8 @@ i386_set_ldt(td, args)
NULL, td);
#else
set_user_ldt(mdp);
- mtx_unlock_spin(&sched_lock);
#endif
+ mtx_unlock_spin(&sched_lock);
}
descs_size = uap->num * sizeof(union descriptor);
OpenPOWER on IntegriCloud