mutex.9 (217074) | mutex.9 (227588) |
---|---|
1.\" 2.\" Copyright (c) 1998 Berkeley Software Design, Inc. All rights reserved. 3.\" 4.\" Redistribution and use in source and binary forms, with or without 5.\" modification, are permitted provided that the following conditions 6.\" are met: 7.\" 1. Redistributions of source code must retain the above copyright 8.\" notice, this list of conditions and the following disclaimer. --- 12 unchanged lines hidden (view full) --- 21.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 22.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 23.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 24.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 25.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 26.\" SUCH DAMAGE. 27.\" 28.\" from BSDI $Id: mutex.4,v 1.1.2.3 1998/04/27 22:53:13 ewv Exp $ | 1.\" 2.\" Copyright (c) 1998 Berkeley Software Design, Inc. All rights reserved. 3.\" 4.\" Redistribution and use in source and binary forms, with or without 5.\" modification, are permitted provided that the following conditions 6.\" are met: 7.\" 1. Redistributions of source code must retain the above copyright 8.\" notice, this list of conditions and the following disclaimer. --- 12 unchanged lines hidden (view full) --- 21.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 22.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 23.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 24.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 25.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 26.\" SUCH DAMAGE. 27.\" 28.\" from BSDI $Id: mutex.4,v 1.1.2.3 1998/04/27 22:53:13 ewv Exp $ |
29.\" $FreeBSD: head/share/man/man9/mutex.9 217074 2011-01-06 21:14:34Z jhb $ | 29.\" $FreeBSD: head/share/man/man9/mutex.9 227588 2011-11-16 21:51:17Z pjd $ |
30.\" | 30.\" |
31.Dd December 21, 2006 | 31.Dd November 16, 2011 |
32.Dt MUTEX 9 33.Os 34.Sh NAME 35.Nm mutex , 36.Nm mtx_init , 37.Nm mtx_destroy , 38.Nm mtx_lock , 39.Nm mtx_lock_spin , --- 38 unchanged lines hidden (view full) --- 78.Fn mtx_unlock_spin "struct mtx *mutex" 79.Ft void 80.Fn mtx_unlock_flags "struct mtx *mutex" "int flags" 81.Ft void 82.Fn mtx_unlock_spin_flags "struct mtx *mutex" "int flags" 83.Ft int 84.Fn mtx_sleep "void *chan" "struct mtx *mtx" "int priority" "const char *wmesg" "int timo" 85.Ft int | 32.Dt MUTEX 9 33.Os 34.Sh NAME 35.Nm mutex , 36.Nm mtx_init , 37.Nm mtx_destroy , 38.Nm mtx_lock , 39.Nm mtx_lock_spin , --- 38 unchanged lines hidden (view full) --- 78.Fn mtx_unlock_spin "struct mtx *mutex" 79.Ft void 80.Fn mtx_unlock_flags "struct mtx *mutex" "int flags" 81.Ft void 82.Fn mtx_unlock_spin_flags "struct mtx *mutex" "int flags" 83.Ft int 84.Fn mtx_sleep "void *chan" "struct mtx *mtx" "int priority" "const char *wmesg" "int timo" 85.Ft int |
86.Fn mtx_initialized "struct mtx *mutex" | 86.Fn mtx_initialized "const struct mtx *mutex" |
87.Ft int | 87.Ft int |
88.Fn mtx_owned "struct mtx *mutex" | 88.Fn mtx_owned "const struct mtx *mutex" |
89.Ft int | 89.Ft int |
90.Fn mtx_recursed "struct mtx *mutex" | 90.Fn mtx_recursed "const struct mtx *mutex" |
91.Pp 92.Cd "options INVARIANTS" 93.Cd "options INVARIANT_SUPPORT" 94.Ft void | 91.Pp 92.Cd "options INVARIANTS" 93.Cd "options INVARIANT_SUPPORT" 94.Ft void |
95.Fn mtx_assert "struct mtx *mutex" "int what" | 95.Fn mtx_assert "const struct mtx *mutex" "int what" |
96.In sys/kernel.h 97.Fn MTX_SYSINIT "name" "struct mtx *mtx" "const char *description" "int opts" 98.Sh DESCRIPTION 99Mutexes are the most basic and primary method of thread synchronization. 100The major design considerations for mutexes are: 101.Bl -enum 102.It 103Acquiring and releasing uncontested mutexes should be as cheap --- 420 unchanged lines hidden --- | 96.In sys/kernel.h 97.Fn MTX_SYSINIT "name" "struct mtx *mtx" "const char *description" "int opts" 98.Sh DESCRIPTION 99Mutexes are the most basic and primary method of thread synchronization. 100The major design considerations for mutexes are: 101.Bl -enum 102.It 103Acquiring and releasing uncontested mutexes should be as cheap --- 420 unchanged lines hidden --- |