aboutsummaryrefslogtreecommitdiff
path: root/share
diff options
context:
space:
mode:
authorJeroen Ruigrok van der Werven <asmodai@FreeBSD.org>2002-05-18 11:12:02 +0000
committerJeroen Ruigrok van der Werven <asmodai@FreeBSD.org>2002-05-18 11:12:02 +0000
commit382682b2a4c79d66e2e504a99e60ef3bbc20fe4a (patch)
treeb9827775ff458f52163a4872fdd7a00df3e0519c /share
parent4ecbca5e4fbc32d7f2dd3490fac2b053151c750e (diff)
Notes
Diffstat (limited to 'share')
-rw-r--r--share/man/man9/Makefile1
-rw-r--r--share/man/man9/zone.912
2 files changed, 13 insertions, 0 deletions
diff --git a/share/man/man9/Makefile b/share/man/man9/Makefile
index f819a9dccb9a2..430f6c6043a36 100644
--- a/share/man/man9/Makefile
+++ b/share/man/man9/Makefile
@@ -391,6 +391,7 @@ MLINKS+=vcount.9 count_dev.9
MLINKS+=zone.9 uma.9
MLINKS+=zone.9 uma_zalloc.9
+MLINKS+=zone.9 uma_zcreate.9
MLINKS+=zone.9 uma_zfree.9
MLINKS+=zone.9 uma_zdestroy.9
diff --git a/share/man/man9/zone.9 b/share/man/man9/zone.9
index df23347ae9052..f059eba3cef03 100644
--- a/share/man/man9/zone.9
+++ b/share/man/man9/zone.9
@@ -29,6 +29,7 @@
.Dt ZONE 9
.Os
.Sh NAME
+.Nm uma_zcreate ,
.Nm uma_zalloc ,
.Nm uma_zfree ,
.Nm uma_zdestroy
@@ -37,6 +38,9 @@
.In sys/param.h
.In sys/queue.h
.In vm/uma.h
+.Ft uma_zone_t
+.Fn uma_zcreate "char *name" "int size" "uma_ctor ctor" "uma_dtor dtor" "uma_in
+it uminit" "uma_fini fini" "int align" "u_int16_t flags"
.Ft void *
.Fn uma_zalloc "uma_zone_t zone, int flags"
.Ft void
@@ -77,6 +81,14 @@ it will have been cleared to zeroes, however subsequent allocations
will retain the contents as of the last free, with the exception of the
fields mentioned above.
.Pp
+The
+.Fn uma_zcreate
+function creates a new zone from which items may then be allocated from.
+The
+.Fa name
+argument is a text name of the zone for debugging and stats; this memory
+should not be freed until the zone has been deallocated.
+.Pp
To allocate an item from a zone, simply call
.Fn uma_zalloc
with a pointer to that zone