lkml.org 
[lkml]   [2014]   [May]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 03/27] generic/tlb.h: Move common defines into generic tlb.h
Date
Move most common defines into the generic tlb.h to avoid
duplicate code.

Cc: Arnd Bergmann <arnd@arndb.de>
Cc: linux-arch@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Richard Weinberger <richard@nod.at>
---
include/asm-generic/tlb.h | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)

diff --git a/include/asm-generic/tlb.h b/include/asm-generic/tlb.h
index 5672d7e..6e15413 100644
--- a/include/asm-generic/tlb.h
+++ b/include/asm-generic/tlb.h
@@ -149,6 +149,30 @@ static inline void tlb_remove_page(struct mmu_gather *tlb, struct page *page)
#define __tlb_remove_pmd_tlb_entry(tlb, pmdp, address) do {} while (0)
#endif

+#ifndef tlb_start_vma
+#define tlb_start_vma(tlb, vma) do {} while (0)
+#endif
+
+#ifndef tlb_end_vma
+#define tlb_end_vma(tlb, vma) do {} while (0)
+#endif
+
+#ifndef __tlb_remove_tlb_entry
+#define __tlb_remove_tlb_entry(tlb, ptep, address) do {} while (0)
+#endif
+
+#ifndef tlb_flush
+#define tlb_flush(tlb) flush_tlb_mm((tlb)->mm)
+#endif
+
+#ifndef __pte_free_tlb
+#define __pte_free_tlb(tlb, pte, address) pte_free((tlb)->mm, pte)
+#endif
+
+#ifndef __pmd_free_tlb
+#define __pmd_free_tlb(tlb, pmd, address) pmd_free((tlb)->mm, pmd)
+#endif
+
#define tlb_remove_pmd_tlb_entry(tlb, pmdp, address) \
do { \
tlb->need_flush = 1; \
--
1.8.4.2


\
 
 \ /
  Last update: 2014-05-17 16:41    [W:0.265 / U:0.660 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site