Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 130383
b: refs/heads/master
c: 85d9fc8
h: refs/heads/master
i:
  130381: 61288ea
  130379: f558685
  130375: 9e041a2
  130367: 24560e5
v: v3
  • Loading branch information
KAMEZAWA Hiroyuki authored and Linus Torvalds committed Jan 30, 2009
1 parent 1db0d90 commit 816abfa
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 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: 7460db567bbca76bf087d1694d792a1a96bdaa26
refs/heads/master: 85d9fc89fb0f0703df6444f260187c088a8d59ff
5 changes: 4 additions & 1 deletion trunk/mm/swapfile.c
Original file line number Diff line number Diff line change
Expand Up @@ -698,8 +698,10 @@ static int unuse_pte(struct vm_area_struct *vma, pmd_t *pmd,
pte_t *pte;
int ret = 1;

if (mem_cgroup_try_charge_swapin(vma->vm_mm, page, GFP_KERNEL, &ptr))
if (mem_cgroup_try_charge_swapin(vma->vm_mm, page, GFP_KERNEL, &ptr)) {
ret = -ENOMEM;
goto out_nolock;
}

pte = pte_offset_map_lock(vma->vm_mm, pmd, addr, &ptl);
if (unlikely(!pte_same(*pte, swp_entry_to_pte(entry)))) {
Expand All @@ -723,6 +725,7 @@ static int unuse_pte(struct vm_area_struct *vma, pmd_t *pmd,
activate_page(page);
out:
pte_unmap_unlock(pte, ptl);
out_nolock:
return ret;
}

Expand Down

0 comments on commit 816abfa

Please sign in to comment.