summaryrefslogtreecommitdiffstats
path: root/sbin/mdmfs
diff options
context:
space:
mode:
authorrwatson <rwatson@FreeBSD.org>2004-02-26 01:15:47 +0000
committerrwatson <rwatson@FreeBSD.org>2004-02-26 01:15:47 +0000
commit2a43e75b09b574b2cc87bbe6770234cb8dfd8c10 (patch)
tree9b3aee90bd59c1b25faf06613150c9106dd00909 /sbin/mdmfs
parentf0df387d8416e8fa18a3e6e923a4b45b5e8771d4 (diff)
downloadFreeBSD-src-2a43e75b09b574b2cc87bbe6770234cb8dfd8c10.zip
FreeBSD-src-2a43e75b09b574b2cc87bbe6770234cb8dfd8c10.tar.gz
Add a "-l" parameter to mdmfs so that memory file systems can be
created with the multilabel flag from inception. This simply passes the "-l" flag on to newfs(8). Obtained from: TrustedBSD Project Sponsored by: DARPA, McAfee Research
Diffstat (limited to 'sbin/mdmfs')
-rw-r--r--sbin/mdmfs/mdmfs.83
-rw-r--r--sbin/mdmfs/mdmfs.c5
2 files changed, 7 insertions, 1 deletions
diff --git a/sbin/mdmfs/mdmfs.8 b/sbin/mdmfs/mdmfs.8
index daf66c2..8c8c9a0 100644
--- a/sbin/mdmfs/mdmfs.8
+++ b/sbin/mdmfs/mdmfs.8
@@ -45,6 +45,7 @@ driver
.Op Fl F Ar file
.Op Fl f Ar frag-size
.Op Fl i Ar bytes
+.Op Fl l
.Op Fl m Ar percent-free
.Op Fl n Ar rotational-positions
.Op Fl O Ar optimization
@@ -162,6 +163,8 @@ memory disk backed by
The fragment size of the file system in bytes.
.It Fl i Ar bytes
Number of bytes per inode.
+.It Fl l
+Enables multilabel MAC on the new file system.
.It Fl L
Show the output of the helper programs.
By default,
diff --git a/sbin/mdmfs/mdmfs.c b/sbin/mdmfs/mdmfs.c
index ff4d41d..2000f3e 100644
--- a/sbin/mdmfs/mdmfs.c
+++ b/sbin/mdmfs/mdmfs.c
@@ -119,7 +119,7 @@ main(int argc, char **argv)
compat = true;
while ((ch = getopt(argc, argv,
- "a:b:Cc:Dd:e:F:f:hi:LMm:Nn:O:o:p:Ss:t:Uv:w:X")) != -1)
+ "a:b:Cc:Dd:e:F:f:hi:LlMm:Nn:O:o:p:Ss:t:Uv:w:X")) != -1)
switch (ch) {
case 'a':
argappend(&newfs_arg, "-a %s", optarg);
@@ -167,6 +167,9 @@ main(int argc, char **argv)
usage();
loudsubs = true;
break;
+ case 'l':
+ argappend(&newfs_arg, "-l");
+ break;
case 'M':
if (have_mdtype)
usage();
OpenPOWER on IntegriCloud