aboutsummaryrefslogtreecommitdiffstats
path: root/fs/btrfs/extent-tree.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/btrfs/extent-tree.c')
-rw-r--r--fs/btrfs/extent-tree.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c
index c86f0e6152f2..9583a9ae8b79 100644
--- a/fs/btrfs/extent-tree.c
+++ b/fs/btrfs/extent-tree.c
@@ -168,9 +168,10 @@ static int pin_down_block(struct btrfs_root *root, u64 blocknr, int tag)
168 BUG_ON(!bh); 168 BUG_ON(!bh);
169 err = radix_tree_insert(&root->fs_info->pinned_radix, 169 err = radix_tree_insert(&root->fs_info->pinned_radix,
170 blocknr, bh); 170 blocknr, bh);
171 BUG_ON(err); 171 if (err && err != -EEXIST) {
172 if (err) 172 BUG();
173 return err; 173 return err;
174 }
174 radix_tree_tag_set(&root->fs_info->pinned_radix, blocknr, 175 radix_tree_tag_set(&root->fs_info->pinned_radix, blocknr,
175 tag); 176 tag);
176 return 0; 177 return 0;