diff options
| -rw-r--r-- | fs/btrfs/inode.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c index 5a5b902e647f..3b957921ba59 100644 --- a/fs/btrfs/inode.c +++ b/fs/btrfs/inode.c | |||
| @@ -7160,7 +7160,7 @@ static int btrfs_get_blocks_direct(struct inode *inode, sector_t iblock, | |||
| 7160 | int ret = 0; | 7160 | int ret = 0; |
| 7161 | 7161 | ||
| 7162 | if (create) | 7162 | if (create) |
| 7163 | unlock_bits |= EXTENT_DELALLOC | EXTENT_DIRTY; | 7163 | unlock_bits |= EXTENT_DIRTY; |
| 7164 | else | 7164 | else |
| 7165 | len = min_t(u64, len, root->sectorsize); | 7165 | len = min_t(u64, len, root->sectorsize); |
| 7166 | 7166 | ||
| @@ -7296,11 +7296,7 @@ unlock: | |||
| 7296 | BTRFS_I(inode)->outstanding_extents++; | 7296 | BTRFS_I(inode)->outstanding_extents++; |
| 7297 | spin_unlock(&BTRFS_I(inode)->lock); | 7297 | spin_unlock(&BTRFS_I(inode)->lock); |
| 7298 | } | 7298 | } |
| 7299 | 7299 | btrfs_free_reserved_data_space(inode, len); | |
| 7300 | ret = set_extent_bit(&BTRFS_I(inode)->io_tree, lockstart, | ||
| 7301 | lockstart + len - 1, EXTENT_DELALLOC, NULL, | ||
| 7302 | &cached_state, GFP_NOFS); | ||
| 7303 | BUG_ON(ret); | ||
| 7304 | } | 7300 | } |
| 7305 | 7301 | ||
| 7306 | /* | 7302 | /* |
