aboutsummaryrefslogtreecommitdiff
path: root/share
diff options
context:
space:
mode:
authorChad David <davidc@FreeBSD.org>2002-06-10 17:36:05 +0000
committerChad David <davidc@FreeBSD.org>2002-06-10 17:36:05 +0000
commit02aadf0b50ecda253f8b51ca325401f4ee71c810 (patch)
treeecdc121325fb6950b46b45437f903fb841a6c913 /share
parentd99146a1f37b63fd435b5f1016731f5a13026c3b (diff)
downloadsrc-02aadf0b50ecda253f8b51ca325401f4ee71c810.tar.gz
src-02aadf0b50ecda253f8b51ca325401f4ee71c810.zip
Fix up the wording thoughout, and document locking.
Notes
Notes: svn path=/head/; revision=98098
Diffstat (limited to 'share')
-rw-r--r--share/man/man9/uidinfo.941
1 files changed, 25 insertions, 16 deletions
diff --git a/share/man/man9/uidinfo.9 b/share/man/man9/uidinfo.9
index 3932d5fc1e15..83afa2893b25 100644
--- a/share/man/man9/uidinfo.9
+++ b/share/man/man9/uidinfo.9
@@ -55,44 +55,53 @@ family of functions
is used to manage
.Vt uidinfo
structures.
-The
+Each
.Vt uidinfo
-structure maintains the process count and socket buffer space usage
-for a given UID.
+structure maintains per uid resource consumption counts, including the
+process count and socket buffer space usage.
.Pp
The
.Fn uihashinit
function initializes the
.Vt uidinfo
-hash table.
+hash table and its mutex.
This function should only be called during system initialization.
.Pp
The
.Fn uifind
function looks up and returns the
.Vt uidinfo
-structure for the
+structure for
.Fa uid .
-If the
+If the no
.Vt uidinfo
-is not found, a new structure is allocated.
+structure exists for
+.Fa uid ,
+a new structure will be allocated and initialized.
+The uidinfo hash mutex is acquired and released.
.Pp
The
.Fn uihold
-function increases the reference count on the
-.Vt uidinfo
-structure.
+function increases the reference count on
+.Fa uip .
+.Fa uip's
+lock is acquired and released.
.Pp
The
.Fn uifree
-function decreases the reference count on the
-.Vt uidinfo
-structure.
-If the count reaches 0, the storage for the structure is freed.
+function decreases the reference count on
+.Fa uip ,
+and if the count reaches 0
+.Fa uip
+is freed.
+.Fa uip's
+lock is acquired and release and the uidinfo hash mutex may be
+acquired and released.
.Sh RETURN VALUES
-The functions that return values all return a pointer to a
+.Fn uifind
+returns a pointer to an initialized
.Vt uidinfo
-structure.
+structure, and should not fail.
.Sh AUTHORS
This man page was written by
.An Chad David Aq davidc@acns.ab.ca .