diff mbox series

block: Remove unused code

Message ID 20190627025941.32262-1-damien.lemoal@wdc.com (mailing list archive)
State New, archived
Headers show
Series block: Remove unused code | expand

Commit Message

Damien Le Moal June 27, 2019, 2:59 a.m. UTC
bio_flush_dcache_pages() is unused. Remove it.

Signed-off-by: Damien Le Moal <damien.lemoal@wdc.com>
---
 block/bio.c         | 12 ------------
 include/linux/bio.h | 11 -----------
 2 files changed, 23 deletions(-)

Comments

Christoph Hellwig June 27, 2019, 7:31 a.m. UTC | #1
Looks good:

Reviewed-by: Christoph Hellwig <hch@lst.de>

The function has been unused going back to at least Linux 3.15.
Jens Axboe June 27, 2019, 1:34 p.m. UTC | #2
On 6/26/19 8:59 PM, Damien Le Moal wrote:
> bio_flush_dcache_pages() is unused. Remove it.

Applied, thanks.
diff mbox series

Patch

diff --git a/block/bio.c b/block/bio.c
index 1c21d1e7f1b8..85a9abe9cf21 100644
--- a/block/bio.c
+++ b/block/bio.c
@@ -1816,18 +1816,6 @@  void generic_end_io_acct(struct request_queue *q, int req_op,
 }
 EXPORT_SYMBOL(generic_end_io_acct);
 
-#if ARCH_IMPLEMENTS_FLUSH_DCACHE_PAGE
-void bio_flush_dcache_pages(struct bio *bi)
-{
-	struct bio_vec bvec;
-	struct bvec_iter iter;
-
-	bio_for_each_segment(bvec, bi, iter)
-		flush_dcache_page(bvec.bv_page);
-}
-EXPORT_SYMBOL(bio_flush_dcache_pages);
-#endif
-
 static inline bool bio_remaining_done(struct bio *bio)
 {
 	/*
diff --git a/include/linux/bio.h b/include/linux/bio.h
index f87abaa898f0..34e05a6e139c 100644
--- a/include/linux/bio.h
+++ b/include/linux/bio.h
@@ -444,17 +444,6 @@  void generic_end_io_acct(struct request_queue *q, int op,
 				struct hd_struct *part,
 				unsigned long start_time);
 
-#ifndef ARCH_IMPLEMENTS_FLUSH_DCACHE_PAGE
-# error	"You should define ARCH_IMPLEMENTS_FLUSH_DCACHE_PAGE for your platform"
-#endif
-#if ARCH_IMPLEMENTS_FLUSH_DCACHE_PAGE
-extern void bio_flush_dcache_pages(struct bio *bi);
-#else
-static inline void bio_flush_dcache_pages(struct bio *bi)
-{
-}
-#endif
-
 extern void bio_copy_data_iter(struct bio *dst, struct bvec_iter *dst_iter,
 			       struct bio *src, struct bvec_iter *src_iter);
 extern void bio_copy_data(struct bio *dst, struct bio *src);