Changeset View
Changeset View
Standalone View
Standalone View
head/sys/ufs/ffs/ffs_vfsops.c
Show First 20 Lines • Show All 139 Lines • ▼ Show 20 Lines | |||||
* Note that userquota and groupquota options are not currently used | * Note that userquota and groupquota options are not currently used | ||||
* by UFS/FFS code and generally mount(8) does not pass those options | * by UFS/FFS code and generally mount(8) does not pass those options | ||||
* from userland, but they can be passed by loader(8) via | * from userland, but they can be passed by loader(8) via | ||||
* vfs.root.mountfrom.options. | * vfs.root.mountfrom.options. | ||||
*/ | */ | ||||
static const char *ffs_opts[] = { "acls", "async", "noatime", "noclusterr", | static const char *ffs_opts[] = { "acls", "async", "noatime", "noclusterr", | ||||
"noclusterw", "noexec", "export", "force", "from", "groupquota", | "noclusterw", "noexec", "export", "force", "from", "groupquota", | ||||
"multilabel", "nfsv4acls", "fsckpid", "snapshot", "nosuid", "suiddir", | "multilabel", "nfsv4acls", "fsckpid", "snapshot", "nosuid", "suiddir", | ||||
"nosymfollow", "sync", "union", "userquota", NULL }; | "nosymfollow", "sync", "union", "userquota", "untrusted", NULL }; | ||||
static int | static int | ||||
ffs_mount(struct mount *mp) | ffs_mount(struct mount *mp) | ||||
{ | { | ||||
struct vnode *devvp; | struct vnode *devvp; | ||||
struct thread *td; | struct thread *td; | ||||
struct ufsmount *ump = NULL; | struct ufsmount *ump = NULL; | ||||
struct fs *fs; | struct fs *fs; | ||||
Show All 22 Lines | ffs_mount(struct mount *mp) | ||||
vfs_deleteopt(mp->mnt_optnew, "groupquota"); | vfs_deleteopt(mp->mnt_optnew, "groupquota"); | ||||
vfs_deleteopt(mp->mnt_optnew, "userquota"); | vfs_deleteopt(mp->mnt_optnew, "userquota"); | ||||
fspec = vfs_getopts(mp->mnt_optnew, "from", &error); | fspec = vfs_getopts(mp->mnt_optnew, "from", &error); | ||||
if (error) | if (error) | ||||
return (error); | return (error); | ||||
mntorflags = 0; | mntorflags = 0; | ||||
if (vfs_getopt(mp->mnt_optnew, "untrusted", NULL, NULL) == 0) | |||||
mntorflags |= MNT_UNTRUSTED; | |||||
if (vfs_getopt(mp->mnt_optnew, "acls", NULL, NULL) == 0) | if (vfs_getopt(mp->mnt_optnew, "acls", NULL, NULL) == 0) | ||||
mntorflags |= MNT_ACLS; | mntorflags |= MNT_ACLS; | ||||
if (vfs_getopt(mp->mnt_optnew, "snapshot", NULL, NULL) == 0) { | if (vfs_getopt(mp->mnt_optnew, "snapshot", NULL, NULL) == 0) { | ||||
mntorflags |= MNT_SNAPSHOT; | mntorflags |= MNT_SNAPSHOT; | ||||
/* | /* | ||||
* Once we have set the MNT_SNAPSHOT flag, do not | * Once we have set the MNT_SNAPSHOT flag, do not | ||||
* persist "snapshot" in the options list. | * persist "snapshot" in the options list. | ||||
▲ Show 20 Lines • Show All 2,153 Lines • Show Last 20 Lines |