Commit 269fa3a4 authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

[PATCH] rmap page refcounting simplification

From: Martin Schwidefsky <schwidefsky@de.ibm.com>

Ok, its just the revert of the page_cache_release delta.
parent 83b41646
...@@ -361,6 +361,7 @@ static int try_to_unmap_one(struct page * page, pte_addr_t paddr) ...@@ -361,6 +361,7 @@ static int try_to_unmap_one(struct page * page, pte_addr_t paddr)
set_page_dirty(page); set_page_dirty(page);
mm->rss--; mm->rss--;
page_cache_release(page);
ret = SWAP_SUCCESS; ret = SWAP_SUCCESS;
out_unlock: out_unlock:
...@@ -401,7 +402,6 @@ int try_to_unmap(struct page * page) ...@@ -401,7 +402,6 @@ int try_to_unmap(struct page * page)
if (ret == SWAP_SUCCESS) { if (ret == SWAP_SUCCESS) {
if (page_test_and_clear_dirty(page)) if (page_test_and_clear_dirty(page))
set_page_dirty(page); set_page_dirty(page);
page_cache_release(page);
page->pte.direct = 0; page->pte.direct = 0;
ClearPageDirect(page); ClearPageDirect(page);
} }
...@@ -441,7 +441,6 @@ int try_to_unmap(struct page * page) ...@@ -441,7 +441,6 @@ int try_to_unmap(struct page * page)
if (page->pte.direct == 0 && if (page->pte.direct == 0 &&
page_test_and_clear_dirty(page)) page_test_and_clear_dirty(page))
set_page_dirty(page); set_page_dirty(page);
page_cache_release(page);
break; break;
case SWAP_AGAIN: case SWAP_AGAIN:
/* Skip this pte, remembering status. */ /* Skip this pte, remembering status. */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment