diff options
author | phk <phk@FreeBSD.org> | 2004-07-30 22:08:52 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 2004-07-30 22:08:52 +0000 |
commit | 2d868d02cfcc9af8da398c52add2f28fe1c493bc (patch) | |
tree | af2a6b4c3e63a13443b647b947b57d5b31690b5a /sys/fs/nullfs/null_vfsops.c | |
parent | 941a15ae99cc0252acd241ea5e407eb00a540858 (diff) | |
download | FreeBSD-src-2d868d02cfcc9af8da398c52add2f28fe1c493bc.zip FreeBSD-src-2d868d02cfcc9af8da398c52add2f28fe1c493bc.tar.gz |
Put a version element in the VFS filesystem configuration structure
and refuse initializing filesystems with a wrong version. This will
aid maintenance activites on the 5-stable branch.
s/vfs_mount/vfs_omount/
s/vfs_nmount/vfs_mount/
Name our filesystems mount function consistently.
Eliminate the namiedata argument to both vfs_mount and vfs_omount.
It was originally there to save stack space. A few places abused
it to get hold of some credentials to pass around. Effectively
it is unused.
Reorganize the root filesystem selection code.
Diffstat (limited to 'sys/fs/nullfs/null_vfsops.c')
-rw-r--r-- | sys/fs/nullfs/null_vfsops.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/sys/fs/nullfs/null_vfsops.c b/sys/fs/nullfs/null_vfsops.c index 25c1651..ea49163 100644 --- a/sys/fs/nullfs/null_vfsops.c +++ b/sys/fs/nullfs/null_vfsops.c @@ -57,7 +57,7 @@ static MALLOC_DEFINE(M_NULLFSMNT, "NULLFS mount", "NULLFS mount structure"); static vfs_fhtovp_t nullfs_fhtovp; static vfs_checkexp_t nullfs_checkexp; -static vfs_nmount_t nullfs_mount; +static vfs_mount_t nullfs_mount; static vfs_quotactl_t nullfs_quotactl; static vfs_root_t nullfs_root; static vfs_start_t nullfs_start; @@ -72,10 +72,7 @@ static vfs_extattrctl_t nullfs_extattrctl; * Mount null layer */ static int -nullfs_mount(mp, ndp, td) - struct mount *mp; - struct nameidata *ndp; - struct thread *td; +nullfs_mount(struct mount *mp, struct thread *td) { int error = 0; struct vnode *lowerrootvp, *vp; @@ -84,6 +81,7 @@ nullfs_mount(mp, ndp, td) char *target; size_t size; int isvnunlocked = 0, len; + struct nameidata nd, *ndp = &nd; NULLFSDEBUG("nullfs_mount(mp = %p)\n", (void *)mp); @@ -403,7 +401,7 @@ static struct vfsops null_vfsops = { .vfs_extattrctl = nullfs_extattrctl, .vfs_fhtovp = nullfs_fhtovp, .vfs_init = nullfs_init, - .vfs_nmount = nullfs_mount, + .vfs_mount = nullfs_mount, .vfs_quotactl = nullfs_quotactl, .vfs_root = nullfs_root, .vfs_start = nullfs_start, |