mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-08 04:42:04 -04:00
Revert "BACKPORT: FROMGIT: mm: improve mprotect(R|W) efficiency on pages referenced once"
This reverts commit fd0edef76b.
Reason for revert: Breaks CTS
Change-Id: I6d04bbe3bf119971b855a874acd374df911fb971
Signed-off-by: Quentin Perret <qperret@google.com>
This commit is contained in:
parent
fd0edef76b
commit
1a955566df
1 changed files with 0 additions and 6 deletions
|
|
@ -43,8 +43,6 @@ static unsigned long change_pte_range(struct vm_area_struct *vma, pmd_t *pmd,
|
|||
spinlock_t *ptl;
|
||||
unsigned long pages = 0;
|
||||
int target_node = NUMA_NO_NODE;
|
||||
bool anon_writable =
|
||||
vma_is_anonymous(vma) && (vma->vm_flags & VM_WRITE);
|
||||
|
||||
/*
|
||||
* Can be called with only the mmap_sem for reading by
|
||||
|
|
@ -121,11 +119,7 @@ static unsigned long change_pte_range(struct vm_area_struct *vma, pmd_t *pmd,
|
|||
(pte_soft_dirty(ptent) ||
|
||||
!(vma->vm_flags & VM_SOFTDIRTY))) {
|
||||
ptent = pte_mkwrite(ptent);
|
||||
} else if (anon_writable &&
|
||||
page_mapcount(pte_page(ptent)) == 1) {
|
||||
ptent = pte_mkwrite(ptent);
|
||||
}
|
||||
|
||||
ptep_modify_prot_commit(vma, addr, pte, oldpte, ptent);
|
||||
pages++;
|
||||
} else if (IS_ENABLED(CONFIG_MIGRATION)) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue