vm_overcommit: put into __read_mostly section

Suggested by:	mjg
Reviewed by:	brooks, imp (previous version)
Discussed with:	markj
Sponsored by:	The FreeBSD Foundation
MFC after:	2 weeks
Differential revision:	https://reviews.freebsd.org/D36540
This commit is contained in:
Konstantin Belousov 2022-09-13 13:00:12 +03:00
parent a6cc4c6e98
commit ccdaa1ab1c

View File

@ -169,7 +169,7 @@ SYSCTL_PROC(_vm, OID_AUTO, swap_total, CTLTYPE_U64 | CTLFLAG_RD | CTLFLAG_MPSAFE
&swap_total, 0, sysctl_page_shift, "QU",
"Total amount of available swap storage.");
int vm_overcommit = 0;
int vm_overcommit __read_mostly = 0;
SYSCTL_INT(_vm, VM_OVERCOMMIT, overcommit, CTLFLAG_RW, &vm_overcommit, 0,
"Configure virtual memory overcommit behavior. See tuning(7) "
"for details.");