Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 128871
b: refs/heads/master
c: 3ce7e67
h: refs/heads/master
i:
  128869: ebb8685
  128867: bda85e5
  128863: 5551b29
v: v3
  • Loading branch information
Chris Mason committed Sep 25, 2008
1 parent d6797e5 commit f1d875e
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 32 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 61b4944018449003ac5f9757f4d125dce519cf51
refs/heads/master: 3ce7e67a069b919be774a341b82fc20978b7f69d
10 changes: 1 addition & 9 deletions trunk/fs/btrfs/file.c
Original file line number Diff line number Diff line change
Expand Up @@ -380,15 +380,7 @@ int btrfs_drop_extent_cache(struct inode *inode, u64 start, u64 end)
spin_unlock(&em_tree->lock);
break;
}
if (test_bit(EXTENT_FLAG_PINNED, &em->flags)) {
printk(KERN_CRIT "inode %lu trying to drop pinned "
"extent start %llu end %llu, em [%llu %llu]\n",
inode->i_ino,
(unsigned long long)start,
(unsigned long long)end,
(unsigned long long)em->start,
(unsigned long long)em->len);
}
clear_bit(EXTENT_FLAG_PINNED, &em->flags);
remove_extent_mapping(em_tree, em);

if (em->block_start < EXTENT_MAP_LAST_BYTE &&
Expand Down
22 changes: 0 additions & 22 deletions trunk/fs/btrfs/inode.c
Original file line number Diff line number Diff line change
Expand Up @@ -505,15 +505,9 @@ static int btrfs_finish_ordered_io(struct inode *inode, u64 start, u64 end)
struct btrfs_trans_handle *trans;
struct btrfs_ordered_extent *ordered_extent;
struct extent_io_tree *io_tree = &BTRFS_I(inode)->io_tree;
struct extent_map_tree *em_tree = &BTRFS_I(inode)->extent_tree;
struct extent_map *em;
struct extent_map *em_orig;
u64 alloc_hint = 0;
u64 clear_start;
u64 clear_end;
struct list_head list;
struct btrfs_key ins;
struct rb_node *rb;
int ret;

ret = btrfs_dec_test_ordered_pending(inode, start, end - start + 1);
Expand Down Expand Up @@ -542,22 +536,6 @@ static int btrfs_finish_ordered_io(struct inode *inode, u64 start, u64 end)

mutex_lock(&BTRFS_I(inode)->extent_mutex);

spin_lock(&em_tree->lock);
clear_start = ordered_extent->file_offset;
clear_end = ordered_extent->file_offset + ordered_extent->len;
em = lookup_extent_mapping(em_tree, clear_start,
ordered_extent->len);
em_orig = em;
while(em && clear_start < extent_map_end(em) && clear_end > em->start) {
clear_bit(EXTENT_FLAG_PINNED, &em->flags);
rb = rb_next(&em->rb_node);
if (!rb)
break;
em = rb_entry(rb, struct extent_map, rb_node);
}
free_extent_map(em_orig);
spin_unlock(&em_tree->lock);

ret = btrfs_drop_extents(trans, root, inode,
ordered_extent->file_offset,
ordered_extent->file_offset +
Expand Down

0 comments on commit f1d875e

Please sign in to comment.