dax: dirty inode only if required
Signed-off-by: Dmitry Monakhov <dmonakhov@openvz.org> Reviewed-by: Jan Kara <jack@suse.cz> Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com> Cc: Matthew Wilcox <matthew.r.wilcox@intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
Родитель
ae026204a2
Коммит
d2b2a28e64
1
fs/dax.c
1
fs/dax.c
|
@ -358,6 +358,7 @@ static int dax_radix_entry(struct address_space *mapping, pgoff_t index,
|
||||||
void *entry;
|
void *entry;
|
||||||
|
|
||||||
WARN_ON_ONCE(pmd_entry && !dirty);
|
WARN_ON_ONCE(pmd_entry && !dirty);
|
||||||
|
if (dirty)
|
||||||
__mark_inode_dirty(mapping->host, I_DIRTY_PAGES);
|
__mark_inode_dirty(mapping->host, I_DIRTY_PAGES);
|
||||||
|
|
||||||
spin_lock_irq(&mapping->tree_lock);
|
spin_lock_irq(&mapping->tree_lock);
|
||||||
|
|
Загрузка…
Ссылка в новой задаче