[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Sat, 12 Dec 2015 12:06:31 -0800
From: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
To: linux-kernel@...r.kernel.org
Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
stable@...r.kernel.org, Michael Ellerman <mpe@...erman.id.au>,
Mark Salter <msalter@...hat.com>,
Laurent Dufour <ldufour@...ux.vnet.ibm.com>,
Ming Lei <ming.lei@...onical.com>, Jens Axboe <axboe@...com>
Subject: [PATCH 4.3 67/71] block: fix segment split
4.3-stable review patch. If anyone has any objections, please let me know.
------------------
From: Ming Lei <ming.lei@...onical.com>
commit 578270bfbd2803dc7b0b03fbc2ac119efbc73195 upstream.
Inside blk_bio_segment_split(), previous bvec pointer(bvprvp)
always points to the iterator local variable, which is obviously
wrong, so fix it by pointing to the local variable of 'bvprv'.
Fixes: 5014c311baa2b(block: fix bogus compiler warnings in blk-merge.c)
Reported-by: Michael Ellerman <mpe@...erman.id.au>
Reported-by: Mark Salter <msalter@...hat.com>
Tested-by: Laurent Dufour <ldufour@...ux.vnet.ibm.com>
Tested-by: Mark Salter <msalter@...hat.com>
Signed-off-by: Ming Lei <ming.lei@...onical.com>
Signed-off-by: Jens Axboe <axboe@...com>
Signed-off-by: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
---
block/blk-merge.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--- a/block/blk-merge.c
+++ b/block/blk-merge.c
@@ -91,7 +91,7 @@ static struct bio *blk_bio_segment_split
seg_size += bv.bv_len;
bvprv = bv;
- bvprvp = &bv;
+ bvprvp = &bvprv;
sectors += bv.bv_len >> 9;
continue;
}
@@ -101,7 +101,7 @@ new_segment:
nsegs++;
bvprv = bv;
- bvprvp = &bv;
+ bvprvp = &bvprv;
seg_size = bv.bv_len;
sectors += bv.bv_len >> 9;
}
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists