提交 cf58b537 编写于 作者: C Christoph Hellwig 提交者: Jens Axboe

rbd: use bvec_virt

Use bvec_virt instead of open coding it.
Signed-off-by: NChristoph Hellwig <hch@lst.de>
Reviewed-by: NJeff Layton <jlayton@kernel.org>
Link: https://lore.kernel.org/r/20210804095634.460779-8-hch@lst.deSigned-off-by: NJens Axboe <axboe@kernel.dk>
上级 fbc27241
......@@ -2986,8 +2986,7 @@ static bool is_zero_bvecs(struct bio_vec *bvecs, u32 bytes)
};
ceph_bvec_iter_advance_step(&it, bytes, ({
if (memchr_inv(page_address(bv.bv_page) + bv.bv_offset, 0,
bv.bv_len))
if (memchr_inv(bvec_virt(&bv), 0, bv.bv_len))
return false;
}));
return true;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册