patch-2.4.0-test12 linux/mm/swap.c
Next file: linux/mm/swap_state.c
Previous file: linux/mm/page_alloc.c
Back to the patch index
Back to the overall index
- Lines: 37
- Date:
Tue Nov 28 16:52:56 2000
- Orig file:
v2.4.0-test11/linux/mm/swap.c
- Orig date:
Tue Oct 31 12:42:27 2000
diff -u --recursive --new-file v2.4.0-test11/linux/mm/swap.c linux/mm/swap.c
@@ -180,33 +180,9 @@
* Don't touch it if it's not on the active list.
* (some pages aren't on any list at all)
*/
- if (PageActive(page) && page_count(page) <= maxcount &&
- !page_ramdisk(page)) {
-
- /*
- * We can move the page to the inactive_dirty list
- * if we have the strong suspicion that they might
- * become freeable in the near future.
- *
- * That is, the page has buffer heads attached (that
- * need to be cleared away) and/or the function calling
- * us has an extra reference count on the page.
- */
- if (page->buffers || page_count(page) == 2) {
- del_page_from_active_list(page);
- add_page_to_inactive_dirty_list(page);
- /*
- * Only if we are SURE the page is clean and immediately
- * reusable, we move it to the inactive_clean list.
- */
- } else if (page->mapping && !PageDirty(page) &&
- !PageLocked(page)) {
- del_page_from_active_list(page);
- add_page_to_inactive_clean_list(page);
- }
- /*
- * OK, we cannot free the page. Leave it alone.
- */
+ if (PageActive(page) && page_count(page) <= maxcount && !page_ramdisk(page)) {
+ del_page_from_active_list(page);
+ add_page_to_inactive_dirty_list(page);
}
}
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)