Skip to content

Commit d2b2a28

Browse files
Dmitry Monakhovtorvalds
authored andcommitted
dax: dirty inode only if required
Signed-off-by: Dmitry Monakhov <[email protected]> Reviewed-by: Jan Kara <[email protected]> Reviewed-by: Ross Zwisler <[email protected]> Cc: Matthew Wilcox <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
1 parent ae02620 commit d2b2a28

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

fs/dax.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -358,7 +358,8 @@ static int dax_radix_entry(struct address_space *mapping, pgoff_t index,
358358
void *entry;
359359

360360
WARN_ON_ONCE(pmd_entry && !dirty);
361-
__mark_inode_dirty(mapping->host, I_DIRTY_PAGES);
361+
if (dirty)
362+
__mark_inode_dirty(mapping->host, I_DIRTY_PAGES);
362363

363364
spin_lock_irq(&mapping->tree_lock);
364365

0 commit comments

Comments
 (0)