]> git.dujemihanovic.xyz Git - linux.git/commitdiff
mm: update legacy flush_tlb_* to use vma
authorChen Li <chenli@uniontech.com>
Tue, 29 Jun 2021 02:39:56 +0000 (19:39 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 29 Jun 2021 17:53:52 +0000 (10:53 -0700)
1. These tlb flush functions have been using vma instead mm long time
   ago, but there is still some comments use mm as parameter.

2. the actual struct we use is vm_area_struct instead of vma_struct.

3. remove unused flush_kern_tlb_page.

Link: https://lkml.kernel.org/r/87k0oaq311.wl-chenli@uniontech.com
Signed-off-by: Chen Li <chenli@uniontech.com>
Acked-by: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Russell King <linux@armlinux.org.uk>
Cc: Jonas Bonn <jonas@southpole.se>
Cc: Chris Zankel <chris@zankel.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
arch/arm/include/asm/tlbflush.h
arch/arm/mm/tlb-v6.S
arch/arm/mm/tlb-v7.S
arch/ia64/kernel/efi_stub.S
arch/m68k/include/asm/tlbflush.h
arch/openrisc/include/asm/tlbflush.h
arch/xtensa/include/asm/tlbflush.h

index 24cbfc112dfad539682ac42432d6395159464a0d..0ccc985b90af0e3bf71cf78276287184a0784506 100644 (file)
@@ -253,7 +253,7 @@ extern struct cpu_tlb_fns cpu_tlb;
  *             space.
  *             - mm    - mm_struct describing address space
  *
- *     flush_tlb_range(mm,start,end)
+ *     flush_tlb_range(vma,start,end)
  *
  *             Invalidate a range of TLB entries in the specified
  *             address space.
@@ -261,18 +261,11 @@ extern struct cpu_tlb_fns cpu_tlb;
  *             - start - start address (may not be aligned)
  *             - end   - end address (exclusive, may not be aligned)
  *
- *     flush_tlb_page(vaddr,vma)
+ *     flush_tlb_page(vma, uaddr)
  *
  *             Invalidate the specified page in the specified address range.
+ *             - vma   - vm_area_struct describing address range
  *             - vaddr - virtual address (may not be aligned)
- *             - vma   - vma_struct describing address range
- *
- *     flush_kern_tlb_page(kaddr)
- *
- *             Invalidate the TLB entry for the specified page.  The address
- *             will be in the kernels virtual memory space.  Current uses
- *             only require the D-TLB to be invalidated.
- *             - kaddr - Kernel virtual memory address
  */
 
 /*
index 5335b9687297fa476f9b0d91fff1f8241d0e69af..74f4b383afe3d59465e914702195e3d1a8a42f27 100644 (file)
@@ -24,7 +24,7 @@
  *
  *     - start - start address (may not be aligned)
  *     - end   - end address (exclusive, may not be aligned)
- *     - vma   - vma_struct describing address range
+ *     - vma   - vm_area_struct describing address range
  *
  *     It is assumed that:
  *     - the "Invalidate single entry" instruction will invalidate
index 1bb28d7db5670551d22035c785544066fbeb1e2c..87bf4ab17721c782af2cd51102a2d955d71de693 100644 (file)
@@ -23,7 +23,7 @@
  *
  *     - start - start address (may not be aligned)
  *     - end   - end address (exclusive, may not be aligned)
- *     - vma   - vma_struct describing address range
+ *     - vma   - vm_area_struct describing address range
  *
  *     It is assumed that:
  *     - the "Invalidate single entry" instruction will invalidate
index 58233bb7976dfa46651f80ef2aaa67df9f8627b4..1fd61b78fb29026445b3761b654ed6a46c41d82f 100644 (file)
@@ -7,7 +7,7 @@
  *
  * This stub allows us to make EFI calls in physical mode with interrupts
  * turned off.  We need this because we can't call SetVirtualMap() until
- * the kernel has booted far enough to allow allocation of struct vma_struct
+ * the kernel has booted far enough to allow allocation of struct vm_area_struct
  * entries (which we would need to map stuff with memory attributes other
  * than uncached or writeback...).  Since the GetTime() service gets called
  * earlier than that, we need to be able to make physical mode EFI calls from
index 5337bc2c262f22468213c616c3de35d9c877255e..a6318ccd308fd3ae3bbf3e0a62f05aae7b6ed9d1 100644 (file)
@@ -263,7 +263,7 @@ static inline void flush_tlb_page(struct vm_area_struct *vma, unsigned long addr
        BUG();
 }
 
-static inline void flush_tlb_range(struct mm_struct *mm,
+static inline void flush_tlb_range(struct vm_area_struct *vma,
                                   unsigned long start, unsigned long end)
 {
        BUG();
index 185dcd3731eddd23e369267b1ce6971110546d41..dbf030365ab48e0dfc9ab58e58cf8f88126c577b 100644 (file)
@@ -25,7 +25,7 @@
  *  - flush_tlb_all() flushes all processes TLBs
  *  - flush_tlb_mm(mm) flushes the specified mm context TLB's
  *  - flush_tlb_page(vma, vmaddr) flushes one page
- *  - flush_tlb_range(mm, start, end) flushes a range of pages
+ *  - flush_tlb_range(vma, start, end) flushes a range of pages
  */
 extern void local_flush_tlb_all(void);
 extern void local_flush_tlb_mm(struct mm_struct *mm);
index 856e2da2e397fe2156055887c22ed5806d45e204..573df8cea2006e0119e7a113ed35006b0963d3e7 100644 (file)
@@ -26,8 +26,8 @@
  *
  *  - flush_tlb_all() flushes all processes TLB entries
  *  - flush_tlb_mm(mm) flushes the specified mm context TLB entries
- *  - flush_tlb_page(mm, vmaddr) flushes a single page
- *  - flush_tlb_range(mm, start, end) flushes a range of pages
+ *  - flush_tlb_page(vma, page) flushes a single page
+ *  - flush_tlb_range(vma, vmaddr, end) flushes a range of pages
  */
 
 void local_flush_tlb_all(void);