lkml.org 
[lkml]   [2023]   [May]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Subject[PATCH 11/15] block: blk-integrity: change how to find the number of integrity of bio
    From
    Date
    The method of constructing a bip has been changed, the number of
    segments can be obtained through bip_vcnt.

    Cc: Christoph Hellwig <hch@lst.de>
    Cc: Martin K. Petersen <martin.petersen@oracle.com>

    Signed-off-by: Jinyoung Choi <j-young.choi@samsung.com>
    ---
    block/blk-integrity.c | 5 +----
    1 file changed, 1 insertion(+), 4 deletions(-)

    diff --git a/block/blk-integrity.c b/block/blk-integrity.c
    index f97b7e8a6d4d..64407b412947 100644
    --- a/block/blk-integrity.c
    +++ b/block/blk-integrity.c
    @@ -217,7 +217,6 @@ bool blk_integrity_merge_bio(struct request_queue *q, struct request *req,
    struct bio *bio)
    {
    int nr_integrity_segs;
    - struct bio *next = bio->bi_next;

    if (blk_integrity_bypass_check(req, bio))
    return true;
    @@ -225,9 +224,7 @@ bool blk_integrity_merge_bio(struct request_queue *q, struct request *req,
    if (!__blk_integrity_mergeable(q, req, bio))
    return false;

    - bio->bi_next = NULL;
    - nr_integrity_segs = blk_rq_count_integrity_sg(q, bio);
    - bio->bi_next = next;
    + nr_integrity_segs = bio_integrity(bio)->bip_vcnt;

    if (req->nr_integrity_segments + nr_integrity_segs >
    q->limits.max_integrity_segments)
    --
    2.34.1
    \
     
     \ /
      Last update: 2023-05-03 12:22    [W:3.918 / U:0.024 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site