From 1e4eb7465438e47cc3718a02d4326dd034f3c0da Mon Sep 17 00:00:00 2001 From: David Sterba Date: Wed, 2 Oct 2019 00:06:15 +0200 Subject: btrfs: switch compression callbacks to direct calls The indirect calls bring some overhead due to spectre vulnerability mitigations. The number of cases is small and below the threshold (10-20) where indirect call would be better. Reviewed-by: Johannes Thumshirn Reviewed-by: Nikolay Borisov Signed-off-by: David Sterba --- fs/btrfs/zstd.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'fs/btrfs/zstd.c') diff --git a/fs/btrfs/zstd.c b/fs/btrfs/zstd.c index b3728220c329..5f17c741d167 100644 --- a/fs/btrfs/zstd.c +++ b/fs/btrfs/zstd.c @@ -713,9 +713,6 @@ const struct btrfs_compress_op btrfs_zstd_compress = { .put_workspace = zstd_put_workspace, .alloc_workspace = zstd_alloc_workspace, .free_workspace = zstd_free_workspace, - .compress_pages = zstd_compress_pages, - .decompress_bio = zstd_decompress_bio, - .decompress = zstd_decompress, .max_level = ZSTD_BTRFS_MAX_LEVEL, .default_level = ZSTD_BTRFS_DEFAULT_LEVEL, }; -- cgit v1.2.3-73-gaa49b