Commit 24a44dca authored by Christoph Hellwig's avatar Christoph Hellwig Committed by Linus Torvalds

[PATCH] ntfs: remove superflous MS_NOATIME/MS_NODIRATIME assignments

MS_RDONLU implies not atime updates at all, no need for the MS_NOATIME and
MS_NODIRATIME flags.
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Cc: Anton Altaparmakov <aia21@cantab.net>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent e6a6d2ef
...@@ -443,8 +443,8 @@ static int ntfs_remount(struct super_block *sb, int *flags, char *opt) ...@@ -443,8 +443,8 @@ static int ntfs_remount(struct super_block *sb, int *flags, char *opt)
ntfs_debug("Entering with remount options string: %s", opt); ntfs_debug("Entering with remount options string: %s", opt);
#ifndef NTFS_RW #ifndef NTFS_RW
/* For read-only compiled driver, enforce all read-only flags. */ /* For read-only compiled driver, enforce read-only flag. */
*flags |= MS_RDONLY | MS_NOATIME | MS_NODIRATIME; *flags |= MS_RDONLY;
#else /* NTFS_RW */ #else /* NTFS_RW */
/* /*
* For the read-write compiled driver, if we are remounting read-write, * For the read-write compiled driver, if we are remounting read-write,
...@@ -1721,7 +1721,7 @@ static BOOL load_system_files(ntfs_volume *vol) ...@@ -1721,7 +1721,7 @@ static BOOL load_system_files(ntfs_volume *vol)
es3); es3);
goto iput_mirr_err_out; goto iput_mirr_err_out;
} }
sb->s_flags |= MS_RDONLY | MS_NOATIME | MS_NODIRATIME; sb->s_flags |= MS_RDONLY;
ntfs_error(sb, "%s. Mounting read-only%s", ntfs_error(sb, "%s. Mounting read-only%s",
!vol->mftmirr_ino ? es1 : es2, es3); !vol->mftmirr_ino ? es1 : es2, es3);
} else } else
...@@ -1837,7 +1837,7 @@ get_ctx_vol_failed: ...@@ -1837,7 +1837,7 @@ get_ctx_vol_failed:
es1, es2); es1, es2);
goto iput_vol_err_out; goto iput_vol_err_out;
} }
sb->s_flags |= MS_RDONLY | MS_NOATIME | MS_NODIRATIME; sb->s_flags |= MS_RDONLY;
ntfs_error(sb, "%s. Mounting read-only%s", es1, es2); ntfs_error(sb, "%s. Mounting read-only%s", es1, es2);
} else } else
ntfs_warning(sb, "%s. Will not be able to remount " ntfs_warning(sb, "%s. Will not be able to remount "
...@@ -1874,7 +1874,7 @@ get_ctx_vol_failed: ...@@ -1874,7 +1874,7 @@ get_ctx_vol_failed:
} }
goto iput_logfile_err_out; goto iput_logfile_err_out;
} }
sb->s_flags |= MS_RDONLY | MS_NOATIME | MS_NODIRATIME; sb->s_flags |= MS_RDONLY;
ntfs_error(sb, "%s. Mounting read-only%s", es1, es2); ntfs_error(sb, "%s. Mounting read-only%s", es1, es2);
} else } else
ntfs_warning(sb, "%s. Will not be able to remount " ntfs_warning(sb, "%s. Will not be able to remount "
...@@ -1919,7 +1919,7 @@ get_ctx_vol_failed: ...@@ -1919,7 +1919,7 @@ get_ctx_vol_failed:
es1, es2); es1, es2);
goto iput_root_err_out; goto iput_root_err_out;
} }
sb->s_flags |= MS_RDONLY | MS_NOATIME | MS_NODIRATIME; sb->s_flags |= MS_RDONLY;
ntfs_error(sb, "%s. Mounting read-only%s", es1, es2); ntfs_error(sb, "%s. Mounting read-only%s", es1, es2);
} else } else
ntfs_warning(sb, "%s. Will not be able to remount " ntfs_warning(sb, "%s. Will not be able to remount "
...@@ -1943,7 +1943,7 @@ get_ctx_vol_failed: ...@@ -1943,7 +1943,7 @@ get_ctx_vol_failed:
goto iput_root_err_out; goto iput_root_err_out;
} }
ntfs_error(sb, "%s. Mounting read-only%s", es1, es2); ntfs_error(sb, "%s. Mounting read-only%s", es1, es2);
sb->s_flags |= MS_RDONLY | MS_NOATIME | MS_NODIRATIME; sb->s_flags |= MS_RDONLY;
/* /*
* Do not set NVolErrors() because ntfs_remount() might manage * Do not set NVolErrors() because ntfs_remount() might manage
* to set the dirty flag in which case all would be well. * to set the dirty flag in which case all would be well.
...@@ -1970,7 +1970,7 @@ get_ctx_vol_failed: ...@@ -1970,7 +1970,7 @@ get_ctx_vol_failed:
goto iput_root_err_out; goto iput_root_err_out;
} }
ntfs_error(sb, "%s. Mounting read-only%s", es1, es2); ntfs_error(sb, "%s. Mounting read-only%s", es1, es2);
sb->s_flags |= MS_RDONLY | MS_NOATIME | MS_NODIRATIME; sb->s_flags |= MS_RDONLY;
NVolSetErrors(vol); NVolSetErrors(vol);
} }
#endif #endif
...@@ -1989,7 +1989,7 @@ get_ctx_vol_failed: ...@@ -1989,7 +1989,7 @@ get_ctx_vol_failed:
goto iput_root_err_out; goto iput_root_err_out;
} }
ntfs_error(sb, "%s. Mounting read-only%s", es1, es2); ntfs_error(sb, "%s. Mounting read-only%s", es1, es2);
sb->s_flags |= MS_RDONLY | MS_NOATIME | MS_NODIRATIME; sb->s_flags |= MS_RDONLY;
NVolSetErrors(vol); NVolSetErrors(vol);
} }
#endif /* NTFS_RW */ #endif /* NTFS_RW */
...@@ -2030,7 +2030,7 @@ get_ctx_vol_failed: ...@@ -2030,7 +2030,7 @@ get_ctx_vol_failed:
es1, es2); es1, es2);
goto iput_quota_err_out; goto iput_quota_err_out;
} }
sb->s_flags |= MS_RDONLY | MS_NOATIME | MS_NODIRATIME; sb->s_flags |= MS_RDONLY;
ntfs_error(sb, "%s. Mounting read-only%s", es1, es2); ntfs_error(sb, "%s. Mounting read-only%s", es1, es2);
} else } else
ntfs_warning(sb, "%s. Will not be able to remount " ntfs_warning(sb, "%s. Will not be able to remount "
...@@ -2053,7 +2053,7 @@ get_ctx_vol_failed: ...@@ -2053,7 +2053,7 @@ get_ctx_vol_failed:
goto iput_quota_err_out; goto iput_quota_err_out;
} }
ntfs_error(sb, "%s. Mounting read-only%s", es1, es2); ntfs_error(sb, "%s. Mounting read-only%s", es1, es2);
sb->s_flags |= MS_RDONLY | MS_NOATIME | MS_NODIRATIME; sb->s_flags |= MS_RDONLY;
NVolSetErrors(vol); NVolSetErrors(vol);
} }
/* /*
...@@ -2074,7 +2074,7 @@ get_ctx_vol_failed: ...@@ -2074,7 +2074,7 @@ get_ctx_vol_failed:
es1, es2); es1, es2);
goto iput_usnjrnl_err_out; goto iput_usnjrnl_err_out;
} }
sb->s_flags |= MS_RDONLY | MS_NOATIME | MS_NODIRATIME; sb->s_flags |= MS_RDONLY;
ntfs_error(sb, "%s. Mounting read-only%s", es1, es2); ntfs_error(sb, "%s. Mounting read-only%s", es1, es2);
} else } else
ntfs_warning(sb, "%s. Will not be able to remount " ntfs_warning(sb, "%s. Will not be able to remount "
...@@ -2097,7 +2097,7 @@ get_ctx_vol_failed: ...@@ -2097,7 +2097,7 @@ get_ctx_vol_failed:
goto iput_usnjrnl_err_out; goto iput_usnjrnl_err_out;
} }
ntfs_error(sb, "%s. Mounting read-only%s", es1, es2); ntfs_error(sb, "%s. Mounting read-only%s", es1, es2);
sb->s_flags |= MS_RDONLY | MS_NOATIME | MS_NODIRATIME; sb->s_flags |= MS_RDONLY;
NVolSetErrors(vol); NVolSetErrors(vol);
} }
#endif /* NTFS_RW */ #endif /* NTFS_RW */
...@@ -2689,7 +2689,7 @@ static int ntfs_fill_super(struct super_block *sb, void *opt, const int silent) ...@@ -2689,7 +2689,7 @@ static int ntfs_fill_super(struct super_block *sb, void *opt, const int silent)
ntfs_debug("Entering."); ntfs_debug("Entering.");
#ifndef NTFS_RW #ifndef NTFS_RW
sb->s_flags |= MS_RDONLY | MS_NOATIME | MS_NODIRATIME; sb->s_flags |= MS_RDONLY;
#endif /* ! NTFS_RW */ #endif /* ! NTFS_RW */
/* Allocate a new ntfs_volume and place it in sb->s_fs_info. */ /* Allocate a new ntfs_volume and place it in sb->s_fs_info. */
sb->s_fs_info = kmalloc(sizeof(ntfs_volume), GFP_NOFS); sb->s_fs_info = kmalloc(sizeof(ntfs_volume), GFP_NOFS);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment