diff options
author | Christoph Hellwig <hch@lst.de> | 2022-02-02 17:01:09 +0100 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2022-02-04 07:43:18 -0700 |
commit | abfc426d1b2fb2176df59851a64223b58ddae7e7 (patch) | |
tree | c5ee019a325bee6b7f158ff409f383781186fa3f /block/blk-mq.c | |
parent | a0e8de798dd6710a69d69ec57b246a0e34c4a695 (diff) | |
download | lwn-abfc426d1b2fb2176df59851a64223b58ddae7e7.tar.gz lwn-abfc426d1b2fb2176df59851a64223b58ddae7e7.zip |
block: pass a block_device to bio_clone_fast
Pass a block_device to bio_clone_fast and __bio_clone_fast and give
the functions more suitable names.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Mike Snitzer <snitzer@redhat.com>
Link: https://lore.kernel.org/r/20220202160109.108149-14-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'block/blk-mq.c')
-rw-r--r-- | block/blk-mq.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/block/blk-mq.c b/block/blk-mq.c index 1adfe4824ef5..4b868e792ba4 100644 --- a/block/blk-mq.c +++ b/block/blk-mq.c @@ -2975,10 +2975,10 @@ int blk_rq_prep_clone(struct request *rq, struct request *rq_src, bs = &fs_bio_set; __rq_for_each_bio(bio_src, rq_src) { - bio = bio_clone_fast(bio_src, gfp_mask, bs); + bio = bio_alloc_clone(rq->q->disk->part0, bio_src, gfp_mask, + bs); if (!bio) goto free_and_out; - bio->bi_bdev = rq->q->disk->part0; if (bio_ctr && bio_ctr(bio, bio_src, data)) goto free_and_out; |