Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 264332
b: refs/heads/master
c: f7f43cc
h: refs/heads/master
v: v3
  • Loading branch information
Chris Mason committed Oct 11, 2011
1 parent 62c59f7 commit 65a9229
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 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: 2a0f7f5769992bae5b3f97157fd80b2b943be485
refs/heads/master: f7f43cc84152e53b5687cd0eb8823310ba065524
4 changes: 3 additions & 1 deletion trunk/fs/btrfs/ioctl.c
Original file line number Diff line number Diff line change
Expand Up @@ -1062,7 +1062,9 @@ int btrfs_defrag_file(struct inode *inode, struct file *file,
if (i < inode->i_mapping->writeback_index)
inode->i_mapping->writeback_index = i;

while (i <= last_index && defrag_count < max_to_defrag) {
while (i <= last_index && defrag_count < max_to_defrag &&
(i < (i_size_read(inode) + PAGE_CACHE_SIZE - 1) >>
PAGE_CACHE_SHIFT)) {
/*
* make sure we stop running if someone unmounts
* the FS
Expand Down

0 comments on commit 65a9229

Please sign in to comment.