kmap_atomic_to_page() has no users, remove it
authorNicolas Pitre <nicolas.pitre@linaro.org>
Mon, 9 Nov 2015 22:58:23 +0000 (14:58 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Mon, 9 Nov 2015 23:11:24 +0000 (15:11 -0800)
Removal started in commit 5bbeed12bdc3 ("sparc32: drop unused
kmap_atomic_to_page").  Let's do it across the whole tree.

Signed-off-by: Nicolas Pitre <nico@linaro.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 files changed:
arch/arm/include/asm/highmem.h
arch/arm/mm/highmem.c
arch/frv/include/asm/highmem.h
arch/frv/mm/highmem.c
arch/metag/include/asm/highmem.h
arch/metag/mm/highmem.c
arch/microblaze/include/asm/highmem.h
arch/mips/include/asm/highmem.h
arch/mips/mm/highmem.c
arch/parisc/include/asm/cacheflush.h
arch/powerpc/include/asm/highmem.h
arch/tile/include/asm/highmem.h
arch/tile/mm/highmem.c
arch/x86/include/asm/highmem.h
arch/x86/mm/highmem_32.c
include/linux/highmem.h

index 535579511ed035f50d14bc179b4c00b74a0b4f95..0a0e2d1784c011ddf917312f51931cefb8fa5d8a 100644 (file)
@@ -68,7 +68,6 @@ extern void kunmap(struct page *page);
 extern void *kmap_atomic(struct page *page);
 extern void __kunmap_atomic(void *kvaddr);
 extern void *kmap_atomic_pfn(unsigned long pfn);
-extern struct page *kmap_atomic_to_page(const void *ptr);
 #endif
 
 #endif
index 9df5f09585ca49bc48c209f8588a395ca5f8d449..d02f8187b1ccedb0df0520d2d75e6d93c838b360 100644 (file)
@@ -147,13 +147,3 @@ void *kmap_atomic_pfn(unsigned long pfn)
 
        return (void *)vaddr;
 }
-
-struct page *kmap_atomic_to_page(const void *ptr)
-{
-       unsigned long vaddr = (unsigned long)ptr;
-
-       if (vaddr < FIXADDR_START)
-               return virt_to_page(ptr);
-
-       return pte_page(get_fixmap_pte(vaddr));
-}
index b3adc93611f32c51ae10716e0decfa8e40ac8b9d..1f58938703ab6e73d824b68d5000c25e347248d4 100644 (file)
@@ -62,8 +62,6 @@ extern void kunmap_high(struct page *page);
 extern void *kmap(struct page *page);
 extern void kunmap(struct page *page);
 
-extern struct page *kmap_atomic_to_page(void *ptr);
-
 #endif /* !__ASSEMBLY__ */
 
 /*
index 785344bbdc07c360e81768c8472336bebd0baa3e..45750fb65c4927f9c59b5b5b0d6b4755e33475d0 100644 (file)
@@ -32,11 +32,6 @@ void kunmap(struct page *page)
 
 EXPORT_SYMBOL(kunmap);
 
-struct page *kmap_atomic_to_page(void *ptr)
-{
-       return virt_to_page(ptr);
-}
-
 void *kmap_atomic(struct page *page)
 {
        unsigned long paddr;
index 6646a15c73dd70c55dbb999d422c84234d6d6e15..9b1d172cd884ad822627bf0f4dab12cddab47674 100644 (file)
@@ -56,7 +56,6 @@ extern void kunmap(struct page *page);
 extern void *kmap_atomic(struct page *page);
 extern void __kunmap_atomic(void *kvaddr);
 extern void *kmap_atomic_pfn(unsigned long pfn);
-extern struct page *kmap_atomic_to_page(void *ptr);
 #endif
 
 #endif
index 807f1b1c4e6567738f676c935ad21483e4972a32..f19a87f2c1ec3401cbe3290bedc4146c5b716646 100644 (file)
@@ -111,20 +111,6 @@ void *kmap_atomic_pfn(unsigned long pfn)
        return (void *)vaddr;
 }
 
-struct page *kmap_atomic_to_page(void *ptr)
-{
-       unsigned long vaddr = (unsigned long)ptr;
-       int idx;
-       pte_t *pte;
-
-       if (vaddr < FIXADDR_START)
-               return virt_to_page(ptr);
-
-       idx = virt_to_fix(vaddr);
-       pte = kmap_pte - (idx - FIX_KMAP_BEGIN);
-       return pte_page(*pte);
-}
-
 void __init kmap_init(void)
 {
        unsigned long kmap_vstart;
index d0463893243888f47bf1e740d7ebf0e68fb087c4..67925ef18cfa3ce0c433b8da11727be67d1d32d1 100644 (file)
@@ -76,19 +76,6 @@ static inline void *kmap_atomic(struct page *page)
        return kmap_atomic_prot(page, kmap_prot);
 }
 
-static inline struct page *kmap_atomic_to_page(void *ptr)
-{
-       unsigned long idx, vaddr = (unsigned long) ptr;
-       pte_t *pte;
-
-       if (vaddr < FIXADDR_START)
-               return virt_to_page(ptr);
-
-       idx = virt_to_fix(vaddr);
-       pte = kmap_pte - (idx - FIX_KMAP_BEGIN);
-       return pte_page(*pte);
-}
-
 #define flush_cache_kmaps()    { flush_icache(); flush_dcache(); }
 
 #endif /* __KERNEL__ */
index 572e63ec2a38fe8f40faa2555ee7595d8be82cce..01880b34a209b37dd5b02d759afda543f7989e9a 100644 (file)
@@ -49,7 +49,6 @@ extern void kunmap(struct page *page);
 extern void *kmap_atomic(struct page *page);
 extern void __kunmap_atomic(void *kvaddr);
 extern void *kmap_atomic_pfn(unsigned long pfn);
-extern struct page *kmap_atomic_to_page(void *ptr);
 
 #define flush_cache_kmaps()    flush_cache_all()
 
index 11661cbc11a8193f7a9817fb0101fd9483db9f23..d7258a103439d8316b527d64569955339489fe4c 100644 (file)
@@ -118,19 +118,6 @@ void *kmap_atomic_pfn(unsigned long pfn)
        return (void*) vaddr;
 }
 
-struct page *kmap_atomic_to_page(void *ptr)
-{
-       unsigned long idx, vaddr = (unsigned long)ptr;
-       pte_t *pte;
-
-       if (vaddr < FIXADDR_START)
-               return virt_to_page(ptr);
-
-       idx = virt_to_fix(vaddr);
-       pte = kmap_pte - (idx - FIX_KMAP_BEGIN);
-       return pte_page(*pte);
-}
-
 void __init kmap_init(void)
 {
        unsigned long kmap_vstart;
index ec2df4bab3022dfc35a83539afcd24207e199f9f..845272ce9cc587222e835131bb5ed96be0be03d4 100644 (file)
@@ -156,7 +156,6 @@ static inline void __kunmap_atomic(void *addr)
 
 #define kmap_atomic_prot(page, prot)   kmap_atomic(page)
 #define kmap_atomic_pfn(pfn)   kmap_atomic(pfn_to_page(pfn))
-#define kmap_atomic_to_page(ptr)       virt_to_page(ptr)
 
 #endif /* _PARISC_CACHEFLUSH_H */
 
index caaf6e00630d0d74b2966b1bce89a367ad3ceaa6..01c2c23b307e76b7a3df003c5ac8c599f11baa5c 100644 (file)
@@ -84,19 +84,6 @@ static inline void *kmap_atomic(struct page *page)
        return kmap_atomic_prot(page, kmap_prot);
 }
 
-static inline struct page *kmap_atomic_to_page(void *ptr)
-{
-       unsigned long idx, vaddr = (unsigned long) ptr;
-       pte_t *pte;
-
-       if (vaddr < FIXADDR_START)
-               return virt_to_page(ptr);
-
-       idx = virt_to_fix(vaddr);
-       pte = kmap_pte - (idx - FIX_KMAP_BEGIN);
-       return pte_page(*pte);
-}
-
 
 #define flush_cache_kmaps()    flush_cache_all()
 
index fc8429a31c850b561f6bb47df86b4dfa5731edfc..979579b38e573a03a6153bd160abc1a2d3959713 100644 (file)
@@ -63,7 +63,6 @@ void *kmap_atomic(struct page *page);
 void __kunmap_atomic(void *kvaddr);
 void *kmap_atomic_pfn(unsigned long pfn);
 void *kmap_atomic_prot_pfn(unsigned long pfn, pgprot_t prot);
-struct page *kmap_atomic_to_page(void *ptr);
 void *kmap_atomic_prot(struct page *page, pgprot_t prot);
 void kmap_atomic_fix_kpte(struct page *page, int finished);
 
index fcd545014e79dcc83a662f4db5a37e7511e695a0..eca28551b22d418d0252145e79d8565125a246d5 100644 (file)
@@ -275,15 +275,3 @@ void *kmap_atomic_prot_pfn(unsigned long pfn, pgprot_t prot)
 {
        return kmap_atomic_prot(pfn_to_page(pfn), prot);
 }
-
-struct page *kmap_atomic_to_page(void *ptr)
-{
-       pte_t *pte;
-       unsigned long vaddr = (unsigned long)ptr;
-
-       if (vaddr < FIXADDR_START)
-               return virt_to_page(ptr);
-
-       pte = kmap_get_pte(vaddr);
-       return pte_page(*pte);
-}
index 04e9d023168f9d098d6f6d90a2c4b8cbae4dc209..1c0b43724ce33adb755ad2655d1c9be555e7afea 100644 (file)
@@ -68,7 +68,6 @@ void *kmap_atomic(struct page *page);
 void __kunmap_atomic(void *kvaddr);
 void *kmap_atomic_pfn(unsigned long pfn);
 void *kmap_atomic_prot_pfn(unsigned long pfn, pgprot_t prot);
-struct page *kmap_atomic_to_page(void *ptr);
 
 #define flush_cache_kmaps()    do { } while (0)
 
index eecb207a2037080f9f5d74c36c300b217a4f7a82..a6d7392581379ba0de7c51b85193ea33d20546c9 100644 (file)
@@ -104,20 +104,6 @@ void __kunmap_atomic(void *kvaddr)
 }
 EXPORT_SYMBOL(__kunmap_atomic);
 
-struct page *kmap_atomic_to_page(void *ptr)
-{
-       unsigned long idx, vaddr = (unsigned long)ptr;
-       pte_t *pte;
-
-       if (vaddr < FIXADDR_START)
-               return virt_to_page(ptr);
-
-       idx = virt_to_fix(vaddr);
-       pte = kmap_pte - (idx - FIX_KMAP_BEGIN);
-       return pte_page(*pte);
-}
-EXPORT_SYMBOL(kmap_atomic_to_page);
-
 void __init set_highmem_pages_init(void)
 {
        struct zone *zone;
index 6aefcd0031a6bd013cf322d1021812fcf84250c2..bb3f3297062a0b67a590adbb6630d6f419249ea5 100644 (file)
@@ -78,7 +78,6 @@ static inline void __kunmap_atomic(void *addr)
 }
 
 #define kmap_atomic_pfn(pfn)   kmap_atomic(pfn_to_page(pfn))
-#define kmap_atomic_to_page(ptr)       virt_to_page(ptr)
 
 #define kmap_flush_unused()    do {} while(0)
 #endif