btrfs: derive maximum output size in the compression implementation
The value of max_out can be calculated from the parameters passed to the
compressors, which is number of pages and the page size, and we don't
have to needlessly pass it around.
Signed-off-by: David Sterba <dsterba@suse.com>
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c
index 11a4eea..0d932b9 100644
--- a/fs/btrfs/inode.c
+++ b/fs/btrfs/inode.c
@@ -510,8 +510,7 @@
pages,
&nr_pages,
&total_in,
- &total_compressed,
- BTRFS_MAX_COMPRESSED);
+ &total_compressed);
if (!ret) {
unsigned long offset = total_compressed &