]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
Btrfs: relax the block group size limit for bitmaps
authorJosef Bacik <jbacik@fusionio.com>
Tue, 12 Feb 2013 19:07:51 +0000 (14:07 -0500)
committerJosef Bacik <jbacik@fusionio.com>
Wed, 20 Feb 2013 17:59:55 +0000 (12:59 -0500)
commitdde5740fdd6175fc95aecf4ccc7856fbbad9b44e
tree19d3c394b5d8268fee1984b53fa68f170acf013c
parent3e39cea61c4ecb5774c08f3e30507fdd58c1cca9
Btrfs: relax the block group size limit for bitmaps

Dave pointed out that xfstests 273 will tell you that it failed to load the
space cache for a block group when it remounts.  This is because we run out
of space writing out the block group cache.  This is ok and is working as it
should, but let's try to be a bit nicer.  This happens because the block
group was 100mb, but bitmap entries cover 128mb, so we were only getting
extent entries for this block group, which ended up being too many to fit in
the free space cache.  So relax the bitmap size requirements to block groups
that are at least half the size a bitmap will cover or larger, that way we
can still keep the amount of space used in the free space cache low enough
to be able to write it out.  With this patch I no longer fail to write out
the free space cache.  Thanks,

Reported-by: David Sterba <dsterba@suse.cz>
Signed-off-by: Josef Bacik <jbacik@fusionio.com>
fs/btrfs/free-space-cache.c