diff options
author | Ingo Molnar <mingo@elte.hu> | 2010-10-08 10:46:27 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2010-10-08 10:46:27 +0200 |
commit | 7cd2541cf2395962daf98ec32a141aba3398a9b2 (patch) | |
tree | 3c8bebb277462ba0de9d44233a970d34056dc45e /mm/ksm.c | |
parent | c62f981f9309486ba5546edbb5925f71e441fa65 (diff) | |
parent | cb655d0f3d57c23db51b981648e452988c0223f9 (diff) | |
download | linux-3.10-7cd2541cf2395962daf98ec32a141aba3398a9b2.tar.gz linux-3.10-7cd2541cf2395962daf98ec32a141aba3398a9b2.tar.bz2 linux-3.10-7cd2541cf2395962daf98ec32a141aba3398a9b2.zip |
Merge commit 'v2.6.36-rc7' into perf/core
Conflicts:
arch/x86/kernel/module.c
Merge reason: Resolve the conflict, pick up fixes.
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'mm/ksm.c')
-rw-r--r-- | mm/ksm.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -712,7 +712,7 @@ static int write_protect_page(struct vm_area_struct *vma, struct page *page, if (!ptep) goto out; - if (pte_write(*ptep)) { + if (pte_write(*ptep) || pte_dirty(*ptep)) { pte_t entry; swapped = PageSwapCache(page); @@ -735,7 +735,9 @@ static int write_protect_page(struct vm_area_struct *vma, struct page *page, set_pte_at(mm, addr, ptep, entry); goto out_unlock; } - entry = pte_wrprotect(entry); + if (pte_dirty(entry)) + set_page_dirty(page); + entry = pte_mkclean(pte_wrprotect(entry)); set_pte_at_notify(mm, addr, ptep, entry); } *orig_pte = *ptep; |