block: remove bvec_kmap_irq and bvec_kunmap_irq
authorChristoph Hellwig <hch@lst.de>
Thu, 20 May 2021 12:15:10 +0000 (14:15 +0200)
committerChristoph Hellwig <hch@lst.de>
Fri, 21 May 2021 05:55:27 +0000 (07:55 +0200)
These two helpers are entirely unused now.

Signed-off-by: Christoph Hellwig <hch@lst.de>
include/linux/bio.h

index a0b4cfdf62a434f0ba287f32f6fd39e9c321a181..adba79581d29409622ee7d5d15b9c90a654ac722 100644 (file)
@@ -523,47 +523,6 @@ static inline void bio_clone_blkg_association(struct bio *dst,
                                              struct bio *src) { }
 #endif /* CONFIG_BLK_CGROUP */
 
-#ifdef CONFIG_HIGHMEM
-/*
- * remember never ever reenable interrupts between a bvec_kmap_irq and
- * bvec_kunmap_irq!
- */
-static inline char *bvec_kmap_irq(struct bio_vec *bvec, unsigned long *flags)
-{
-       unsigned long addr;
-
-       /*
-        * might not be a highmem page, but the preempt/irq count
-        * balancing is a lot nicer this way
-        */
-       local_irq_save(*flags);
-       addr = (unsigned long) kmap_atomic(bvec->bv_page);
-
-       BUG_ON(addr & ~PAGE_MASK);
-
-       return (char *) addr + bvec->bv_offset;
-}
-
-static inline void bvec_kunmap_irq(char *buffer, unsigned long *flags)
-{
-       unsigned long ptr = (unsigned long) buffer & PAGE_MASK;
-
-       kunmap_atomic((void *) ptr);
-       local_irq_restore(*flags);
-}
-
-#else
-static inline char *bvec_kmap_irq(struct bio_vec *bvec, unsigned long *flags)
-{
-       return page_address(bvec->bv_page) + bvec->bv_offset;
-}
-
-static inline void bvec_kunmap_irq(char *buffer, unsigned long *flags)
-{
-       *flags = 0;
-}
-#endif
-
 /*
  * BIO list management for use by remapping drivers (e.g. DM or MD) and loop.
  *