Re: [PATCH for-next v4 3/4] block: add helper to map bvec iterator for passthrough

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Sep 06, 2022 at 12:03:29PM +0530, Kanchan Joshi wrote:
On Tue, Sep 06, 2022 at 08:25:22AM +0200, Christoph Hellwig wrote:
On Mon, Sep 05, 2022 at 07:18:32PM +0530, Kanchan Joshi wrote:
+static struct bio *bio_map_get(struct request *rq, unsigned int nr_vecs,
		gfp_t gfp_mask)
{
@@ -259,13 +252,31 @@ static int bio_map_user_iov(struct request *rq, struct iov_iter *iter,
		bio = bio_alloc_bioset(NULL, nr_vecs, opf, gfp_mask,
					&fs_bio_set);
		if (!bio)
-			return -ENOMEM;
+			return NULL;

This context looks weird?  That bio_alloc_bioset should not be there,
as biosets are only used for file system I/O, which this is not.

if you think it's a deal-breaker, maybe I can add a new bioset in nvme and
pass that as argument to this helper. Would you prefer that over the
current approach.

seems I responded without looking carefully. The bioset addition is not
part of this series. It got added earlier [1] [2], as part of optimizing
polled-io on file/passthru path.

[1] https://lore.kernel.org/linux-block/20220806152004.382170-3-axboe@xxxxxxxxx/
[2] https://lore.kernel.org/linux-block/f2863702-e54c-cd74-efcf-8cb238be1a7c@xxxxxxxxx/





[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux