From d1d9c4f5bca9d6c55419ce30210d403bcadfb0a1 Mon Sep 17 00:00:00 2001 From: rodrigc Date: Sun, 28 May 2006 20:09:18 +0000 Subject: Modify MNT_UPDATE behavior for nullfs so that it does not return EOPNOTSUPP if an "export" parameter was passed in. This should allow nullfs mounts to be NFS exported. PR: kern/87906 MFC after: 1 week --- sys/fs/nullfs/null_vfsops.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'sys/fs/nullfs') diff --git a/sys/fs/nullfs/null_vfsops.c b/sys/fs/nullfs/null_vfsops.c index 1ba5c6e..c291fa8 100644 --- a/sys/fs/nullfs/null_vfsops.c +++ b/sys/fs/nullfs/null_vfsops.c @@ -89,8 +89,13 @@ nullfs_mount(struct mount *mp, struct thread *td) * Update is a no-op */ if (mp->mnt_flag & MNT_UPDATE) { - return (EOPNOTSUPP); - /* return VFS_MOUNT(MOUNTTONULLMOUNT(mp)->nullm_vfs, path, data, ndp, td);*/ + /* + * Only support update mounts for NFS export. + */ + if (vfs_flagopt(mp->mnt_optnew, "export", NULL, 0)) + return (0); + else + return (EOPNOTSUPP); } /* -- cgit v1.1