aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-parisc/tlbflush.h
diff options
context:
space:
mode:
authorKyle McMartin <kyle@hera.kernel.org>2007-02-18 14:35:45 -0500
committerKyle McMartin <kyle@hera.kernel.org>2007-02-18 14:35:45 -0500
commit04532c4f55ef4b577c59744f789d5b1add435503 (patch)
treeb38fc98b2729b1edc12796bd996e88eddbddc226 /include/asm-parisc/tlbflush.h
parentf6744bdd7346dcdf94b9a7ac6fb820693b2724cd (diff)
Revert "[PARISC] Optimize TLB flush on SMP systems"
This reverts commit 592ac93a607109e0643da6c23ae07ac749e973b1 which causes SMP machines with maxcpus > 1 to fail to boot...
Diffstat (limited to 'include/asm-parisc/tlbflush.h')
-rw-r--r--include/asm-parisc/tlbflush.h24
1 files changed, 13 insertions, 11 deletions
diff --git a/include/asm-parisc/tlbflush.h b/include/asm-parisc/tlbflush.h
index ae2d12008546..3313da9ea00f 100644
--- a/include/asm-parisc/tlbflush.h
+++ b/include/asm-parisc/tlbflush.h
@@ -39,19 +39,21 @@ extern void flush_tlb_all_local(void *);
39 * etc. do not do that). 39 * etc. do not do that).
40 */ 40 */
41 41
42static inline void __flush_tlb_mm(void *mmv)
43{
44 struct mm_struct *mm = (struct mm_struct *)mmv;
45 if (mm == current->active_mm)
46 load_context(mm->context);
47}
48
49static inline void flush_tlb_mm(struct mm_struct *mm) 42static inline void flush_tlb_mm(struct mm_struct *mm)
50{ 43{
51 if (mm->context != 0) 44 BUG_ON(mm == &init_mm); /* Should never happen */
52 free_sid(mm->context); 45
53 mm->context = alloc_sid(); 46#ifdef CONFIG_SMP
54 on_each_cpu(__flush_tlb_mm, mm, 1, 1); 47 flush_tlb_all();
48#else
49 if (mm) {
50 if (mm->context != 0)
51 free_sid(mm->context);
52 mm->context = alloc_sid();
53 if (mm == current->active_mm)
54 load_context(mm->context);
55 }
56#endif
55} 57}
56 58
57extern __inline__ void flush_tlb_pgtables(struct mm_struct *mm, unsigned long start, unsigned long end) 59extern __inline__ void flush_tlb_pgtables(struct mm_struct *mm, unsigned long start, unsigned long end)