diff options
author | wollman <wollman@FreeBSD.org> | 1994-10-20 00:48:28 +0000 |
---|---|---|
committer | wollman <wollman@FreeBSD.org> | 1994-10-20 00:48:28 +0000 |
commit | fee1af436823ae98e696ae6862e8196e304fc0f2 (patch) | |
tree | de70a5583f7a3fd634d16c3bdd11e618c57fa668 /sys/kern/vfs_init.c | |
parent | ccc81f66b716a6456d3e5954073f4947cd60e923 (diff) | |
download | FreeBSD-src-fee1af436823ae98e696ae6862e8196e304fc0f2.zip FreeBSD-src-fee1af436823ae98e696ae6862e8196e304fc0f2.tar.gz |
Actually implement the functionality documented in sysctl.h for type CTL_FS.
(Namely, call a filesystem-dependent sysctl function analogous to how it works
for networking and (now) physical devices.)
Diffstat (limited to 'sys/kern/vfs_init.c')
-rw-r--r-- | sys/kern/vfs_init.c | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/sys/kern/vfs_init.c b/sys/kern/vfs_init.c index 3fe1555..508e23f 100644 --- a/sys/kern/vfs_init.c +++ b/sys/kern/vfs_init.c @@ -36,7 +36,7 @@ * SUCH DAMAGE. * * @(#)vfs_init.c 8.3 (Berkeley) 1/4/94 - * $Id: vfs_init.c,v 1.7 1994/09/22 22:10:36 wollman Exp $ + * $Id: vfs_init.c,v 1.8 1994/10/08 22:33:42 phk Exp $ */ @@ -321,6 +321,18 @@ fs_sysctl(name, namelen, oldp, oldlenp, newp, newlen, p) return 0; default: + if(namelen < 1) return EINVAL; + + i = name[0]; + + if(i <= MOUNT_MAXTYPE + && vfssw[i] + && vfssw[i]->vfs_sysctl) { + return vfssw[i]->vfs_sysctl(name + 1, namelen - 1, + oldp, oldlenp, + newp, newlen, p); + } + return (EOPNOTSUPP); } /* NOTREACHED */ |