]> git.baikalelectronics.ru Git - kernel.git/commit
Btrfs: use the global reserve as a backup for deleting inodes
authorJosef Bacik <josef@redhat.com>
Mon, 26 Sep 2011 19:46:06 +0000 (15:46 -0400)
committerJosef Bacik <josef@redhat.com>
Wed, 19 Oct 2011 19:12:48 +0000 (15:12 -0400)
commitc4f1879701704c3a0d9c1a8ba42db2ca03322e79
tree5b2c95df5854b5b5829ce5f88e3e807eb4bc8d4a
parent875b2bfdf31bd0bfac0c908db0c63f1b368f4f5a
Btrfs: use the global reserve as a backup for deleting inodes

Xfstests 83 really stresses our ENOSPC since it uses a 100mb fs which ends up
with the mixed block group stuff.  Because of this we can run into a situation
where we don't have enough space to delete inodes, or even worse we can't free
the inodes when we next mount the fs which causes the orphan code to lose its
mind.  So if we fail to make our reservation, steal from the global reserve.
The global reserve will end up taking up the entire rest of the free space on
the fs in this worst case so there really is no other option.  With this patch
test 83 doesn't freak out.  Thanks,

Signed-off-by: Josef Bacik <josef@redhat.com>
fs/btrfs/inode.c