summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorMing Lei <ming.lei@redhat.com>2019-04-02 04:26:44 +0200
committerJens Axboe <axboe@kernel.dk>2019-04-08 18:57:10 +0200
commitb21e11c5c8311b8bf6923ff29d57f2a5f997e939 (patch)
tree0c2becff5ec805afd350fd73e8f446f52f925de9 /tools
parentblock, bfq: fix some typos in comments (diff)
downloadlinux-b21e11c5c8311b8bf6923ff29d57f2a5f997e939.tar.xz
linux-b21e11c5c8311b8bf6923ff29d57f2a5f997e939.zip
block: fix build warning in merging bvecs
Commit f6970f83ef79 ("block: don't check if adjacent bvecs in one bio can be mergeable") changes bvec merge by only considering two bvecs from different bios. However, if the former bio doesn't inlcude any io bvec, then the following warning may be triggered: warning: ‘bvec.bv_offset’ may be used uninitialized in this function [-Wmaybe-uninitialized] In practice, it shouldn't be triggered. Fixes it by adding check on former bio, the check shouldn't add any cost given 'bio->bi_iter' can be hit in cache. Reported-by: Jens Axboe <axboe@kernel.dk> Fixes: f6970f83ef79 ("block: don't check if adjacent bvecs in one bio can be mergeable") Signed-off-by: Ming Lei <ming.lei@redhat.com> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'tools')
0 files changed, 0 insertions, 0 deletions