mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-25 02:09:42 +00:00
btrfs: simplify code with bio_io_error
bio_io_error was introduced in the commit 4246a0b63b
("block: add a bi_error field to struct bio"), so use it to simplify
code.
Signed-off-by: Guoqing Jiang <gqjiang@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
parent
25ff17e82f
commit
054ec2f626
1 changed files with 1 additions and 2 deletions
|
@ -8647,8 +8647,7 @@ static void btrfs_submit_direct(struct bio *dio_bio, struct inode *inode,
|
|||
* callbacks - they require an allocated dip and a clone of dio_bio.
|
||||
*/
|
||||
if (bio && dip) {
|
||||
bio->bi_error = -EIO;
|
||||
bio_endio(bio);
|
||||
bio_io_error(bio);
|
||||
/*
|
||||
* The end io callbacks free our dip, do the final put on bio
|
||||
* and all the cleanup and final put for dio_bio (through
|
||||
|
|
Loading…
Reference in a new issue