mirror of
https://github.com/torvalds/linux.git
synced 2026-05-26 08:02:27 +02:00
scsi: 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-7-kbusch@meta.com Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
parent
d2c5b1facc
commit
27c3785e94
|
|
@ -1175,8 +1175,7 @@ blk_status_t scsi_alloc_sgtables(struct scsi_cmnd *cmd)
|
|||
goto out_free_sgtables;
|
||||
}
|
||||
|
||||
ivecs = blk_rq_count_integrity_sg(rq->q, rq->bio);
|
||||
|
||||
ivecs = rq->nr_integrity_segments;
|
||||
if (sg_alloc_table_chained(&prot_sdb->table, ivecs,
|
||||
prot_sdb->table.sgl,
|
||||
SCSI_INLINE_PROT_SG_CNT)) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user