diff options
author | David Sterba <dsterba@suse.com> | 2022-10-27 02:02:32 +0200 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2022-12-05 18:00:51 +0100 |
commit | 19af6a7d345acc885f970d57577fa80ca4ad3d98 (patch) | |
tree | f7f25d7ec1d1a30e6e54b0f860d7f4f318920990 /fs/btrfs/compression.c | |
parent | 961f5b8bf48a463ac5fe5b13143426d79eb41817 (diff) |
btrfs: change how repair action is passed to btrfs_repair_one_sector
There's a function pointer passed to btrfs_repair_one_sector that will
submit the right bio for repair. However there are only two callbacks,
for buffered and for direct IO. This can be simplified to a bool-based
switch and call either function, indirect calls in this case is an
unnecessary abstraction. This allows to remove the submit_bio_hook_t
typedef.
Reviewed-by: Anand Jain <anand.jain@oracle.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/compression.c')
-rw-r--r-- | fs/btrfs/compression.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/btrfs/compression.c b/fs/btrfs/compression.c index e66fa18dbcf7..cf3dc7e501ec 100644 --- a/fs/btrfs/compression.c +++ b/fs/btrfs/compression.c @@ -196,7 +196,7 @@ static void end_compressed_bio_read(struct btrfs_bio *bbio) refcount_inc(&cb->pending_ios); ret = btrfs_repair_one_sector(inode, bbio, offset, bv.bv_page, bv.bv_offset, - btrfs_submit_data_read_bio); + true); if (ret) { refcount_dec(&cb->pending_ios); status = errno_to_blk_status(ret); |