From e5d2cb43198498da39c3d792a966330a84d40484 Mon Sep 17 00:00:00 2001 From: Will Deacon Date: Tue, 13 Aug 2019 20:51:48 +0800 Subject: [PATCH] asm-generic/tlb: Guard with #ifdef CONFIG_MMU mainline inclusion from mainline-4.20-rc1 commit: faaadaf315b48d40b39bf4f0011fa740f40fbe9e category: feature feature: Reduce synchronous TLB invalidation on ARM64 bugzilla: NA CVE: NA -------------------------------------------------- The inner workings of the mmu_gather-based TLB invalidation mechanism are not relevant to nommu configurations, so guard them with an #ifdef. This allows us to implement future functions using static inlines without breaking the build. Acked-by: Nicholas Piggin Acked-by: Peter Zijlstra (Intel) Signed-off-by: Will Deacon Signed-off-by: Hanjun Guo Reviewed-by: Xuefeng Wang Signed-off-by: Yang Yingliang --- include/asm-generic/tlb.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/include/asm-generic/tlb.h b/include/asm-generic/tlb.h index b3353e21f3b3..a25e236f7a7f 100644 --- a/include/asm-generic/tlb.h +++ b/include/asm-generic/tlb.h @@ -20,6 +20,8 @@ #include #include +#ifdef CONFIG_MMU + #ifdef CONFIG_HAVE_RCU_TABLE_FREE /* * Semi RCU freeing of the page directories. @@ -310,6 +312,8 @@ static inline void tlb_remove_check_page_size_change(struct mmu_gather *tlb, #endif #endif +#endif /* CONFIG_MMU */ + #define tlb_migrate_finish(mm) do {} while (0) #endif /* _ASM_GENERIC__TLB_H */ -- GitLab