aboutsummaryrefslogtreecommitdiffstats
path: root/fs/namespace.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/namespace.c')
-rw-r--r--fs/namespace.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/fs/namespace.c b/fs/namespace.c
index f0e353f5bc30..8bc15b362d23 100644
--- a/fs/namespace.c
+++ b/fs/namespace.c
@@ -16,6 +16,7 @@
16#include <linux/init.h> 16#include <linux/init.h>
17#include <linux/quotaops.h> 17#include <linux/quotaops.h>
18#include <linux/acct.h> 18#include <linux/acct.h>
19#include <linux/capability.h>
19#include <linux/module.h> 20#include <linux/module.h>
20#include <linux/seq_file.h> 21#include <linux/seq_file.h>
21#include <linux/namespace.h> 22#include <linux/namespace.h>
@@ -355,14 +356,14 @@ static int show_vfsmnt(struct seq_file *m, void *v)
355 { MS_SYNCHRONOUS, ",sync" }, 356 { MS_SYNCHRONOUS, ",sync" },
356 { MS_DIRSYNC, ",dirsync" }, 357 { MS_DIRSYNC, ",dirsync" },
357 { MS_MANDLOCK, ",mand" }, 358 { MS_MANDLOCK, ",mand" },
358 { MS_NOATIME, ",noatime" },
359 { MS_NODIRATIME, ",nodiratime" },
360 { 0, NULL } 359 { 0, NULL }
361 }; 360 };
362 static struct proc_fs_info mnt_info[] = { 361 static struct proc_fs_info mnt_info[] = {
363 { MNT_NOSUID, ",nosuid" }, 362 { MNT_NOSUID, ",nosuid" },
364 { MNT_NODEV, ",nodev" }, 363 { MNT_NODEV, ",nodev" },
365 { MNT_NOEXEC, ",noexec" }, 364 { MNT_NOEXEC, ",noexec" },
365 { MNT_NOATIME, ",noatime" },
366 { MNT_NODIRATIME, ",nodiratime" },
366 { 0, NULL } 367 { 0, NULL }
367 }; 368 };
368 struct proc_fs_info *fs_infop; 369 struct proc_fs_info *fs_infop;
@@ -1286,7 +1287,13 @@ long do_mount(char *dev_name, char *dir_name, char *type_page,
1286 mnt_flags |= MNT_NODEV; 1287 mnt_flags |= MNT_NODEV;
1287 if (flags & MS_NOEXEC) 1288 if (flags & MS_NOEXEC)
1288 mnt_flags |= MNT_NOEXEC; 1289 mnt_flags |= MNT_NOEXEC;
1289 flags &= ~(MS_NOSUID | MS_NOEXEC | MS_NODEV | MS_ACTIVE); 1290 if (flags & MS_NOATIME)
1291 mnt_flags |= MNT_NOATIME;
1292 if (flags & MS_NODIRATIME)
1293 mnt_flags |= MNT_NODIRATIME;
1294
1295 flags &= ~(MS_NOSUID | MS_NOEXEC | MS_NODEV | MS_ACTIVE |
1296 MS_NOATIME | MS_NODIRATIME);
1290 1297
1291 /* ... and get the mountpoint */ 1298 /* ... and get the mountpoint */
1292 retval = path_lookup(dir_name, LOOKUP_FOLLOW, &nd); 1299 retval = path_lookup(dir_name, LOOKUP_FOLLOW, &nd);