summaryrefslogtreecommitdiffstats
path: root/block
diff options
context:
space:
mode:
authorGuoqing Jiang <gqjiang@suse.com>2016-09-22 03:10:01 -0400
committerJens Axboe <axboe@fb.com>2016-09-22 07:48:03 -0600
commit491221f88d00651e449c9caf7415b6453c8a77b7 (patch)
tree8021285e1ee5eaff42fa4a5a00929ad36dad7633 /block
parent1e3aeae4ea710023dda2a6b780183ee371d1a796 (diff)
downloadlinux-stable-491221f88d00651e449c9caf7415b6453c8a77b7.tar.gz
linux-stable-491221f88d00651e449c9caf7415b6453c8a77b7.tar.bz2
linux-stable-491221f88d00651e449c9caf7415b6453c8a77b7.zip
block: export bio_free_pages to other modules
bio_free_pages is introduced in commit 1dfa0f68c040 ("block: add a helper to free bio bounce buffer pages"), we can reuse the func in other modules after it was imported. Cc: Christoph Hellwig <hch@infradead.org> Cc: Jens Axboe <axboe@fb.com> Cc: Mike Snitzer <snitzer@redhat.com> Cc: Shaohua Li <shli@fb.com> Signed-off-by: Guoqing Jiang <gqjiang@suse.com> Acked-by: Kent Overstreet <kent.overstreet@gmail.com> Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'block')
-rw-r--r--block/bio.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/block/bio.c b/block/bio.c
index a6d279e1ea9e..db85c5753a76 100644
--- a/block/bio.c
+++ b/block/bio.c
@@ -1068,7 +1068,7 @@ static int bio_copy_to_iter(struct bio *bio, struct iov_iter iter)
return 0;
}
-static void bio_free_pages(struct bio *bio)
+void bio_free_pages(struct bio *bio)
{
struct bio_vec *bvec;
int i;
@@ -1076,6 +1076,7 @@ static void bio_free_pages(struct bio *bio)
bio_for_each_segment_all(bvec, bio, i)
__free_page(bvec->bv_page);
}
+EXPORT_SYMBOL(bio_free_pages);
/**
* bio_uncopy_user - finish previously mapped bio