arm64: Remove __flush_dcache_page()
authorCatalin Marinas <catalin.marinas@arm.com>
Wed, 1 May 2013 15:38:23 +0000 (16:38 +0100)
committerMark Brown <broonie@linaro.org>
Thu, 15 May 2014 10:17:09 +0000 (11:17 +0100)
This function is only used in __sync_icache_dcache(), so remove it and
call __flush_dcache_area() directly. The flush_icache_user_range()
function is not used in the arm64 kernel.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Reported-by: Will Deacon <will.deacon@arm.com>
Acked-by: Will Deacon <will.deacon@arm.com>
(cherry picked from commit ebd88367de80f9509bd30a09342d0a19c925b23e)
Signed-off-by: Mark Brown <broonie@linaro.org>
arch/arm64/include/asm/cacheflush.h
arch/arm64/mm/flush.c
arch/arm64/mm/mm.h

index 3300cbd18a89b504939c7b2530040f8bdd159ebf..fea9ee32720678b348685ef4803bb2c622c3eb8e 100644 (file)
@@ -123,9 +123,6 @@ static inline void __flush_icache_all(void)
 #define flush_dcache_mmap_unlock(mapping) \
        spin_unlock_irq(&(mapping)->tree_lock)
 
-#define flush_icache_user_range(vma,page,addr,len) \
-       flush_dcache_page(page)
-
 /*
  * We don't appear to need to do anything here.  In fact, if we did, we'd
  * duplicate cache flushing elsewhere performed by flush_dcache_page().
index 88611c3a421aecd15391e734e9646089ee6ce54d..d3751b5f7f07433ac625aff0ba72b4565805948d 100644 (file)
@@ -70,11 +70,6 @@ void copy_to_user_page(struct vm_area_struct *vma, struct page *page,
 #endif
 }
 
-void __flush_dcache_page(struct page *page)
-{
-       __flush_dcache_area(page_address(page), PAGE_SIZE);
-}
-
 void __sync_icache_dcache(pte_t pte, unsigned long addr)
 {
        unsigned long pfn;
@@ -86,7 +81,7 @@ void __sync_icache_dcache(pte_t pte, unsigned long addr)
 
        page = pfn_to_page(pfn);
        if (!test_and_set_bit(PG_dcache_clean, &page->flags)) {
-               __flush_dcache_page(page);
+               __flush_dcache_area(page_address(page), PAGE_SIZE);
                __flush_icache_all();
        } else if (icache_is_aivivt()) {
                __flush_icache_all();
index 916701e6d040b92b5edbf63935ff2ecd8f3e101a..d519f4f50c8c6f5431281ee5e15346e860e9f741 100644 (file)
@@ -1,3 +1,2 @@
-extern void __flush_dcache_page(struct page *page);
 extern void __init bootmem_init(void);
 extern void __init arm64_swiotlb_init(void);