Skip to content

Commit f433076

Browse files
keithbuschaxboe
authored andcommitted
nvme-rdma: use request to get integrity segments
The request tracks the integrity segments already, so no need to recount the segments again. Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com> Reviewed-by: Kanchan Joshi <joshi.k@samsung.com> Signed-off-by: Keith Busch <kbusch@kernel.org> Link: https://lore.kernel.org/r/20240913182854.2445457-8-kbusch@meta.com Signed-off-by: Jens Axboe <axboe@kernel.dk>
1 parent 27c3785 commit f433076

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/nvme/host/rdma.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1496,7 +1496,7 @@ static int nvme_rdma_dma_map_req(struct ib_device *ibdev, struct request *rq,
14961496
req->metadata_sgl->sg_table.sgl =
14971497
(struct scatterlist *)(req->metadata_sgl + 1);
14981498
ret = sg_alloc_table_chained(&req->metadata_sgl->sg_table,
1499-
blk_rq_count_integrity_sg(rq->q, rq->bio),
1499+
rq->nr_integrity_segments,
15001500
req->metadata_sgl->sg_table.sgl,
15011501
NVME_INLINE_METADATA_SG_CNT);
15021502
if (unlikely(ret)) {

0 commit comments

Comments
 (0)