commit | 5ca496604b5975d371bb669ee6c2394bcbea818f | [log] [tgz] |
---|---|---|
author | Li Zefan <lizf@cn.fujitsu.com> | Fri Sep 02 15:56:55 2011 +0800 |
committer | David Sterba <dsterba@suse.cz> | Thu Oct 20 18:10:37 2011 +0200 |
tree | 6a99818b0c54b71c706206bf8981e807e2b0a99b | |
parent | 151a31b25e5c941bdd9fdefed650effca223c716 [diff] |
Btrfs: fix wrong max_to_defrag in btrfs_defrag_file() It's off-by-one, and thus we may skip the last page while defragmenting. An example case: # create /mnt/file with 2 4K file extents # btrfs fi defrag /mnt/file # sync # filefrag /mnt/file /mnt/file: 2 extents found So it's not defragmented. Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>