Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 86824
b: refs/heads/master
c: 6d48ff8
h: refs/heads/master
v: v3
  • Loading branch information
Hugh Dickins authored and Linus Torvalds committed Mar 5, 2008
1 parent 9de700c commit 0392a57
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 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: b9c565d5a29a795f970b4a1340393d8fc6722fb9
refs/heads/master: 6d48ff8bcfd403ec8d3ef7a56538ea9e6f773b9c
12 changes: 6 additions & 6 deletions trunk/mm/memcontrol.c
Original file line number Diff line number Diff line change
Expand Up @@ -665,15 +665,15 @@ void mem_cgroup_uncharge_page(struct page *page)
page_assign_page_cgroup(page, NULL);
unlock_page_cgroup(page);

mem = pc->mem_cgroup;
css_put(&mem->css);
res_counter_uncharge(&mem->res, PAGE_SIZE);

mz = page_cgroup_zoneinfo(pc);
spin_lock_irqsave(&mz->lru_lock, flags);
__mem_cgroup_remove_list(pc);
spin_unlock_irqrestore(&mz->lru_lock, flags);

mem = pc->mem_cgroup;
res_counter_uncharge(&mem->res, PAGE_SIZE);
css_put(&mem->css);

kfree(pc);
return;
}
Expand Down Expand Up @@ -774,9 +774,9 @@ static void mem_cgroup_force_empty_list(struct mem_cgroup *mem,
if (page_get_page_cgroup(page) == pc) {
page_assign_page_cgroup(page, NULL);
unlock_page_cgroup(page);
css_put(&mem->css);
res_counter_uncharge(&mem->res, PAGE_SIZE);
__mem_cgroup_remove_list(pc);
res_counter_uncharge(&mem->res, PAGE_SIZE);
css_put(&mem->css);
kfree(pc);
} else {
/* racing uncharge: let page go then retry */
Expand Down

0 comments on commit 0392a57

Please sign in to comment.