mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
[PATCH] lock PTE before updating it in 440/BookE page fault handler
Fix 44x and BookE page fault handler to correctly lock PTE before trying to pte_update() it, otherwise this PTE might be swapped out after pte_present() check but before pte_uptdate() call, resulting in corrupted PTE. This can happen with enabled preemption and low memory condition. Signed-off-by: Eugene Surovegin <[email protected]> Signed-off-by: Paul Mackerras <[email protected]>
This commit is contained in:
parent
bac30d1a78
commit
bab70a4af7
5 changed files with 44 additions and 31 deletions
|
|
@ -837,7 +837,8 @@ static inline int io_remap_pfn_range(struct vm_area_struct *vma,
|
|||
*/
|
||||
#define pgtable_cache_init() do { } while (0)
|
||||
|
||||
extern int get_pteptr(struct mm_struct *mm, unsigned long addr, pte_t **ptep);
|
||||
extern int get_pteptr(struct mm_struct *mm, unsigned long addr, pte_t **ptep,
|
||||
pmd_t **pmdp);
|
||||
|
||||
#include <asm-generic/pgtable.h>
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue