]> git.baikalelectronics.ru Git - kernel.git/commit
blk-merge: fix computing bio->bi_seg_front_size in case of single segment
authorMing Lei <ming.lei@canonical.com>
Mon, 30 Nov 2015 08:05:49 +0000 (16:05 +0800)
committerJens Axboe <axboe@fb.com>
Mon, 30 Nov 2015 20:02:36 +0000 (13:02 -0700)
commitbdb5b0df58f2ffe280a56db6278c5fa990550411
tree3cfc7528e641317aa7a56f82af569b03015ccdd1
parent8b7328800d325c7ae7f03a0bbcaa76dfee1bddc3
blk-merge: fix computing bio->bi_seg_front_size in case of single segment

When bio has only one physical segment, we should set bio's
bi_seg_front_size as the real(final) size of the single segment.

Fixes: a27e8351f2bb8(blk-merge: fix blk_bio_segment_split)
Reported-by: Markus Trippelsdorf <markus@trippelsdorf.de>
Tested-by: Markus Trippelsdorf <markus@trippelsdorf.de>
Signed-off-by: Ming Lei <ming.lei@canonical.com>
Signed-off-by: Jens Axboe <axboe@fb.com>
block/blk-merge.c