Skip to content

Commit 2c2acd2

Browse files
Christoph HellwigAl Viro
authored andcommitted
ntfs: fix bogus __mark_inode_dirty(I_DIRTY_SYNC | I_DIRTY_DATASYNC) call
I_DIRTY_DATASYNC is a strict superset of I_DIRTY_SYNC semantics, as in mark dirty to be written out by fdatasync as well. So dirtying for both flags makes no sense. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
1 parent 937d330 commit 2c2acd2

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎fs/ntfs/mft.c‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -381,7 +381,7 @@ MFT_RECORD *map_extent_mft_record(ntfs_inode *base_ni, MFT_REF mref,
381381
* vfs inode dirty. This ensures that any changes to the mft record are
382382
* written out to disk.
383383
*
384-
* NOTE: We only set I_DIRTY_SYNC and I_DIRTY_DATASYNC (and not I_DIRTY_PAGES)
384+
* NOTE: We only set I_DIRTY_DATASYNC (and not I_DIRTY_PAGES)
385385
* on the base vfs inode, because even though file data may have been modified,
386386
* it is dirty in the inode meta data rather than the data page cache of the
387387
* inode, and thus there are no data pages that need writing out. Therefore, a
@@ -407,7 +407,7 @@ void __mark_mft_record_dirty(ntfs_inode *ni)
407407
else
408408
base_ni = ni->ext.base_ntfs_ino;
409409
mutex_unlock(&ni->extent_lock);
410-
__mark_inode_dirty(VFS_I(base_ni), I_DIRTY_SYNC | I_DIRTY_DATASYNC);
410+
__mark_inode_dirty(VFS_I(base_ni), I_DIRTY_DATASYNC);
411411
}
412412

413413
static const char *ntfs_please_email = "Please email "

0 commit comments

Comments
 (0)