diff options
author | Josef Bacik <jbacik@fb.com> | 2015-09-23 23:11:16 +0200 |
---|---|---|
committer | Chris Mason <clm@fb.com> | 2015-10-22 03:51:44 +0200 |
commit | 0b670dc44c91bd1e5fac15b5ac4c98c8bd255ca2 (patch) | |
tree | e0215055573cac5f67c6f6c5a515efdceb60bb07 /fs/kernfs | |
parent | Btrfs: add fragment=* debug mount option (diff) | |
download | linux-0b670dc44c91bd1e5fac15b5ac4c98c8bd255ca2.tar.xz linux-0b670dc44c91bd1e5fac15b5ac4c98c8bd255ca2.zip |
Btrfs: fix prealloc under heavy fragmentation conditions
If we are heavily fragmented we will continually try to prealloc the largest
extent size we can every time we call btrfs_reserve_extent. This can be very
expensive when we are heavily fragmented, burning lots of CPU cycles and loops
through the allocator. So instead notice when we get a smaller chunk from the
allocator than what we specified and use this as the new maximum size we try to
allocate. Thanks,
Signed-off-by: Josef Bacik <jbacik@fb.com>
Signed-off-by: Chris Mason <clm@fb.com>
Diffstat (limited to 'fs/kernfs')
0 files changed, 0 insertions, 0 deletions