
From: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>

MSDOS doesn't have atime, so this sets MS_NOATIME to msdos in order that we
don't get unnecessary writes.

Signed-off-by: Werner Almesberger <werner@almesberger.net>
Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Signed-off-by: Andrew Morton <akpm@osdl.org>
---

 25-akpm/fs/fat/inode.c   |    3 ++-
 25-akpm/fs/msdos/namei.c |    1 +
 2 files changed, 3 insertions(+), 1 deletion(-)

diff -puN fs/fat/inode.c~fat-set-ms_noatime-to-msdos fs/fat/inode.c
--- 25/fs/fat/inode.c~fat-set-ms_noatime-to-msdos	2005-03-21 21:54:39.000000000 -0800
+++ 25-akpm/fs/fat/inode.c	2005-03-21 21:54:39.000000000 -0800
@@ -431,7 +431,8 @@ static void __exit fat_destroy_inodecach
 
 static int fat_remount(struct super_block *sb, int *flags, char *data)
 {
-	*flags |= MS_NODIRATIME;
+	struct msdos_sb_info *sbi = MSDOS_SB(sb);
+	*flags |= MS_NODIRATIME | (sbi->options.isvfat ? 0 : MS_NOATIME);
 	return 0;
 }
 
diff -puN fs/msdos/namei.c~fat-set-ms_noatime-to-msdos fs/msdos/namei.c
--- 25/fs/msdos/namei.c~fat-set-ms_noatime-to-msdos	2005-03-21 21:54:39.000000000 -0800
+++ 25-akpm/fs/msdos/namei.c	2005-03-21 21:54:39.000000000 -0800
@@ -671,6 +671,7 @@ static int msdos_fill_super(struct super
 	if (res)
 		return res;
 
+	sb->s_flags |= MS_NOATIME;
 	sb->s_root->d_op = &msdos_dentry_operations;
 	return 0;
 }
_
