]> www.infradead.org Git - users/jedix/linux-maple.git/commit
block: Check for gaps on front and back merges
authorJens Axboe <axboe@fb.com>
Wed, 4 Oct 2017 15:12:01 +0000 (08:12 -0700)
committerAshok Vairavan <ashok.vairavan@oracle.com>
Mon, 23 Oct 2017 18:32:47 +0000 (11:32 -0700)
commit50f113a81b852e45ead0d4b0fd5d79e96530f643
tree0581f2f09d63bd551b4ae67939d3fad07c18d366
parentcc500383c29a734102683003e2485dac6c6a0f05
block: Check for gaps on front and back merges

We are checking for gaps to previous bio_vec, which can
only detect back merges gaps. Moreover, at the point where
we check for a gap, we don't know if we will attempt a back
or a front merge. Thus, check for gap to prev in a back merge
attempt and check for a gap to next in a front merge attempt.

Signed-off-by: Jens Axboe <axboe@fb.com>
[sagig: Minor rename change]
Signed-off-by: Sagi Grimberg <sagig@mellanox.com>
(cherry picked from commit 5e7c4274a70aa2d6f485996d0ca1dad52d0039ca)

Orabug: 26871819

Conflicts:
     Replaced queue_virt_boundary with
test_bit(QUEUE_FLAG_SG_GAPS, &q->queue_flags)

Signed-off-by: Ashok Vairavan <ashok.vairavan@oracle.com>
Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com>
Reviewed-by: Kyle Fortin <kyle.fortin@oracle.com>
block/blk-merge.c
include/linux/blkdev.h