Module Name: src
Committed By: jruoho
Date: Thu Jul 8 22:46:34 UTC 2010
Modified Files:
src/lib/libpthread: pthread_mutexattr.3
Log Message:
.Xr instaed of .Fn for pthread_mutex_init(3), update the error codes,
cleanup STANDARDS, etc.
To generate a diff of this commit:
cvs rdiff -u -r1.10 -r1.11 src/lib/libpthread/pthread_mutexattr.3
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/lib/libpthread/pthread_mutexattr.3
diff -u src/lib/libpthread/pthread_mutexattr.3:1.10 src/lib/libpthread/pthread_mutexattr.3:1.11
--- src/lib/libpthread/pthread_mutexattr.3:1.10 Thu May 20 05:19:29 2010
+++ src/lib/libpthread/pthread_mutexattr.3 Thu Jul 8 22:46:34 2010
@@ -1,6 +1,6 @@
-.\" $NetBSD: pthread_mutexattr.3,v 1.10 2010/05/20 05:19:29 jruoho Exp $
+.\" $NetBSD: pthread_mutexattr.3,v 1.11 2010/07/08 22:46:34 jruoho Exp $
.\"
-.\" Copyright (c) 2002 The NetBSD Foundation, Inc.
+.\" Copyright (c) 2002, 2010 The NetBSD Foundation, Inc.
.\" All rights reserved.
.\" Redistribution and use in source and binary forms, with or without
.\" modification, are permitted provided that the following conditions
@@ -50,7 +50,7 @@
.\" EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
.\"
.\" $FreeBSD: src/lib/libpthread/man/pthread_mutexattr.3,v 1.8 2002/09/16 19:29:29 mini Exp $
-.Dd May 20, 2010
+.Dd July 9, 2010
.Dt PTHREAD_MUTEXATTR 3
.Os
.Sh NAME
@@ -72,22 +72,28 @@
.Ft int
.Fn pthread_mutexattr_destroy "pthread_mutexattr_t *attr"
.\" .Ft int
-.\" .Fn pthread_mutexattr_setprioceiling "pthread_mutexattr_t *attr" "int prioceiling"
+.\" .Fn pthread_mutexattr_setprioceiling \
+.\" "pthread_mutexattr_t *attr" "int prioceiling"
.\" .Ft int
-.\" .Fn pthread_mutexattr_getprioceiling "pthread_mutexattr_t *attr" "int *prioceiling"
+.\" .Fn pthread_mutexattr_getprioceiling \
+.\" "pthread_mutexattr_t *attr" "int *prioceiling"
.\" .Ft int
-.\" .Fn pthread_mutexattr_setprotocol "pthread_mutexattr_t *attr" "int protocol"
+.\" .Fn pthread_mutexattr_setprotocol \
+.\" "pthread_mutexattr_t *attr" "int protocol"
.\" .Ft int
-.\" .Fn pthread_mutexattr_getprotocol "pthread_mutexattr_t *attr" "int *protocol"
+.\" .Fn pthread_mutexattr_getprotocol \
+.\" "pthread_mutexattr_t *attr" "int *protocol"
.Ft int
.Fn pthread_mutexattr_settype "pthread_mutexattr_t *attr" "int type"
.Ft int
-.Fn pthread_mutexattr_gettype "pthread_mutexattr_t * restrict attr" "int * restrict type"
+.Fn pthread_mutexattr_gettype \
+"pthread_mutexattr_t * restrict attr" "int * restrict type"
.Sh DESCRIPTION
Mutex attributes are used to specify parameters to
.Fn pthread_mutex_init .
-One attribute object can be used in multiple calls to
-.Fn pthread_mutex_init ,
+Like with thread attributes,
+one attribute object can be used in multiple calls to
+.Xr pthread_mutex_init 3 ,
with or without modifications between calls.
.Pp
The
@@ -170,21 +176,32 @@
If successful, these functions return 0.
Otherwise, an error number is returned to indicate the error.
.Sh ERRORS
+The
.Fn pthread_mutexattr_init
-shall fail if:
+function shall fail if:
.Bl -tag -width Er
.It Bq Er ENOMEM
Insufficient memory exists to initialize the mutex attributes object.
.El
.Pp
+The
.Fn pthread_mutexattr_settype
-shall fail if:
+function shall fail if:
.Bl -tag -width Er
.It Bq Er EINVAL
-The value specified by
+The value specified either by
.Fa type
+or
+.Fa attr
is invalid.
.El
+.Pp
+No error numbers are defined for the
+.Fn pthread_mutexattr_destroy
+and
+.Fn pthread_mutexattr_gettype
+functions.
+.\"
.\" .Pp
.\" .Fn pthread_mutexattr_setprioceiling
.\" may fail if:
@@ -222,28 +239,8 @@
.\" .Fa attr .
.\" .El
.\" .Pp
-.Pp
-.Fn pthread_mutexattr_destroy ,
-.Fn pthread_mutexattr_settype ,
-and
-.Fn pthread_mutexattr_gettype
-may fail if:
-.Bl -tag -width Er
-.It Bq Er EINVAL
-Invalid value for
-.Fa attr .
-.El
.Sh SEE ALSO
.Xr pthread_mutex_init 3
.Sh STANDARDS
-.Fn pthread_mutexattr_init ,
-.Fn pthread_mutexattr_destroy ,
-.Fn pthread_mutexattr_settype ,
-.\" .Fn pthread_mutexattr_setprioceiling ,
-.\" .Fn pthread_mutexattr_getprioceiling ,
-.\" .Fn pthread_mutexattr_setprotocol ,
-.\" .Fn pthread_mutexattr_getprotocol ,
-and
-.Fn pthread_mutexattr_gettype
-conform to
-.St -p1003.1-96 .
+These functions conform to
+.St -p1003.1-2001 .