block: change how we get page references in bio_iov_iter_get_pages
authorChristoph Hellwig <hch@lst.de>
Thu, 11 Apr 2019 06:23:30 +0000 (08:23 +0200)
committerJens Axboe <axboe@kernel.dk>
Fri, 12 Apr 2019 15:06:40 +0000 (09:06 -0600)
commit7321ecbfc7cf85211460a1dc6bb0ccfc3dcf9df0
tree3e9df6be8ed3f3a6f965b0c28f937f54890e28eb
parent14eacf12dbc75352fa746dfd9e24de3170ba5ff5
block: change how we get page references in bio_iov_iter_get_pages

Instead of needing a special macro to iterate over all pages in
a bvec just do a second passs over the whole bio.  This also matches
what we do on the release side.  The release side helper is moved
up to where we need the get helper to clearly express the symmetry.

Reviewed-by: Ming Lei <ming.lei@redhat.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/bio.c
include/linux/bvec.h