]> asedeno.scripts.mit.edu Git - linux.git/blobdiff - fs/fat/inode.c
Merge tag 'xfs-4.20-merge-2' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux
[linux.git] / fs / fat / inode.c
index 3bf60f19b6d35fd8ee68e197cdf7eb042235c906..c0b5b5c3373bd967f86697f9aa39b75942399877 100644 (file)
@@ -244,7 +244,7 @@ static int fat_write_end(struct file *file, struct address_space *mapping,
        if (err < len)
                fat_write_failed(mapping, pos + len);
        if (!(err < 0) && !(MSDOS_I(inode)->i_attrs & ATTR_ARCH)) {
-               inode->i_mtime = inode->i_ctime = current_time(inode);
+               fat_truncate_time(inode, NULL, S_CTIME|S_MTIME);
                MSDOS_I(inode)->i_attrs |= ATTR_ARCH;
                mark_inode_dirty(inode);
        }
@@ -564,7 +564,7 @@ int fat_fill_inode(struct inode *inode, struct msdos_dir_entry *de)
                                  de->cdate, de->ctime_cs);
                fat_time_fat2unix(sbi, &inode->i_atime, 0, de->adate, 0);
        } else
-               inode->i_ctime = inode->i_atime = inode->i_mtime;
+               fat_truncate_time(inode, &inode->i_mtime, S_ATIME|S_CTIME);
 
        return 0;
 }