|
@@ -2703,6 +2703,10 @@ static int btrfs_finish_ordered_io(struct btrfs_ordered_extent *ordered_extent)
|
|
goto out;
|
|
goto out;
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ btrfs_free_io_failure_record(inode, ordered_extent->file_offset,
|
|
|
|
+ ordered_extent->file_offset +
|
|
|
|
+ ordered_extent->len - 1);
|
|
|
|
+
|
|
if (test_bit(BTRFS_ORDERED_TRUNCATED, &ordered_extent->flags)) {
|
|
if (test_bit(BTRFS_ORDERED_TRUNCATED, &ordered_extent->flags)) {
|
|
truncated = true;
|
|
truncated = true;
|
|
logical_len = ordered_extent->truncated_len;
|
|
logical_len = ordered_extent->truncated_len;
|
|
@@ -4799,6 +4803,8 @@ void btrfs_evict_inode(struct inode *inode)
|
|
/* do we really want it for ->i_nlink > 0 and zero btrfs_root_refs? */
|
|
/* do we really want it for ->i_nlink > 0 and zero btrfs_root_refs? */
|
|
btrfs_wait_ordered_range(inode, 0, (u64)-1);
|
|
btrfs_wait_ordered_range(inode, 0, (u64)-1);
|
|
|
|
|
|
|
|
+ btrfs_free_io_failure_record(inode, 0, (u64)-1);
|
|
|
|
+
|
|
if (root->fs_info->log_root_recovering) {
|
|
if (root->fs_info->log_root_recovering) {
|
|
BUG_ON(test_bit(BTRFS_INODE_HAS_ORPHAN_ITEM,
|
|
BUG_ON(test_bit(BTRFS_INODE_HAS_ORPHAN_ITEM,
|
|
&BTRFS_I(inode)->runtime_flags));
|
|
&BTRFS_I(inode)->runtime_flags));
|