summaryrefslogtreecommitdiff
path: root/sys/kern/vfs_mount.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/kern/vfs_mount.c')
-rw-r--r--sys/kern/vfs_mount.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/sys/kern/vfs_mount.c b/sys/kern/vfs_mount.c
index 51a464a..39f98d2 100644
--- a/sys/kern/vfs_mount.c
+++ b/sys/kern/vfs_mount.c
@@ -74,6 +74,7 @@ int
mount(struct mount_args *margs)
{
struct fs_info *fip;
+ struct vfsops *vfsops;
struct mount *mp;
int error;
@@ -95,13 +96,18 @@ mount(struct mount_args *margs)
return error;
}
+ vfsops = fip->vfsops;
+ if (vfsops->mount == NULL) {
+ return -ENOTSUP;
+ }
+
mp = kalloc(sizeof(*mp));
if (mp == NULL) {
return -ENOMEM;
}
mp->fip = fip;
- error = vnode_init(&mp->vp, VDIR);
+ error = vfsops->mount(fip, mp);
if (error < 0) {
kfree(mp);
return error;