xref: /illumos-gate/usr/src/man/man9f/vmem_contains.9f (revision bc1f688b4872ace323eaddbb1a6365d054e7bf56)
1.\"
2.\" This file and its contents are supplied under the terms of the
3.\" Common Development and Distribution License ("CDDL"), version 1.0.
4.\" You may only use this file in accordance with the terms of version
5.\" 1.0 of the CDDL.
6.\"
7.\" A full copy of the text of the CDDL should have accompanied this
8.\" source.  A copy of the CDDL is also available via the Internet at
9.\" http://www.illumos.org/license/CDDL.
10.\"
11.\"
12.\" Copyright 2017, Richard Lowe.
13.\"
14.Dd Jan 18, 2017
15.Dt VMEM_CONTAINS 9F
16.Os
17.Sh NAME
18.Nm vmem_contains
19.Nd check for membership in a vmem arena
20.Sh SYNOPSIS
21.In sys/vmem.h
22.Ft int
23.Fo vmem_contains
24.Fa "vmem_t *vmp"
25.Fa "void *vaddr"
26.Fa "size_t *size"
27.Fc
28.Sh INTERFACE LEVEL
29illumos DDI specific
30.Sh PARAMETERS
31.Bl -tag -width Ds
32.It Fa vmp
33The vmem arena
34.It Fa vaddr
35address of the segment to query.
36.It Fa size
37size of the segment to query
38.El
39.Sh DESCRIPTION
40The
41.Fn vmem_contains
42function checks whether a segment of
43.Fa size
44bytes at
45.Fa vaddr
46exists within the vmem arena
47.Fa vmp .
48.Sh CONTEXT
49This function may be called from user or kernel context.
50.Sh RETURN VALUES
51.Fn vmem_contains
52returns non\-0 if the segment exists, and 0 otherwise.
53.Sh SEE ALSO
54.Xr vmem 9 ,
55.Xr vmem_add 9F ,
56.Xr vmem_alloc 9F ,
57.Xr vmem_create 9F
58