summaryrefslogtreecommitdiffstats
path: root/drivers/md/dm-crypt.c
diff options
context:
space:
mode:
authorMing Lei <ming.lei@redhat.com>2017-12-18 13:22:13 +0100
committerJens Axboe <axboe@kernel.dk>2018-01-06 17:18:00 +0100
commit92681eca6104d2ec2fdf9fc65f529deb226ab0a1 (patch)
tree5283da0b54a4b1b93314af1180ba5091141c4fb1 /drivers/md/dm-crypt.c
parentbtrfs: avoid accessing bvec table directly for a cloned bio (diff)
downloadlinux-92681eca6104d2ec2fdf9fc65f529deb226ab0a1.tar.xz
linux-92681eca6104d2ec2fdf9fc65f529deb226ab0a1.zip
dm-crypt: don't clear bvec->bv_page in crypt_free_buffer_pages()
The bio is always freed after running crypt_free_buffer_pages(), so it isn't necessary to clear bv->bv_page. Cc: Mike Snitzer <snitzer@redhat.com> Cc:dm-devel@redhat.com Signed-off-by: Ming Lei <ming.lei@redhat.com> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/md/dm-crypt.c')
-rw-r--r--drivers/md/dm-crypt.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/md/dm-crypt.c b/drivers/md/dm-crypt.c
index 9fc12f556534..48332666fc38 100644
--- a/drivers/md/dm-crypt.c
+++ b/drivers/md/dm-crypt.c
@@ -1446,7 +1446,6 @@ static void crypt_free_buffer_pages(struct crypt_config *cc, struct bio *clone)
bio_for_each_segment_all(bv, clone, i) {
BUG_ON(!bv->bv_page);
mempool_free(bv->bv_page, cc->page_pool);
- bv->bv_page = NULL;
}
}