Date: Tue, 02 Dec 2025 03:41:55 +0000 From: Konstantin Belousov <kib@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: 7295aeaf5f5c - main - libuvmem: provide man page mostly as a pointer to vmem(9) Message-ID: <692e6003.3225e.38bd67fc@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=7295aeaf5f5cbbbb16d4992b13b08bce09f03609 commit 7295aeaf5f5cbbbb16d4992b13b08bce09f03609 Author: Konstantin Belousov <kib@FreeBSD.org> AuthorDate: 2025-10-15 22:10:16 +0000 Commit: Konstantin Belousov <kib@FreeBSD.org> CommitDate: 2025-12-02 03:41:13 +0000 libuvmem: provide man page mostly as a pointer to vmem(9) Reviewed by: bnovkov, markj Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D27220 --- lib/libuvmem/Makefile | 2 ++ lib/libuvmem/libuvmem.3 | 71 +++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 73 insertions(+) diff --git a/lib/libuvmem/Makefile b/lib/libuvmem/Makefile index 9d13eabd277c..0dae3eb77a74 100644 --- a/lib/libuvmem/Makefile +++ b/lib/libuvmem/Makefile @@ -10,6 +10,8 @@ CFLAGS.clang+=-Wno-thread-safety-analysis SYMBOL_MAPS= ${.CURDIR}/Symbol.map VERSION_DEF= ${SRCTOP}/lib/libc/Versions.def +MAN= libuvmem.3 + .include <src.opts.mk> .PATH: ${SRCTOP}/sys/kern diff --git a/lib/libuvmem/libuvmem.3 b/lib/libuvmem/libuvmem.3 new file mode 100644 index 000000000000..5fbb50ec57c2 --- /dev/null +++ b/lib/libuvmem/libuvmem.3 @@ -0,0 +1,71 @@ +.\" SPDX-License-Identifier: BSD-2-Clause +.\" +.\" Copyright (c) 2025 The FreeBSD Foundation +.\" +.\" This documentation was written by +.\" Konstantin Belousov <kib@FreeBSD.org> under sponsorship +.\" from the FreeBSD Foundation. +.\" +.Dd October 16, 2025 +.Dt LIBUVMEM 3 +.Os +.Sh NAME +.Nm libuvmem +.Nd userspace general purpose resource allocator +.Sh SYNOPSIS +.Lb libuvmem +.In sys/vmem.h +.Sh DESCRIPTION +The +.Nm +is a general purpose resource allocator. +It is a port of the kernel facility of the similar name +.Nm vmem . +.Pp +Refer to the description of the kernel allocator +.Xr vmem 9 +to get the documentation for it. +.Sh NOTES +The +.Dq quantum cache +feature is not implemented for userspace, and the +.Fa quantum +and +.Fa qcache_max +arguments of the +.Fn vmem_create +function are ignored. +.Pp +The library internally uses +.Xr malloc 3 +to allocate structures tracking allocations. +.Pp +The allocator is thread-safe. +Locks for separate +.Nm vmem's +are independent between each other. +.Pp +The supported +.Fa flags +for the +.Fn vmem_xalloc +function are +.Bl -bullet +.It +.Dv M_NOWAIT +.It +.Dv M_FIRSTFIT +.It +.Dv M_BESTFIT +.It +.Dv M_NEXTFIT +.El +.Sh AUTHORS +See +.Xr vmem 9 +for the history of the kernel allocator. +.Pp +The userspace port for +.Fx +was done by +.An Konstantin Belousov Aq Mt kib@FreeBSD.org .
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?692e6003.3225e.38bd67fc>
