diff options
author | jhb <jhb@FreeBSD.org> | 2009-01-23 22:49:23 +0000 |
---|---|---|
committer | jhb <jhb@FreeBSD.org> | 2009-01-23 22:49:23 +0000 |
commit | a9601871c9cab7b5c2e29040b753a7ef82517e43 (patch) | |
tree | 2c18b5812e7c67819c56727cb3850858b9a5fc57 /sys/kern/vfs_cache.c | |
parent | 0245a3370f55dccdbd0670687fbe5a6d704ed8c9 (diff) | |
download | FreeBSD-src-a9601871c9cab7b5c2e29040b753a7ef82517e43.zip FreeBSD-src-a9601871c9cab7b5c2e29040b753a7ef82517e43.tar.gz |
- Mark all standalone INT/LONG/QUAD sysctl's MPSAFE. This is done
inside the SYSCTL() macros and thus does not need to be done for
all of the nodes scattered across the source tree.
- Mark the name-cache related sysctl's (including debug.hashstat.*) MPSAFE.
- Mark vm.loadavg MPSAFE.
- Remove GIANT_REQUIRED from vmtotal() (everything in this routine already
has sufficient locking) and mark vm.vmtotal MPSAFE.
- Mark the vm.stats.(sys|vm).* sysctls MPSAFE.
Diffstat (limited to 'sys/kern/vfs_cache.c')
-rw-r--r-- | sys/kern/vfs_cache.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/sys/kern/vfs_cache.c b/sys/kern/vfs_cache.c index e79a568..a98a3cf 100644 --- a/sys/kern/vfs_cache.c +++ b/sys/kern/vfs_cache.c @@ -163,8 +163,8 @@ static u_long numposhits; STATNODE(CTLFLAG_RD, numposhits, &numposhits); static u_long numnegzaps; STATNODE(CTLFLAG_RD, numnegzaps, &numnegzaps); static u_long numneghits; STATNODE(CTLFLAG_RD, numneghits, &numneghits); -SYSCTL_OPAQUE(_vfs_cache, OID_AUTO, nchstats, CTLFLAG_RD, &nchstats, - sizeof(nchstats), "LU", "VFS cache effectiveness statistics"); +SYSCTL_OPAQUE(_vfs_cache, OID_AUTO, nchstats, CTLFLAG_RD | CTLFLAG_MPSAFE, + &nchstats, sizeof(nchstats), "LU", "VFS cache effectiveness statistics"); @@ -212,8 +212,9 @@ sysctl_debug_hashstat_rawnchash(SYSCTL_HANDLER_ARGS) } return (0); } -SYSCTL_PROC(_debug_hashstat, OID_AUTO, rawnchash, CTLTYPE_INT|CTLFLAG_RD, - 0, 0, sysctl_debug_hashstat_rawnchash, "S,int", "nchash chain lengths"); +SYSCTL_PROC(_debug_hashstat, OID_AUTO, rawnchash, CTLTYPE_INT|CTLFLAG_RD| + CTLFLAG_MPSAFE, 0, 0, sysctl_debug_hashstat_rawnchash, "S,int", + "nchash chain lengths"); static int sysctl_debug_hashstat_nchash(SYSCTL_HANDLER_ARGS) @@ -260,8 +261,9 @@ sysctl_debug_hashstat_nchash(SYSCTL_HANDLER_ARGS) return (error); return (0); } -SYSCTL_PROC(_debug_hashstat, OID_AUTO, nchash, CTLTYPE_INT|CTLFLAG_RD, - 0, 0, sysctl_debug_hashstat_nchash, "I", "nchash chain lengths"); +SYSCTL_PROC(_debug_hashstat, OID_AUTO, nchash, CTLTYPE_INT|CTLFLAG_RD| + CTLFLAG_MPSAFE, 0, 0, sysctl_debug_hashstat_nchash, "I", + "nchash chain lengths"); /* * cache_zap(): |