Message ID | 20151130141141.6ce3fadb@tom-T450 (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On 2015.11.30 at 14:11 +0800, Ming Lei wrote: > On Sun, 29 Nov 2015 18:05:06 +0100 > Markus Trippelsdorf <markus@trippelsdorf.de> wrote: > > > > No, I'm not using DM multipath. > > > OK, I guess it is still one block merge issue, care to test the > following patch? > > The patch can address one issue when bio->bi_seg_front_size > is set as too small mistakenly, then fewer physical segment may > be figured out. Many thanks. Your patch fixes the issue for me.
diff --git a/block/blk-merge.c b/block/blk-merge.c index 41a55ba..e01405a 100644 --- a/block/blk-merge.c +++ b/block/blk-merge.c @@ -103,6 +103,9 @@ static struct bio *blk_bio_segment_split(struct request_queue *q, bvprv = bv; bvprvp = &bvprv; sectors += bv.bv_len >> 9; + + if (nsegs == 1 && seg_size > front_seg_size) + front_seg_size = seg_size; continue; } new_segment: