Skip to content

Commit

Permalink
[PATCH] ext4 balloc: reset windowsz when full
Browse files Browse the repository at this point in the history
ext4_new_blocks should reset the reservation window size to 0 when squeezing
the last blocks out of an almost full filesystem, so the retry doesn't skip
any groups with less than half that free, reporting ENOSPC too soon.

Signed-off-by: Mingming Cao <cmm@us.ibm.com>
Signed-off-by: Hugh Dickins <hugh@veritas.com>
Cc: <linux-ext4@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Hugh Dickins authored and Linus Torvalds committed Dec 7, 2006
1 parent 1260392 commit cd16c8f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions fs/ext4/balloc.c
Original file line number Diff line number Diff line change
Expand Up @@ -1566,6 +1566,7 @@ ext4_fsblk_t ext4_new_blocks(handle_t *handle, struct inode *inode,
*/
if (my_rsv) {
my_rsv = NULL;
windowsz = 0;
group_no = goal_group;
goto retry_alloc;
}
Expand Down

0 comments on commit cd16c8f

Please sign in to comment.