|
@@ -3526,8 +3526,10 @@ next_slot:
|
|
|
struct extent_map_tree *tree = &BTRFS_I(inode)->extent_tree;
|
|
|
struct extent_map *em, *n;
|
|
|
|
|
|
+ write_lock(&tree->lock);
|
|
|
list_for_each_entry_safe(em, n, &tree->modified_extents, list)
|
|
|
list_del_init(&em->list);
|
|
|
+ write_unlock(&tree->lock);
|
|
|
}
|
|
|
|
|
|
if (inode_only == LOG_INODE_ALL && S_ISDIR(inode->i_mode)) {
|