]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
MIPS: mm: Remove local_flush_tlb_mm()
authorPaul Burton <paul.burton@mips.com>
Sat, 2 Feb 2019 01:43:22 +0000 (01:43 +0000)
committerPaul Burton <paul.burton@mips.com>
Mon, 4 Feb 2019 18:56:24 +0000 (10:56 -0800)
All 3 variants of local_flush_tlb_mm() are now effectively simple calls
to drop_mmu_context(). Remove them and use drop_mmu_context() directly.

Signed-off-by: Paul Burton <paul.burton@mips.com>
Cc: linux-mips@vger.kernel.org
arch/mips/include/asm/tlbflush.h
arch/mips/kernel/smp.c
arch/mips/mm/tlb-r3k.c
arch/mips/mm/tlb-r4k.c
arch/mips/mm/tlb-r8k.c

index 40a361092491e0145324569f75f8ebeb252cad74..9789e7a32defebbb922ee6e0b420c8cfdf32709f 100644 (file)
@@ -14,7 +14,6 @@
  *  - flush_tlb_kernel_range(start, end) flushes a range of kernel pages
  */
 extern void local_flush_tlb_all(void);
-extern void local_flush_tlb_mm(struct mm_struct *mm);
 extern void local_flush_tlb_range(struct vm_area_struct *vma,
        unsigned long start, unsigned long end);
 extern void local_flush_tlb_kernel_range(unsigned long start,
@@ -23,6 +22,8 @@ extern void local_flush_tlb_page(struct vm_area_struct *vma,
        unsigned long page);
 extern void local_flush_tlb_one(unsigned long vaddr);
 
+#include <asm/mmu_context.h>
+
 #ifdef CONFIG_SMP
 
 extern void flush_tlb_all(void);
@@ -36,7 +37,7 @@ extern void flush_tlb_one(unsigned long vaddr);
 #else /* CONFIG_SMP */
 
 #define flush_tlb_all()                        local_flush_tlb_all()
-#define flush_tlb_mm(mm)               local_flush_tlb_mm(mm)
+#define flush_tlb_mm(mm)               drop_mmu_context(mm)
 #define flush_tlb_range(vma, vmaddr, end)      local_flush_tlb_range(vma, vmaddr, end)
 #define flush_tlb_kernel_range(vmaddr,end) \
        local_flush_tlb_kernel_range(vmaddr, end)
index d84b9066b4654e4e9a3eee2fc7136260fd25b702..d7088ca31e43556b7370deb554406f685c68331a 100644 (file)
@@ -487,7 +487,7 @@ void flush_tlb_all(void)
 
 static void flush_tlb_mm_ipi(void *mm)
 {
-       local_flush_tlb_mm((struct mm_struct *)mm);
+       drop_mmu_context((struct mm_struct *)mm);
 }
 
 /*
@@ -540,7 +540,7 @@ void flush_tlb_mm(struct mm_struct *mm)
                                cpu_context(cpu, mm) = 0;
                }
        }
-       local_flush_tlb_mm(mm);
+       drop_mmu_context(mm);
 
        preempt_enable();
 }
index 60eb7a1144403f30efaacf188ac983aba642c707..50f207591b6d08b6bb8326debe3e90721522c7cf 100644 (file)
@@ -67,18 +67,6 @@ void local_flush_tlb_all(void)
        local_irq_restore(flags);
 }
 
-void local_flush_tlb_mm(struct mm_struct *mm)
-{
-#ifdef DEBUG_TLB
-       int cpu = smp_processor_id();
-
-       if (cpu_context(cpu, mm) != 0)
-               printk("[tlbmm<%lu>]", (unsigned long)cpu_context(cpu, mm));
-#endif
-
-       drop_mmu_context(mm);
-}
-
 void local_flush_tlb_range(struct vm_area_struct *vma, unsigned long start,
                           unsigned long end)
 {
index 9fff08eabe8fc059b27640d28927fada3a52524c..0114c43398f351f2272ac44a1369885751727b30 100644 (file)
@@ -104,13 +104,6 @@ void local_flush_tlb_all(void)
 }
 EXPORT_SYMBOL(local_flush_tlb_all);
 
-/* All entries common to a mm share an asid.  To effectively flush
-   these entries, we just bump the asid. */
-void local_flush_tlb_mm(struct mm_struct *mm)
-{
-       drop_mmu_context(mm);
-}
-
 void local_flush_tlb_range(struct vm_area_struct *vma, unsigned long start,
        unsigned long end)
 {
index c938d6b497ef111f2ec8ad91574af34eccdbfd70..c1e9e144007edd396b3c6bec798cf9422246f609 100644 (file)
@@ -50,11 +50,6 @@ void local_flush_tlb_all(void)
        local_irq_restore(flags);
 }
 
-void local_flush_tlb_mm(struct mm_struct *mm)
-{
-       drop_mmu_context(mm);
-}
-
 void local_flush_tlb_range(struct vm_area_struct *vma, unsigned long start,
        unsigned long end)
 {