bio-integrity: create multi-page bvecs in bio_integrity_add_page()
authorJinyoung Choi <j-young.choi@samsung.com>
Thu, 3 Aug 2023 02:52:02 +0000 (11:52 +0900)
committerJens Axboe <axboe@kernel.dk>
Wed, 9 Aug 2023 22:05:35 +0000 (16:05 -0600)
commit0ece1d649b6dd615925a72bc1824d6b9fa5b998a
tree16a9635eb7f496c9d5a060dff83ab2ce833e1e30
parentd1f04c2e23c99258049c6081c3147bae69e5bcb8
bio-integrity: create multi-page bvecs in bio_integrity_add_page()

In general, the bvec data structure consists of one for physically
continuous pages. But, in the bvec configuration for bip, physically
continuous integrity pages are composed of each bvec.

Allow bio_integrity_add_page() to create multi-page bvecs, just like
the bio payloads. This simplifies adding larger payloads, and fixes
support for non-tiny workloads with nvme, which stopped using
scatterlist for metadata a while ago.

Cc: Christoph Hellwig <hch@lst.de>
Cc: Martin K. Petersen <martin.petersen@oracle.com>
Fixes: 783b94bd9250 ("nvme-pci: do not build a scatterlist to map metadata")
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jinyoung Choi <j-young.choi@samsung.com>
Tested-by: "Martin K. Petersen" <martin.petersen@oracle.com>
Reviewed-by: "Martin K. Petersen" <martin.petersen@oracle.com>
Link: https://lore.kernel.org/r/20230803025202epcms2p82f57cbfe32195da38c776377b55aed59@epcms2p8
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/bio-integrity.c