Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 356491
b: refs/heads/master
c: af34770
h: refs/heads/master
i:
  356489: 9f53283
  356487: 8d37749
v: v3
  • Loading branch information
Johannes Weiner authored and Linus Torvalds committed Feb 24, 2013
1 parent f0fcecd commit c5a2331
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 9b4f98cdac9683ee9cdb28c582a81223f0c10a3f
refs/heads/master: af34770e55fd899c96d8d73bdc04dbc956096650
6 changes: 0 additions & 6 deletions trunk/mm/ksm.c
Original file line number Diff line number Diff line change
Expand Up @@ -1590,13 +1590,7 @@ struct page *ksm_does_need_to_copy(struct page *page,

SetPageDirty(new_page);
__SetPageUptodate(new_page);
SetPageSwapBacked(new_page);
__set_page_locked(new_page);

if (!mlocked_vma_newpage(vma, new_page))
lru_cache_add_lru(new_page, LRU_ACTIVE_ANON);
else
add_page_to_unevictable_list(new_page);
}

return new_page;
Expand Down
5 changes: 4 additions & 1 deletion trunk/mm/memory.c
Original file line number Diff line number Diff line change
Expand Up @@ -3044,7 +3044,10 @@ static int do_swap_page(struct mm_struct *mm, struct vm_area_struct *vma,
}
flush_icache_page(vma, page);
set_pte_at(mm, address, page_table, pte);
do_page_add_anon_rmap(page, vma, address, exclusive);
if (swapcache) /* ksm created a completely new copy */
page_add_new_anon_rmap(page, vma, address);
else
do_page_add_anon_rmap(page, vma, address, exclusive);
/* It's better to call commit-charge after rmap is established */
mem_cgroup_commit_charge_swapin(page, ptr);

Expand Down

0 comments on commit c5a2331

Please sign in to comment.