diff options
author | Jens Axboe <axboe@kernel.dk> | 2023-01-04 16:51:19 +0100 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2023-01-04 17:05:23 +0100 |
commit | 613b14884b8595e20b9fac4126bf627313827fbe (patch) | |
tree | c779b681aaaeb9854bc310c3a618b8c72f376686 /drivers/s390/block/dcssblk.c | |
parent | Merge tag 'nvme-6.2-2022-12-29' of git://git.infradead.org/nvme into block-6.2 (diff) | |
download | linux-613b14884b8595e20b9fac4126bf627313827fbe.tar.xz linux-613b14884b8595e20b9fac4126bf627313827fbe.zip |
block: handle bio_split_to_limits() NULL return
This can't happen right now, but in preparation for allowing
bio_split_to_limits() returning NULL if it ended the bio, check for it
in all the callers.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/s390/block/dcssblk.c')
-rw-r--r-- | drivers/s390/block/dcssblk.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/s390/block/dcssblk.c b/drivers/s390/block/dcssblk.c index b392b9f5482e..c0f85ffb2b62 100644 --- a/drivers/s390/block/dcssblk.c +++ b/drivers/s390/block/dcssblk.c @@ -865,6 +865,8 @@ dcssblk_submit_bio(struct bio *bio) unsigned long bytes_done; bio = bio_split_to_limits(bio); + if (!bio) + return; bytes_done = 0; dev_info = bio->bi_bdev->bd_disk->private_data; |