• Ming Lei's avatar
    block: blk-merge: try to make front segments in full size · a2d37968
    Ming Lei authored
    When merging one bvec into segment, if the bvec is too big
    to merge, current policy is to move the whole bvec into another
    new segment.
    
    This patchset changes the policy into trying to maximize size of
    front segments, that means in above situation, part of bvec
    is merged into current segment, and the remainder is put
    into next segment.
    
    This patch prepares for support multipage bvec because
    it can be quite common to see this case and we should try
    to make front segments in full size.
    Signed-off-by: default avatarMing Lei <ming.lei@redhat.com>
    Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
    a2d37968
blk-merge.c 20.7 KB