Btrfs: dedupe_file_range ioctl: remove 16MiB restriction
authorTimofey Titovets <nefelim4ag@gmail.com>
Wed, 2 May 2018 05:15:37 +0000 (08:15 +0300)
committerDavid Sterba <dsterba@suse.com>
Mon, 28 May 2018 16:24:04 +0000 (18:24 +0200)
commitb67287682688a60d03e8c2c6d4689ea3a25d5d3c
tree96fc3ed384436982e7b99ed21e83f166218cc0da
parent3973909d926c093fd13d56953e591635d56ab7b6
Btrfs: dedupe_file_range ioctl: remove 16MiB restriction

Currently btrfs_dedupe_file_range silently restricts the dedupe range to
to 16MiB to limit locking and working memory size and is documented in
manual page as implementation specific.

Let's remove that restriction by iterating over the dedup range in 16MiB
steps.  This is backward compatible and will not change anything for
requests smaller then 16MiB.

Signed-off-by: Timofey Titovets <nefelim4ag@gmail.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/ioctl.c