Add OID for the vm.overcommit sysctl. This makes it possible to remove
one call to sysctl(2) from jemalloc startup code. (That also requires changes to jemalloc, but I plan to push those to upstream first.) Reviewed by: kib MFC after: 2 weeks Sponsored by: DARPA, AFRL Differential Revision: https://reviews.freebsd.org/D12745
This commit is contained in:
parent
ae63a24a87
commit
b1c2085f71
@ -28,7 +28,7 @@
|
||||
.\" @(#)sysctl.3 8.4 (Berkeley) 5/9/95
|
||||
.\" $FreeBSD$
|
||||
.\"
|
||||
.Dd September 10, 2015
|
||||
.Dd October 22, 2017
|
||||
.Dt SYSCTL 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
@ -741,6 +741,7 @@ privilege may change the value.
|
||||
.It Dv VM_V_FREE_TARGET Ta integer Ta yes
|
||||
.It Dv VM_V_INACTIVE_TARGET Ta integer Ta yes
|
||||
.It Dv VM_V_PAGEOUT_FREE_MIN Ta integer Ta yes
|
||||
.It Dv VM_OVERCOMMIT Ta integer Ta yes
|
||||
.El
|
||||
.Bl -tag -width 6n
|
||||
.It Li VM_LOADAVG
|
||||
@ -773,6 +774,9 @@ process address space when needed.
|
||||
.It Li VM_V_PAGEOUT_FREE_MIN
|
||||
If the amount of free and cache memory falls below this value, the
|
||||
pageout daemon will enter "memory conserving mode" to avoid deadlock.
|
||||
.It Li VM_OVERCOMMIT
|
||||
Overcommit behaviour, as described in
|
||||
.Xr tuning 7 .
|
||||
.El
|
||||
.Sh RETURN VALUES
|
||||
.Rv -std
|
||||
|
@ -157,7 +157,7 @@ static vm_ooffset_t swap_reserved;
|
||||
SYSCTL_QUAD(_vm, OID_AUTO, swap_reserved, CTLFLAG_RD, &swap_reserved, 0,
|
||||
"Amount of swap storage needed to back all allocated anonymous memory.");
|
||||
static int overcommit = 0;
|
||||
SYSCTL_INT(_vm, OID_AUTO, overcommit, CTLFLAG_RW, &overcommit, 0,
|
||||
SYSCTL_INT(_vm, VM_OVERCOMMIT, overcommit, CTLFLAG_RW, &overcommit, 0,
|
||||
"Configure virtual memory overcommit behavior. See tuning(7) "
|
||||
"for details.");
|
||||
static unsigned long swzone;
|
||||
|
@ -84,7 +84,8 @@
|
||||
#define VM_V_PAGEOUT_FREE_MIN 9 /* vm_cnt.v_pageout_free_min */
|
||||
#define VM_OBSOLETE_10 10 /* pageout algorithm */
|
||||
#define VM_SWAPPING_ENABLED 11 /* swapping enabled */
|
||||
#define VM_MAXID 12 /* number of valid vm ids */
|
||||
#define VM_OVERCOMMIT 12 /* vm.overcommit */
|
||||
#define VM_MAXID 13 /* number of valid vm ids */
|
||||
|
||||
/*
|
||||
* Structure for swap device statistics
|
||||
|
Loading…
Reference in New Issue
Block a user