diff options
author | Christoph Hellwig <hch@lst.de> | 2022-07-07 07:33:27 +0200 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2022-07-25 19:54:47 +0200 |
commit | 524bcd1e178da1dccf24d9fc60fb20a35ec45e88 (patch) | |
tree | 9331397638556fcb0a32b112b2cdc5294d8c9a9e /fs/open.c | |
parent | c144c63fd33a1fc0e43e0b851a35b09c9460d94d (diff) | |
download | linux-524bcd1e178da1dccf24d9fc60fb20a35ec45e88.tar.bz2 |
btrfs: simplify the pending I/O counting in struct compressed_bio
Instead of counting the sectors just count the bios, with an extra
reference held during submission. This significantly simplifies the
submission side error handling.
This slightly changes completion and error handling of
btrfs_submit_compressed_{read,write} because with the old code the
compressed_bio could have been completed in
submit_compressed_{read,write} only if there was an error during
submission for one of the lower bio, whilst with the new code there is a
chance for this to happen even for successful submission if the all the
lower bios complete before the end of the function is reached.
Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Reviewed-by: Boris Burkov <boris@bur.io>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/open.c')
0 files changed, 0 insertions, 0 deletions