aboutsummaryrefslogtreecommitdiffstats
path: root/fs/namespace.c
diff options
context:
space:
mode:
authorMatthew Garrett <mjg@redhat.com>2009-03-26 13:53:14 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2009-03-26 14:01:10 -0400
commit0a1c01c9477602ee8b44548a9405b2c1d587b5a2 (patch)
tree4f9f77b34bf1f2f497a8f99b8976599a6b2be8cc /fs/namespace.c
parentd0adde574b8487ef30f69e2d08bba769e4be513f (diff)
Make relatime default
Change the default behaviour of the kernel to use relatime for all filesystems. This can be overridden with the "strictatime" mount option. Signed-off-by: Matthew Garrett <mjg@redhat.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/namespace.c')
-rw-r--r--fs/namespace.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/fs/namespace.c b/fs/namespace.c
index d0659ec291c9..f0e753097353 100644
--- a/fs/namespace.c
+++ b/fs/namespace.c
@@ -1920,6 +1920,9 @@ long do_mount(char *dev_name, char *dir_name, char *type_page,
1920 if (data_page) 1920 if (data_page)
1921 ((char *)data_page)[PAGE_SIZE - 1] = 0; 1921 ((char *)data_page)[PAGE_SIZE - 1] = 0;
1922 1922
1923 /* Default to relatime */
1924 mnt_flags |= MNT_RELATIME;
1925
1923 /* Separate the per-mountpoint flags */ 1926 /* Separate the per-mountpoint flags */
1924 if (flags & MS_NOSUID) 1927 if (flags & MS_NOSUID)
1925 mnt_flags |= MNT_NOSUID; 1928 mnt_flags |= MNT_NOSUID;
@@ -1931,8 +1934,6 @@ long do_mount(char *dev_name, char *dir_name, char *type_page,
1931 mnt_flags |= MNT_NOATIME; 1934 mnt_flags |= MNT_NOATIME;
1932 if (flags & MS_NODIRATIME) 1935 if (flags & MS_NODIRATIME)
1933 mnt_flags |= MNT_NODIRATIME; 1936 mnt_flags |= MNT_NODIRATIME;
1934 if (flags & MS_RELATIME)
1935 mnt_flags |= MNT_RELATIME;
1936 if (flags & MS_STRICTATIME) 1937 if (flags & MS_STRICTATIME)
1937 mnt_flags &= ~(MNT_RELATIME | MNT_NOATIME); 1938 mnt_flags &= ~(MNT_RELATIME | MNT_NOATIME);
1938 if (flags & MS_RDONLY) 1939 if (flags & MS_RDONLY)