diff options
author | Lars Persson <lars.persson@axis.com> | 2015-02-26 08:16:02 -0500 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2015-03-25 08:48:00 -0400 |
commit | 5b9593f3bccb9904f260f9ad7f184e1d2921bd1e (patch) | |
tree | 06d4c30e6863919a084d467f6c0917e5e8922a7c /arch/mips/include/asm | |
parent | 9a49899eb88803dcc0ef437f09912f9a7b7a66fd (diff) |
Revert "MIPS: Remove race window in page fault handling"
Revert commit 2a4a8b1e5d9d ("MIPS: Remove race window in page fault
handling") because it increased the number of flushed dcache pages and
became a performance problem for some workloads.
Signed-off-by: Lars Persson <larper@axis.com>
Cc: linux-mips@linux-mips.org
Cc: paul.burton@imgtec.com
Cc: linux-kernel@vger.kernel.org
Patchwork: https://patchwork.linux-mips.org/patch/9345/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/include/asm')
-rw-r--r-- | arch/mips/include/asm/pgtable.h | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/arch/mips/include/asm/pgtable.h b/arch/mips/include/asm/pgtable.h index bffd46ca3694..819af9d057a8 100644 --- a/arch/mips/include/asm/pgtable.h +++ b/arch/mips/include/asm/pgtable.h | |||
@@ -127,10 +127,6 @@ do { \ | |||
127 | } \ | 127 | } \ |
128 | } while(0) | 128 | } while(0) |
129 | 129 | ||
130 | |||
131 | extern void set_pte_at(struct mm_struct *mm, unsigned long addr, pte_t *ptep, | ||
132 | pte_t pteval); | ||
133 | |||
134 | #if defined(CONFIG_PHYS_ADDR_T_64BIT) && defined(CONFIG_CPU_MIPS32) | 130 | #if defined(CONFIG_PHYS_ADDR_T_64BIT) && defined(CONFIG_CPU_MIPS32) |
135 | 131 | ||
136 | #define pte_none(pte) (!(((pte).pte_high) & ~_PAGE_GLOBAL)) | 132 | #define pte_none(pte) (!(((pte).pte_high) & ~_PAGE_GLOBAL)) |
@@ -152,6 +148,7 @@ static inline void set_pte(pte_t *ptep, pte_t pte) | |||
152 | buddy->pte_high |= _PAGE_GLOBAL; | 148 | buddy->pte_high |= _PAGE_GLOBAL; |
153 | } | 149 | } |
154 | } | 150 | } |
151 | #define set_pte_at(mm, addr, ptep, pteval) set_pte(ptep, pteval) | ||
155 | 152 | ||
156 | static inline void pte_clear(struct mm_struct *mm, unsigned long addr, pte_t *ptep) | 153 | static inline void pte_clear(struct mm_struct *mm, unsigned long addr, pte_t *ptep) |
157 | { | 154 | { |
@@ -190,6 +187,7 @@ static inline void set_pte(pte_t *ptep, pte_t pteval) | |||
190 | } | 187 | } |
191 | #endif | 188 | #endif |
192 | } | 189 | } |
190 | #define set_pte_at(mm, addr, ptep, pteval) set_pte(ptep, pteval) | ||
193 | 191 | ||
194 | static inline void pte_clear(struct mm_struct *mm, unsigned long addr, pte_t *ptep) | 192 | static inline void pte_clear(struct mm_struct *mm, unsigned long addr, pte_t *ptep) |
195 | { | 193 | { |
@@ -399,12 +397,15 @@ static inline pte_t pte_modify(pte_t pte, pgprot_t newprot) | |||
399 | 397 | ||
400 | extern void __update_tlb(struct vm_area_struct *vma, unsigned long address, | 398 | extern void __update_tlb(struct vm_area_struct *vma, unsigned long address, |
401 | pte_t pte); | 399 | pte_t pte); |
400 | extern void __update_cache(struct vm_area_struct *vma, unsigned long address, | ||
401 | pte_t pte); | ||
402 | 402 | ||
403 | static inline void update_mmu_cache(struct vm_area_struct *vma, | 403 | static inline void update_mmu_cache(struct vm_area_struct *vma, |
404 | unsigned long address, pte_t *ptep) | 404 | unsigned long address, pte_t *ptep) |
405 | { | 405 | { |
406 | pte_t pte = *ptep; | 406 | pte_t pte = *ptep; |
407 | __update_tlb(vma, address, pte); | 407 | __update_tlb(vma, address, pte); |
408 | __update_cache(vma, address, pte); | ||
408 | } | 409 | } |
409 | 410 | ||
410 | static inline void update_mmu_cache_pmd(struct vm_area_struct *vma, | 411 | static inline void update_mmu_cache_pmd(struct vm_area_struct *vma, |