Skip to content

Commit

Permalink
btrfs: drop unused parameter level from alloc_heuristic_ws()
Browse files Browse the repository at this point in the history
The compression heuristic pass does not need a level, so we can drop the
parameter.

Reviewed-by: Anand Jain <anand.jain@oracle.com>
Signed-off-by: David Sterba <dsterba@suse.com>
  • Loading branch information
kdave committed Nov 11, 2024
1 parent 8c7cd2b commit a9c50c9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions fs/btrfs/compression.c
Original file line number Diff line number Diff line change
Expand Up @@ -702,7 +702,7 @@ static void free_heuristic_ws(struct list_head *ws)
kfree(workspace);
}

static struct list_head *alloc_heuristic_ws(unsigned int level)
static struct list_head *alloc_heuristic_ws(void)
{
struct heuristic_ws *ws;

Expand Down Expand Up @@ -744,7 +744,7 @@ static const struct btrfs_compress_op * const btrfs_compress_op[] = {
static struct list_head *alloc_workspace(int type, unsigned int level)
{
switch (type) {
case BTRFS_COMPRESS_NONE: return alloc_heuristic_ws(level);
case BTRFS_COMPRESS_NONE: return alloc_heuristic_ws();
case BTRFS_COMPRESS_ZLIB: return zlib_alloc_workspace(level);
case BTRFS_COMPRESS_LZO: return lzo_alloc_workspace();
case BTRFS_COMPRESS_ZSTD: return zstd_alloc_workspace(level);
Expand Down

0 comments on commit a9c50c9

Please sign in to comment.