Wed Dec 22 17:28:18 2021 UTC ()
Document PR_PSERIALIZE.  Remove documentation for pool_cache_setpredestruct().


(thorpej)
diff -r1.2400 -r1.2401 src/distrib/sets/lists/comp/mi
diff -r1.459 -r1.460 src/share/man/man9/Makefile
diff -r1.49 -r1.50 src/share/man/man9/pool.9
diff -r1.23 -r1.24 src/share/man/man9/pool_cache.9

cvs diff -r1.2400 -r1.2401 src/distrib/sets/lists/comp/mi (expand / switch to unified diff)

--- src/distrib/sets/lists/comp/mi 2021/12/21 18:59:22 1.2400
+++ src/distrib/sets/lists/comp/mi 2021/12/22 17:28:17 1.2401
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1# $NetBSD: mi,v 1.2400 2021/12/21 18:59:22 thorpej Exp $ 1# $NetBSD: mi,v 1.2401 2021/12/22 17:28:17 thorpej Exp $
2# 2#
3# Note: don't delete entries from here - mark them as "obsolete" instead. 3# Note: don't delete entries from here - mark them as "obsolete" instead.
4./etc/mtree/set.comp comp-sys-root 4./etc/mtree/set.comp comp-sys-root
5./usr/bin/addr2line comp-debug-bin binutils 5./usr/bin/addr2line comp-debug-bin binutils
6./usr/bin/ar comp-util-bin binutils 6./usr/bin/ar comp-util-bin binutils
7./usr/bin/as comp-util-bin binutils 7./usr/bin/as comp-util-bin binutils
8./usr/bin/asa comp-fortran-bin 8./usr/bin/asa comp-fortran-bin
9./usr/bin/atf-compile comp-obsolete obsolete 9./usr/bin/atf-compile comp-obsolete obsolete
10./usr/bin/c++ comp-cxx-bin gcccmds 10./usr/bin/c++ comp-cxx-bin gcccmds
11./usr/bin/c++filt comp-cxx-bin binutils 11./usr/bin/c++filt comp-cxx-bin binutils
12./usr/bin/c11 comp-c-bin 12./usr/bin/c11 comp-c-bin
13./usr/bin/c89 comp-c-bin 13./usr/bin/c89 comp-c-bin
14./usr/bin/c99 comp-c-bin 14./usr/bin/c99 comp-c-bin
@@ -12272,27 +12272,27 @@ @@ -12272,27 +12272,27 @@
12272./usr/share/man/cat9/pool_cache.0 comp-sys-catman .cat 12272./usr/share/man/cat9/pool_cache.0 comp-sys-catman .cat
12273./usr/share/man/cat9/pool_cache_destroy.0 comp-sys-catman .cat 12273./usr/share/man/cat9/pool_cache_destroy.0 comp-sys-catman .cat
12274./usr/share/man/cat9/pool_cache_destruct_object.0 comp-sys-catman .cat 12274./usr/share/man/cat9/pool_cache_destruct_object.0 comp-sys-catman .cat
12275./usr/share/man/cat9/pool_cache_get.0 comp-sys-catman .cat 12275./usr/share/man/cat9/pool_cache_get.0 comp-sys-catman .cat
12276./usr/share/man/cat9/pool_cache_get_paddr.0 comp-sys-catman .cat 12276./usr/share/man/cat9/pool_cache_get_paddr.0 comp-sys-catman .cat
12277./usr/share/man/cat9/pool_cache_init.0 comp-sys-catman .cat 12277./usr/share/man/cat9/pool_cache_init.0 comp-sys-catman .cat
12278./usr/share/man/cat9/pool_cache_invalidate.0 comp-sys-catman .cat 12278./usr/share/man/cat9/pool_cache_invalidate.0 comp-sys-catman .cat
12279./usr/share/man/cat9/pool_cache_invalidate_local.0 comp-obsolete obsolete 12279./usr/share/man/cat9/pool_cache_invalidate_local.0 comp-obsolete obsolete
12280./usr/share/man/cat9/pool_cache_put.0 comp-sys-catman .cat 12280./usr/share/man/cat9/pool_cache_put.0 comp-sys-catman .cat
12281./usr/share/man/cat9/pool_cache_put_paddr.0 comp-sys-catman .cat 12281./usr/share/man/cat9/pool_cache_put_paddr.0 comp-sys-catman .cat
12282./usr/share/man/cat9/pool_cache_sethardlimit.0 comp-sys-catman .cat 12282./usr/share/man/cat9/pool_cache_sethardlimit.0 comp-sys-catman .cat
12283./usr/share/man/cat9/pool_cache_sethiwat.0 comp-sys-catman .cat 12283./usr/share/man/cat9/pool_cache_sethiwat.0 comp-sys-catman .cat
12284./usr/share/man/cat9/pool_cache_setlowat.0 comp-sys-catman .cat 12284./usr/share/man/cat9/pool_cache_setlowat.0 comp-sys-catman .cat
12285./usr/share/man/cat9/pool_cache_setpredestruct.0 comp-sys-catman .cat 12285./usr/share/man/cat9/pool_cache_setpredestruct.0 comp-obsolete obsolete
12286./usr/share/man/cat9/pool_create.0 comp-sys-catman .cat 12286./usr/share/man/cat9/pool_create.0 comp-sys-catman .cat
12287./usr/share/man/cat9/pool_destroy.0 comp-sys-catman .cat 12287./usr/share/man/cat9/pool_destroy.0 comp-sys-catman .cat
12288./usr/share/man/cat9/pool_get.0 comp-sys-catman .cat 12288./usr/share/man/cat9/pool_get.0 comp-sys-catman .cat
12289./usr/share/man/cat9/pool_init.0 comp-sys-catman .cat 12289./usr/share/man/cat9/pool_init.0 comp-sys-catman .cat
12290./usr/share/man/cat9/pool_prime.0 comp-sys-catman .cat 12290./usr/share/man/cat9/pool_prime.0 comp-sys-catman .cat
12291./usr/share/man/cat9/pool_put.0 comp-sys-catman .cat 12291./usr/share/man/cat9/pool_put.0 comp-sys-catman .cat
12292./usr/share/man/cat9/pool_sethardlimit.0 comp-sys-catman .cat 12292./usr/share/man/cat9/pool_sethardlimit.0 comp-sys-catman .cat
12293./usr/share/man/cat9/pool_sethiwat.0 comp-sys-catman .cat 12293./usr/share/man/cat9/pool_sethiwat.0 comp-sys-catman .cat
12294./usr/share/man/cat9/pool_setlowat.0 comp-sys-catman .cat 12294./usr/share/man/cat9/pool_setlowat.0 comp-sys-catman .cat
12295./usr/share/man/cat9/postsig.0 comp-sys-catman .cat 12295./usr/share/man/cat9/postsig.0 comp-sys-catman .cat
12296./usr/share/man/cat9/powerhook_disestablish.0 comp-sys-catman .cat 12296./usr/share/man/cat9/powerhook_disestablish.0 comp-sys-catman .cat
12297./usr/share/man/cat9/powerhook_establish.0 comp-sys-catman .cat 12297./usr/share/man/cat9/powerhook_establish.0 comp-sys-catman .cat
12298./usr/share/man/cat9/powerof2.0 comp-sys-catman .cat 12298./usr/share/man/cat9/powerof2.0 comp-sys-catman .cat
@@ -20465,27 +20465,27 @@ @@ -20465,27 +20465,27 @@
20465./usr/share/man/html9/pool_cache.html comp-sys-htmlman html 20465./usr/share/man/html9/pool_cache.html comp-sys-htmlman html
20466./usr/share/man/html9/pool_cache_destroy.html comp-sys-htmlman html 20466./usr/share/man/html9/pool_cache_destroy.html comp-sys-htmlman html
20467./usr/share/man/html9/pool_cache_destruct_object.html comp-sys-htmlman html 20467./usr/share/man/html9/pool_cache_destruct_object.html comp-sys-htmlman html
20468./usr/share/man/html9/pool_cache_get.html comp-sys-htmlman html 20468./usr/share/man/html9/pool_cache_get.html comp-sys-htmlman html
20469./usr/share/man/html9/pool_cache_get_paddr.html comp-sys-htmlman html 20469./usr/share/man/html9/pool_cache_get_paddr.html comp-sys-htmlman html
20470./usr/share/man/html9/pool_cache_init.html comp-sys-htmlman html 20470./usr/share/man/html9/pool_cache_init.html comp-sys-htmlman html
20471./usr/share/man/html9/pool_cache_invalidate.html comp-sys-htmlman html 20471./usr/share/man/html9/pool_cache_invalidate.html comp-sys-htmlman html
20472./usr/share/man/html9/pool_cache_invalidate_local.html comp-obsolete obsolete 20472./usr/share/man/html9/pool_cache_invalidate_local.html comp-obsolete obsolete
20473./usr/share/man/html9/pool_cache_put.html comp-sys-htmlman html 20473./usr/share/man/html9/pool_cache_put.html comp-sys-htmlman html
20474./usr/share/man/html9/pool_cache_put_paddr.html comp-sys-htmlman html 20474./usr/share/man/html9/pool_cache_put_paddr.html comp-sys-htmlman html
20475./usr/share/man/html9/pool_cache_sethardlimit.html comp-sys-htmlman html 20475./usr/share/man/html9/pool_cache_sethardlimit.html comp-sys-htmlman html
20476./usr/share/man/html9/pool_cache_sethiwat.html comp-sys-htmlman html 20476./usr/share/man/html9/pool_cache_sethiwat.html comp-sys-htmlman html
20477./usr/share/man/html9/pool_cache_setlowat.html comp-sys-htmlman html 20477./usr/share/man/html9/pool_cache_setlowat.html comp-sys-htmlman html
20478./usr/share/man/html9/pool_cache_setpredestruct.html comp-sys-htmlman html 20478./usr/share/man/html9/pool_cache_setpredestruct.html comp-obsolete obsolete
20479./usr/share/man/html9/pool_create.html comp-sys-htmlman html 20479./usr/share/man/html9/pool_create.html comp-sys-htmlman html
20480./usr/share/man/html9/pool_destroy.html comp-sys-htmlman html 20480./usr/share/man/html9/pool_destroy.html comp-sys-htmlman html
20481./usr/share/man/html9/pool_get.html comp-sys-htmlman html 20481./usr/share/man/html9/pool_get.html comp-sys-htmlman html
20482./usr/share/man/html9/pool_init.html comp-sys-htmlman html 20482./usr/share/man/html9/pool_init.html comp-sys-htmlman html
20483./usr/share/man/html9/pool_prime.html comp-sys-htmlman html 20483./usr/share/man/html9/pool_prime.html comp-sys-htmlman html
20484./usr/share/man/html9/pool_put.html comp-sys-htmlman html 20484./usr/share/man/html9/pool_put.html comp-sys-htmlman html
20485./usr/share/man/html9/pool_sethardlimit.html comp-sys-htmlman html 20485./usr/share/man/html9/pool_sethardlimit.html comp-sys-htmlman html
20486./usr/share/man/html9/pool_sethiwat.html comp-sys-htmlman html 20486./usr/share/man/html9/pool_sethiwat.html comp-sys-htmlman html
20487./usr/share/man/html9/pool_setlowat.html comp-sys-htmlman html 20487./usr/share/man/html9/pool_setlowat.html comp-sys-htmlman html
20488./usr/share/man/html9/postsig.html comp-sys-htmlman html 20488./usr/share/man/html9/postsig.html comp-sys-htmlman html
20489./usr/share/man/html9/powerhook_disestablish.html comp-sys-htmlman html 20489./usr/share/man/html9/powerhook_disestablish.html comp-sys-htmlman html
20490./usr/share/man/html9/powerhook_establish.html comp-sys-htmlman html 20490./usr/share/man/html9/powerhook_establish.html comp-sys-htmlman html
20491./usr/share/man/html9/powerof2.html comp-sys-htmlman html 20491./usr/share/man/html9/powerof2.html comp-sys-htmlman html
@@ -28819,27 +28819,27 @@ @@ -28819,27 +28819,27 @@
28819./usr/share/man/man9/pool_cache.9 comp-sys-man .man 28819./usr/share/man/man9/pool_cache.9 comp-sys-man .man
28820./usr/share/man/man9/pool_cache_destroy.9 comp-sys-man .man 28820./usr/share/man/man9/pool_cache_destroy.9 comp-sys-man .man
28821./usr/share/man/man9/pool_cache_destruct_object.9 comp-sys-man .man 28821./usr/share/man/man9/pool_cache_destruct_object.9 comp-sys-man .man
28822./usr/share/man/man9/pool_cache_get.9 comp-sys-man .man 28822./usr/share/man/man9/pool_cache_get.9 comp-sys-man .man
28823./usr/share/man/man9/pool_cache_get_paddr.9 comp-sys-man .man 28823./usr/share/man/man9/pool_cache_get_paddr.9 comp-sys-man .man
28824./usr/share/man/man9/pool_cache_init.9 comp-sys-man .man 28824./usr/share/man/man9/pool_cache_init.9 comp-sys-man .man
28825./usr/share/man/man9/pool_cache_invalidate.9 comp-sys-man .man 28825./usr/share/man/man9/pool_cache_invalidate.9 comp-sys-man .man
28826./usr/share/man/man9/pool_cache_invalidate_local.9 comp-obsolete obsolete 28826./usr/share/man/man9/pool_cache_invalidate_local.9 comp-obsolete obsolete
28827./usr/share/man/man9/pool_cache_put.9 comp-sys-man .man 28827./usr/share/man/man9/pool_cache_put.9 comp-sys-man .man
28828./usr/share/man/man9/pool_cache_put_paddr.9 comp-sys-man .man 28828./usr/share/man/man9/pool_cache_put_paddr.9 comp-sys-man .man
28829./usr/share/man/man9/pool_cache_sethardlimit.9 comp-sys-man .man 28829./usr/share/man/man9/pool_cache_sethardlimit.9 comp-sys-man .man
28830./usr/share/man/man9/pool_cache_sethiwat.9 comp-sys-man .man 28830./usr/share/man/man9/pool_cache_sethiwat.9 comp-sys-man .man
28831./usr/share/man/man9/pool_cache_setlowat.9 comp-sys-man .man 28831./usr/share/man/man9/pool_cache_setlowat.9 comp-sys-man .man
28832./usr/share/man/man9/pool_cache_setpredestruct.9 comp-sys-man .man 28832./usr/share/man/man9/pool_cache_setpredestruct.9 comp-obsolete obsolete
28833./usr/share/man/man9/pool_create.9 comp-sys-man .man 28833./usr/share/man/man9/pool_create.9 comp-sys-man .man
28834./usr/share/man/man9/pool_destroy.9 comp-sys-man .man 28834./usr/share/man/man9/pool_destroy.9 comp-sys-man .man
28835./usr/share/man/man9/pool_get.9 comp-sys-man .man 28835./usr/share/man/man9/pool_get.9 comp-sys-man .man
28836./usr/share/man/man9/pool_init.9 comp-sys-man .man 28836./usr/share/man/man9/pool_init.9 comp-sys-man .man
28837./usr/share/man/man9/pool_prime.9 comp-sys-man .man 28837./usr/share/man/man9/pool_prime.9 comp-sys-man .man
28838./usr/share/man/man9/pool_put.9 comp-sys-man .man 28838./usr/share/man/man9/pool_put.9 comp-sys-man .man
28839./usr/share/man/man9/pool_sethardlimit.9 comp-sys-man .man 28839./usr/share/man/man9/pool_sethardlimit.9 comp-sys-man .man
28840./usr/share/man/man9/pool_sethiwat.9 comp-sys-man .man 28840./usr/share/man/man9/pool_sethiwat.9 comp-sys-man .man
28841./usr/share/man/man9/pool_setlowat.9 comp-sys-man .man 28841./usr/share/man/man9/pool_setlowat.9 comp-sys-man .man
28842./usr/share/man/man9/postsig.9 comp-sys-man .man 28842./usr/share/man/man9/postsig.9 comp-sys-man .man
28843./usr/share/man/man9/powerhook_disestablish.9 comp-sys-man .man 28843./usr/share/man/man9/powerhook_disestablish.9 comp-sys-man .man
28844./usr/share/man/man9/powerhook_establish.9 comp-sys-man .man 28844./usr/share/man/man9/powerhook_establish.9 comp-sys-man .man
28845./usr/share/man/man9/powerof2.9 comp-sys-man .man 28845./usr/share/man/man9/powerof2.9 comp-sys-man .man

cvs diff -r1.459 -r1.460 src/share/man/man9/Makefile (expand / switch to unified diff)

--- src/share/man/man9/Makefile 2021/12/21 18:59:22 1.459
+++ src/share/man/man9/Makefile 2021/12/22 17:28:17 1.460
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1# $NetBSD: Makefile,v 1.459 2021/12/21 18:59:22 thorpej Exp $ 1# $NetBSD: Makefile,v 1.460 2021/12/22 17:28:17 thorpej Exp $
2 2
3# Makefile for section 9 (kernel function and variable) manual pages. 3# Makefile for section 9 (kernel function and variable) manual pages.
4 4
5MAN= accept_filter.9 accf_data.9 accf_http.9 \ 5MAN= accept_filter.9 accf_data.9 accf_http.9 \
6 altq.9 arp.9 audio.9 autoconf.9 \ 6 altq.9 arp.9 audio.9 autoconf.9 \
7 bcdtobin.9 bcmp.9 bcopy.9 bintime_add.9 bluetooth.9 boothowto.9 bpf.9 \ 7 bcdtobin.9 bcmp.9 bcopy.9 bintime_add.9 bluetooth.9 boothowto.9 bpf.9 \
8 buffercache.9 bufferio.9 bufq.9 bus_dma.9 bus_space.9 byteorder.9 \ 8 buffercache.9 bufferio.9 bufq.9 bus_dma.9 bus_space.9 byteorder.9 \
9 bzero.9 \ 9 bzero.9 \
10 callback.9 callout.9 cardbus.9 clock.9 cnmagic.9 condvar.9 config.9 \ 10 callback.9 callout.9 cardbus.9 clock.9 cnmagic.9 condvar.9 config.9 \
11 cons.9 copy.9 coredump_write.9 \ 11 cons.9 copy.9 coredump_write.9 \
12 cpu_configure.9 cpu_coredump.9 cpu_dumpconf.9 \ 12 cpu_configure.9 cpu_coredump.9 cpu_dumpconf.9 \
13 cpu_lwp_fork.9 \ 13 cpu_lwp_fork.9 \
14 cpu_idle.9 cpu_initclocks.9 cpu_need_resched.9 \ 14 cpu_idle.9 cpu_initclocks.9 cpu_need_resched.9 \
@@ -748,28 +748,27 @@ MLINKS+=pool.9 pool_create.9 pool.9 pool @@ -748,28 +748,27 @@ MLINKS+=pool.9 pool_create.9 pool.9 pool
748 pool.9 pool_init.9 pool.9 pool_put.9 pool.9 pool_prime.9 \ 748 pool.9 pool_init.9 pool.9 pool_put.9 pool.9 pool_prime.9 \
749 pool.9 pool_sethiwat.9 pool.9 pool_setlowat.9 \ 749 pool.9 pool_sethiwat.9 pool.9 pool_setlowat.9 \
750 pool.9 pool_sethardlimit.9 750 pool.9 pool_sethardlimit.9
751MLINKS+=pool_cache.9 pool_cache_init.9 \ 751MLINKS+=pool_cache.9 pool_cache_init.9 \
752 pool_cache.9 pool_cache_destroy.9 \ 752 pool_cache.9 pool_cache_destroy.9 \
753 pool_cache.9 pool_cache_get_paddr.9 \ 753 pool_cache.9 pool_cache_get_paddr.9 \
754 pool_cache.9 pool_cache_get.9 \ 754 pool_cache.9 pool_cache_get.9 \
755 pool_cache.9 pool_cache_put_paddr.9 \ 755 pool_cache.9 pool_cache_put_paddr.9 \
756 pool_cache.9 pool_cache_put.9 \ 756 pool_cache.9 pool_cache_put.9 \
757 pool_cache.9 pool_cache_destruct_object.9 \ 757 pool_cache.9 pool_cache_destruct_object.9 \
758 pool_cache.9 pool_cache_invalidate.9 \ 758 pool_cache.9 pool_cache_invalidate.9 \
759 pool_cache.9 pool_cache_sethiwat.9 \ 759 pool_cache.9 pool_cache_sethiwat.9 \
760 pool_cache.9 pool_cache_setlowat.9 \ 760 pool_cache.9 pool_cache_setlowat.9 \
761 pool_cache.9 pool_cache_sethardlimit.9 \ 761 pool_cache.9 pool_cache_sethardlimit.9
762 pool_cache.9 pool_cache_setpredestruct.9 
763MLINKS+=powerhook_establish.9 powerhook_disestablish.9 762MLINKS+=powerhook_establish.9 powerhook_disestablish.9
764MLINKS+=preempt.9 yield.9 763MLINKS+=preempt.9 yield.9
765MLINKS+=pserialize.9 pserialize_create.9 \ 764MLINKS+=pserialize.9 pserialize_create.9 \
766 pserialize.9 pserialize_destroy.9 \ 765 pserialize.9 pserialize_destroy.9 \
767 pserialize.9 pserialize_read_enter.9 \ 766 pserialize.9 pserialize_read_enter.9 \
768 pserialize.9 pserialize_read_exit.9 \ 767 pserialize.9 pserialize_read_exit.9 \
769 pserialize.9 pserialize_perform.9 768 pserialize.9 pserialize_perform.9
770MLINKS+=pslist.9 PSLIST_DESTROY.9 \ 769MLINKS+=pslist.9 PSLIST_DESTROY.9 \
771 pslist.9 PSLIST_ENTRY_DESTROY.9 \ 770 pslist.9 PSLIST_ENTRY_DESTROY.9 \
772 pslist.9 PSLIST_ENTRY_INIT.9 \ 771 pslist.9 PSLIST_ENTRY_INIT.9 \
773 pslist.9 PSLIST_ENTRY_INITIALIZER.9 \ 772 pslist.9 PSLIST_ENTRY_INITIALIZER.9 \
774 pslist.9 PSLIST_INIT.9 \ 773 pslist.9 PSLIST_INIT.9 \
775 pslist.9 PSLIST_INITIALIZER.9 \ 774 pslist.9 PSLIST_INITIALIZER.9 \

cvs diff -r1.49 -r1.50 src/share/man/man9/pool.9 (expand / switch to unified diff)

--- src/share/man/man9/pool.9 2020/04/13 08:59:14 1.49
+++ src/share/man/man9/pool.9 2021/12/22 17:28:17 1.50
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1.\" $NetBSD: pool.9,v 1.49 2020/04/13 08:59:14 wiz Exp $ 1.\" $NetBSD: pool.9,v 1.50 2021/12/22 17:28:17 thorpej Exp $
2.\" 2.\"
3.\" Copyright (c) 1997, 1998, 2007 The NetBSD Foundation, Inc. 3.\" Copyright (c) 1997, 1998, 2007 The NetBSD Foundation, Inc.
4.\" All rights reserved. 4.\" All rights reserved.
5.\" 5.\"
6.\" This code is derived from software contributed to The NetBSD Foundation 6.\" This code is derived from software contributed to The NetBSD Foundation
7.\" by Paul Kranenburg. 7.\" by Paul Kranenburg.
8.\" 8.\"
9.\" Redistribution and use in source and binary forms, with or without 9.\" Redistribution and use in source and binary forms, with or without
10.\" modification, are permitted provided that the following conditions 10.\" modification, are permitted provided that the following conditions
11.\" are met: 11.\" are met:
12.\" 1. Redistributions of source code must retain the above copyright 12.\" 1. Redistributions of source code must retain the above copyright
13.\" notice, this list of conditions and the following disclaimer. 13.\" notice, this list of conditions and the following disclaimer.
14.\" 2. Redistributions in binary form must reproduce the above copyright 14.\" 2. Redistributions in binary form must reproduce the above copyright
@@ -88,32 +88,48 @@ The handle identifying the pool resource @@ -88,32 +88,48 @@ The handle identifying the pool resource
88.It Fa size 88.It Fa size
89Specifies the size of the memory items managed by the pool. 89Specifies the size of the memory items managed by the pool.
90.It Fa align 90.It Fa align
91Specifies the memory address alignment of the items returned by 91Specifies the memory address alignment of the items returned by
92.Fn pool_get . 92.Fn pool_get .
93This argument must be a power of two. 93This argument must be a power of two.
94If zero, 94If zero,
95the alignment defaults to an architecture-specific natural alignment. 95the alignment defaults to an architecture-specific natural alignment.
96.It Fa align_offset 96.It Fa align_offset
97The offset within an item to which the 97The offset within an item to which the
98.Fa align 98.Fa align
99parameter applies. 99parameter applies.
100.It Fa flags 100.It Fa flags
101Should be set to zero or 101Should be set to zero,
102.Dv PR_NOTOUCH . 102.Dv PR_NOTOUCH ,
 103or
 104.Dv PR_PSERIALIZE .
103If 105If
104.Dv PR_NOTOUCH 106.Dv PR_NOTOUCH
105is given, free items are never used to keep internal state so that 107is given, free items are never used to keep internal state so that
106the pool can be used for non memory backed objects. 108the pool can be used for non memory backed objects.
 109If
 110.Dv PR_PSERIALIZE
 111is given, then the allocator guarantees that a passive serialization
 112barrier equivalent to
 113.Dq xc_barrier(0)
 114will be performed before the object's backing store is returned to
 115the system.
 116.Dv PR_PSERIALIZE
 117implies
 118.Dv PR_NOTOUCH .
 119Because of the guarantees provided by
 120.Dv PR_PSERIALIZE ,
 121objects muste never be freed to a pool using this option from either
 122hard or soft interrupt context, as doing so may block.
107.It Fa wchan 123.It Fa wchan
108The 124The
109.Sq wait channel 125.Sq wait channel
110passed on to 126passed on to
111.Xr cv_wait 9 127.Xr cv_wait 9
112if 128if
113.Fn pool_get 129.Fn pool_get
114must wait for items to be returned to the pool. 130must wait for items to be returned to the pool.
115.It Fa palloc 131.It Fa palloc
116Can be set to 132Can be set to
117.Dv NULL 133.Dv NULL
118or 134or
119.Dv pool_allocator_kmem , 135.Dv pool_allocator_kmem ,

cvs diff -r1.23 -r1.24 src/share/man/man9/pool_cache.9 (expand / switch to unified diff)

--- src/share/man/man9/pool_cache.9 2021/12/21 18:59:22 1.23
+++ src/share/man/man9/pool_cache.9 2021/12/22 17:28:17 1.24
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1.\" $NetBSD: pool_cache.9,v 1.23 2021/12/21 18:59:22 thorpej Exp $ 1.\" $NetBSD: pool_cache.9,v 1.24 2021/12/22 17:28:17 thorpej Exp $
2.\" 2.\"
3.\" Copyright (c)2003 YAMAMOTO Takashi, 3.\" Copyright (c)2003 YAMAMOTO Takashi,
4.\" All rights reserved. 4.\" All rights reserved.
5.\" 5.\"
6.\" Redistribution and use in source and binary forms, with or without 6.\" Redistribution and use in source and binary forms, with or without
7.\" modification, are permitted provided that the following conditions 7.\" modification, are permitted provided that the following conditions
8.\" are met: 8.\" are met:
9.\" 1. Redistributions of source code must retain the above copyright 9.\" 1. Redistributions of source code must retain the above copyright
10.\" notice, this list of conditions and the following disclaimer. 10.\" notice, this list of conditions and the following disclaimer.
11.\" 2. Redistributions in binary form must reproduce the above copyright 11.\" 2. Redistributions in binary form must reproduce the above copyright
12.\" notice, this list of conditions and the following disclaimer in the 12.\" notice, this list of conditions and the following disclaimer in the
13.\" documentation and/or other materials provided with the distribution. 13.\" documentation and/or other materials provided with the distribution.
14.\" 14.\"
@@ -59,28 +59,27 @@ @@ -59,28 +59,27 @@
59.\" ------------------------------------------------------------ 59.\" ------------------------------------------------------------
60.Sh NAME 60.Sh NAME
61.Nm pool_cache , 61.Nm pool_cache ,
62.Nm pool_cache_init , 62.Nm pool_cache_init ,
63.Nm pool_cache_destroy , 63.Nm pool_cache_destroy ,
64.Nm pool_cache_get_paddr , 64.Nm pool_cache_get_paddr ,
65.Nm pool_cache_get , 65.Nm pool_cache_get ,
66.Nm pool_cache_put_paddr , 66.Nm pool_cache_put_paddr ,
67.Nm pool_cache_put , 67.Nm pool_cache_put ,
68.Nm pool_cache_destruct_object , 68.Nm pool_cache_destruct_object ,
69.Nm pool_cache_invalidate , 69.Nm pool_cache_invalidate ,
70.Nm pool_cache_sethiwat , 70.Nm pool_cache_sethiwat ,
71.Nm pool_cache_setlowat , 71.Nm pool_cache_setlowat ,
72.Nm pool_cache_sethardlimit , 72.Nm pool_cache_sethardlimit
73.Nm pool_cache_setpredestruct 
74.Nd resource-pool cache manager 73.Nd resource-pool cache manager
75.\" ------------------------------------------------------------ 74.\" ------------------------------------------------------------
76.Sh SYNOPSIS 75.Sh SYNOPSIS
77.In sys/pool.h 76.In sys/pool.h
78.\" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 77.\" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
79.Ft pool_cache_t 78.Ft pool_cache_t
80.Fn pool_cache_init \ 79.Fn pool_cache_init \
81"size_t size" "u_int align" "u_int align_offset" "int flags" \ 80"size_t size" "u_int align" "u_int align_offset" "int flags" \
82"const char *name" "struct pool_allocator *palloc" "int ipl" \ 81"const char *name" "struct pool_allocator *palloc" "int ipl" \
83"int (*ctor)(void *, void *, int)" "void (*dtor)(void *, void *)" "void *arg" 82"int (*ctor)(void *, void *, int)" "void (*dtor)(void *, void *)" "void *arg"
84.\" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 83.\" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
85.Ft void 84.Ft void
86.Fn pool_cache_destroy \ 85.Fn pool_cache_destroy \
@@ -110,30 +109,26 @@ @@ -110,30 +109,26 @@
110.Fn pool_cache_invalidate \ 109.Fn pool_cache_invalidate \
111"pool_cache_t pc" 110"pool_cache_t pc"
112.\" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 111.\" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
113.Ft void 112.Ft void
114.Fn pool_cache_sethiwat \ 113.Fn pool_cache_sethiwat \
115"pool_cache_t pc" "int n" 114"pool_cache_t pc" "int n"
116.Ft void 115.Ft void
117.Fn pool_cache_setlowat \ 116.Fn pool_cache_setlowat \
118"pool_cache_t pc" "int n" 117"pool_cache_t pc" "int n"
119.Ft void 118.Ft void
120.Fn pool_cache_sethardlimit \ 119.Fn pool_cache_sethardlimit \
121"pool_cache_t pc" "int n" "const char *warnmess" "int ratecap" 120"pool_cache_t pc" "int n" "const char *warnmess" "int ratecap"
122.\" ------------------------------------------------------------ 121.\" ------------------------------------------------------------
123.Ft void 
124.Fn pool_cache_setpredestruct \ 
125"pool_cache_t pc" "void (*fn)(void *)" 
126.\" ------------------------------------------------------------ 
127.Sh DESCRIPTION 122.Sh DESCRIPTION
128These utility routines provide management of pools of fixed-sized 123These utility routines provide management of pools of fixed-sized
129areas of memory. 124areas of memory.
130Resource pools set aside an amount of memory for exclusive use by the resource 125Resource pools set aside an amount of memory for exclusive use by the resource
131pool owner. 126pool owner.
132This can be used by applications to guarantee the availability of a minimum 127This can be used by applications to guarantee the availability of a minimum
133amount of memory needed to continue operation independent of the memory 128amount of memory needed to continue operation independent of the memory
134resources currently available from the system-wide memory allocator. 129resources currently available from the system-wide memory allocator.
135.Pp 130.Pp
136.Nm 131.Nm
137follows the 132follows the
138.Xr pool 9 133.Xr pool 9
139API closely and offers routines that are functionally equivalent to 134API closely and offers routines that are functionally equivalent to
@@ -165,32 +160,48 @@ Specifies the size of the memory items m @@ -165,32 +160,48 @@ Specifies the size of the memory items m
165.Pp 160.Pp
166Specifies the memory address alignment of the items returned by 161Specifies the memory address alignment of the items returned by
167.Fn pool_cache_get . 162.Fn pool_cache_get .
168This argument must be a power of two. 163This argument must be a power of two.
169If zero, 164If zero,
170the alignment defaults to an architecture-specific natural alignment. 165the alignment defaults to an architecture-specific natural alignment.
171.It Fa align_offset 166.It Fa align_offset
172.Pp 167.Pp
173The offset within an item to which the 168The offset within an item to which the
174.Fa align 169.Fa align
175parameter applies. 170parameter applies.
176.It Fa flags 171.It Fa flags
177.Pp 172.Pp
178Should be set to zero or 173Should be set to zero,
179.Dv PR_NOTOUCH . 174.Dv PR_NOTOUCH ,
 175or
 176.Dv PR_PSERIALIZE .
180If 177If
181.Dv PR_NOTOUCH 178.Dv PR_NOTOUCH
182is given, free items are never used to keep internal state so that 179is given, free items are never used to keep internal state so that
183the pool can be used for non memory backed objects. 180the pool can be used for non memory backed objects.
 181If
 182.Dv PR_PSERIALIZE
 183is given, then the allocator guarantees that a passive serialization barrier
 184equivalent to
 185.Dq xc_barrier(0)
 186will be performed before either the object's destructor is called or
 187before object's backing store is returned to the system.
 188.Dv PR_PSERIALIZE
 189implies
 190.Dv PR_NOTOUCH .
 191Because of the guarantees provided by
 192.Dv PR_PSERIALIZE ,
 193objects must never be freed to a pool cache using this option
 194from either hard or soft interrupt context, as doing so may block.
184.It Fa name 195.It Fa name
185.Pp 196.Pp
186The name used to identify the object in diagnostic output. 197The name used to identify the object in diagnostic output.
187.It Fa palloc 198.It Fa palloc
188.Pp 199.Pp
189Should be typically be set to NULL, instructing 200Should be typically be set to NULL, instructing
190.Fn pool_cache_init 201.Fn pool_cache_init
191to select an appropriate back-end allocator. 202to select an appropriate back-end allocator.
192Alternate allocators can be used to partition space from arbitrary sources. 203Alternate allocators can be used to partition space from arbitrary sources.
193Use of alternate allocators is not documented here as it is not a stable, 204Use of alternate allocators is not documented here as it is not a stable,
194endorsed part of the API. 205endorsed part of the API.
195.It Fa ipl 206.It Fa ipl
196.Pp 207.Pp
@@ -342,35 +353,26 @@ The number of free items is not guarante @@ -342,35 +353,26 @@ The number of free items is not guarante
342.\" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 353.\" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
343.It Fn pool_cache_sethardlimit "pc" "n" "warnmess" "ratecap" 354.It Fn pool_cache_sethardlimit "pc" "n" "warnmess" "ratecap"
344Set the maximum number of total items (both free and allocated) for the backing 355Set the maximum number of total items (both free and allocated) for the backing
345.Xr pool 9 356.Xr pool 9
346to 357to
347.Fa n . 358.Fa n .
348When the hard limit is reached, the warning message 359When the hard limit is reached, the warning message
349.Fa warnmess 360.Fa warnmess
350will be logged. 361will be logged.
351.Fa ratecap 362.Fa ratecap
352represents the minimal interval (in seconds) after which another warning 363represents the minimal interval (in seconds) after which another warning
353message is issued when the pool hits its hard limit again. 364message is issued when the pool hits its hard limit again.
354.\" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 365.\" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
355.It Fn pool_cache_setpredestruct "fn" 
356Sets a pre-destructor hook for the pool cache. 
357This hook will be invoked 
358.Pq with the same argument passed to the destructor 
359before a batch of one or more objects is destructed. 
360Pool cache users who rely on type-stability or use other 
361forms of passive serialization may use this hook as a 
362synchronization point. 
363.\" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 
364.It Fn pool_cache_prime "pc" "n" 366.It Fn pool_cache_prime "pc" "n"
365Set the minimum number of total items (both free and allocated) for the backing 367Set the minimum number of total items (both free and allocated) for the backing
366.Xr pool 9 368.Xr pool 9
367to 369to
368.Fa n . 370.Fa n .
369.El 371.El
370.\" ------------------------------------------------------------ 372.\" ------------------------------------------------------------
371.Sh CODE REFERENCES 373.Sh CODE REFERENCES
372The 374The
373.Nm 375.Nm
374subsystem is implemented within the file 376subsystem is implemented within the file
375.Pa sys/kern/subr_pool.c . 377.Pa sys/kern/subr_pool.c .
376.Sh SEE ALSO 378.Sh SEE ALSO