summaryrefslogtreecommitdiffstats
path: root/fs/autofs4/dev-ioctl.c
diff options
context:
space:
mode:
authorLi Zefan <lizf@cn.fujitsu.com>2011-09-02 15:57:07 +0800
committerDavid Sterba <dsterba@suse.cz>2011-10-20 18:10:39 +0200
commit008873eafbc77deb1702aedece33756c58486c6a (patch)
tree2b578bfdb47f8351f33d8ebf29714d4f2e4b15f6 /fs/autofs4/dev-ioctl.c
parent83c8c9bde0add721f7509aa446455183b040b931 (diff)
downloadlinux-008873eafbc77deb1702aedece33756c58486c6a.tar.bz2
Btrfs: honor extent thresh during defragmentation
We won't defrag an extent, if it's bigger than the threshold we specified and there's no small extent before it, but actually the code doesn't work this way. There are three bugs: - When should_defrag_range() decides we should keep on defragmenting an extent, last_len is not incremented. (old bug) - The length that passes to should_defrag_range() is not the length we're going to defrag. (new bug) - We always defrag 256K bytes data, and a big extent can be part of this range. (new bug) For a file with 4 extents: | 4K | 4K | 256K | 256K | The result of defrag with (the default) 256K extent thresh should be: | 264K | 256K | but with those bugs, we'll get: | 520K | Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
Diffstat (limited to 'fs/autofs4/dev-ioctl.c')
0 files changed, 0 insertions, 0 deletions