Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 147767
b: refs/heads/master
c: 585ad2c
h: refs/heads/master
i:
  147765: fd0ce37
  147763: ca72d3e
  147759: 38654aa
v: v3
  • Loading branch information
Chris Mason committed Jun 10, 2009
1 parent 0a2c4f8 commit f241b75
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 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: 2c943de6ad795a174dcc424c293bb77f15ae3b8c
refs/heads/master: 585ad2c3797dcaa643aeba75b9f072778adf3490
7 changes: 2 additions & 5 deletions trunk/fs/btrfs/disk-io.c
Original file line number Diff line number Diff line change
Expand Up @@ -2378,17 +2378,14 @@ void btrfs_btree_balance_dirty(struct btrfs_root *root, unsigned long nr)
* looks as though older kernels can get into trouble with
* this code, they end up stuck in balance_dirty_pages forever
*/
struct extent_io_tree *tree;
u64 num_dirty;
u64 start = 0;
unsigned long thresh = 32 * 1024 * 1024;
tree = &BTRFS_I(root->fs_info->btree_inode)->io_tree;

if (current->flags & PF_MEMALLOC)
return;

num_dirty = count_range_bits(tree, &start, (u64)-1,
thresh, EXTENT_DIRTY);
num_dirty = root->fs_info->dirty_metadata_bytes;

if (num_dirty > thresh) {
balance_dirty_pages_ratelimited_nr(
root->fs_info->btree_inode->i_mapping, 1);
Expand Down

0 comments on commit f241b75

Please sign in to comment.