Deleted Added
full compact
sysctl.9 (158122) sysctl.9 (158130)
1.\"
2.\" Copyright (c) 2006 Robert N. M. Watson
3.\" All rights reserved.
4.\"
5.\" Redistribution and use in source and binary forms, with or without
6.\" modification, are permitted provided that the following conditions
7.\" are met:
8.\" 1. Redistributions of source code must retain the above copyright

--- 9 unchanged lines hidden (view full) ---

18.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24.\" SUCH DAMAGE.
25.\"
1.\"
2.\" Copyright (c) 2006 Robert N. M. Watson
3.\" All rights reserved.
4.\"
5.\" Redistribution and use in source and binary forms, with or without
6.\" modification, are permitted provided that the following conditions
7.\" are met:
8.\" 1. Redistributions of source code must retain the above copyright

--- 9 unchanged lines hidden (view full) ---

18.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24.\" SUCH DAMAGE.
25.\"
26.\" $FreeBSD: head/share/man/man9/sysctl.9 158122 2006-04-28 19:43:44Z rwatson $
26.\" $FreeBSD: head/share/man/man9/sysctl.9 158130 2006-04-28 23:21:36Z keramida $
27.\"
28.Dd April 28, 2006
29.Dt SYSCTL 9
30.Os
31.Sh NAME
32.Nm SYSCTL_DECL ,
33.Nm SYSCTL_INT ,
34.Nm SYSCTL_LONG ,

--- 98 unchanged lines hidden (view full) ---

133The
134.Nm
135kernel interfaces allow code to statically declare
136.Xr sysctl 8
137MIB entries, which will be initialized when the kernel module containing the
138declaration is initialized.
139When the module is unloaded, the sysctl will be automatically destroyed.
140.Pp
27.\"
28.Dd April 28, 2006
29.Dt SYSCTL 9
30.Os
31.Sh NAME
32.Nm SYSCTL_DECL ,
33.Nm SYSCTL_INT ,
34.Nm SYSCTL_LONG ,

--- 98 unchanged lines hidden (view full) ---

133The
134.Nm
135kernel interfaces allow code to statically declare
136.Xr sysctl 8
137MIB entries, which will be initialized when the kernel module containing the
138declaration is initialized.
139When the module is unloaded, the sysctl will be automatically destroyed.
140.Pp
141Sysctl nodes are created in a hierarchal tree, with all static nodes being
141Sysctl nodes are created in a hierarchical tree, with all static nodes being
142represented by named C data structures; in order to create a new node under
143an existing node in the tree, the structure representing the desired parent
144node must be declared in the current context using
145.Fn SYSCTL_DECL .
146.Pp
147New nodes are declared using one of
148.Nm SYSCTL_INT ,
149.Nm SYSCTL_LONG ,

--- 91 unchanged lines hidden (view full) ---

241Machine-dependent configuration parameters.
242.It Dv net
243Network subsystem.
244Various protocols have name spaces under
245.Dv net .
246.It Dv regression
247Regression test configuration and information.
248.It Dv security
142represented by named C data structures; in order to create a new node under
143an existing node in the tree, the structure representing the desired parent
144node must be declared in the current context using
145.Fn SYSCTL_DECL .
146.Pp
147New nodes are declared using one of
148.Nm SYSCTL_INT ,
149.Nm SYSCTL_LONG ,

--- 91 unchanged lines hidden (view full) ---

241Machine-dependent configuration parameters.
242.It Dv net
243Network subsystem.
244Various protocols have name spaces under
245.Dv net .
246.It Dv regression
247Regression test configuration and information.
248.It Dv security
249Security and security policy configuration and information.
249Security and security-policy configuration and information.
250.It Dv sysctl
251Reserved name space for the implementation of sysctl.
252.It Dv user
253Configuration settings relating to user application behavior.
250.It Dv sysctl
251Reserved name space for the implementation of sysctl.
252.It Dv user
253Configuration settings relating to user application behavior.
254Generally, configuring applications using kernel sysctls is disouraged.
254Generally, configuring applications using kernel sysctls is discouraged.
255.It Dv vfs
256Virtual file system configuration and information.
257.It Dv vm
258Virtual memory subsystem configuration and information.
259.El
260.Sh EXAMPLES
261Sample use of
262.Nm SYSCTL_DECL

--- 48 unchanged lines hidden (view full) ---

311 */
312SYSCTL_PROC(_kern_timecounter, OID_AUTO, hardware, CTLTYPE_STRING |
313 CTLFLAG_RW, NULL, 0, sysctl_kern_timecounter_hardware, "A",
314 "");
315.Ed
316.Pp
317When adding, modifying, or removing sysctl names, it is important to be
318aware that these interfaces may be used by users, libraries, applications,
255.It Dv vfs
256Virtual file system configuration and information.
257.It Dv vm
258Virtual memory subsystem configuration and information.
259.El
260.Sh EXAMPLES
261Sample use of
262.Nm SYSCTL_DECL

--- 48 unchanged lines hidden (view full) ---

311 */
312SYSCTL_PROC(_kern_timecounter, OID_AUTO, hardware, CTLTYPE_STRING |
313 CTLFLAG_RW, NULL, 0, sysctl_kern_timecounter_hardware, "A",
314 "");
315.Ed
316.Pp
317When adding, modifying, or removing sysctl names, it is important to be
318aware that these interfaces may be used by users, libraries, applications,
319and even books, and are implicitly published application interfaces.
319or documentation (such as published books), and are implicitly published application interfaces.
320As with other application interfaces, caution must be taken not to break
321existing applications, and to think about future use of new name spaces so as
322to avoid the need to rename or remove interfaces that might be depended on in
323the future.
324.Sh SEE ALSO
325.Xr sysctl 8 ,
326.Xr sysctl_add_oid 9 ,
327.Xr sysctl_ctx_free 9 ,

--- 16 unchanged lines hidden ---
320As with other application interfaces, caution must be taken not to break
321existing applications, and to think about future use of new name spaces so as
322to avoid the need to rename or remove interfaces that might be depended on in
323the future.
324.Sh SEE ALSO
325.Xr sysctl 8 ,
326.Xr sysctl_add_oid 9 ,
327.Xr sysctl_ctx_free 9 ,

--- 16 unchanged lines hidden ---