lkml.org 
[lkml]   [2001]   [Jun]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH] fix accounting of memory_pressure
Hi,

the attached patch makes sure to only increase memory_pressure
in cases we actually found a page, this prevents the inactive
target from rising to infinite in case we don't have any
inactive_clean pages in the system...

(observed in testing)

regards,

Rik
--
Executive summary of a recent Microsoft press release:
"we are concerned about the GNU General Public License (GPL)"

http://www.surriel.com/
http://www.conectiva.com/ http://distro.conectiva.com/


--- linux-2.4.5-ac17/mm/page_alloc.c.unlazy Sun Jun 24 19:03:03 2001
+++ linux-2.4.5-ac17/mm/page_alloc.c Sun Jun 24 19:05:22 2001
@@ -440,7 +440,6 @@
* the inactive clean list. (done by page_launder)
*/
if (gfp_mask & __GFP_WAIT) {
- memory_pressure++;
try_to_free_pages(gfp_mask);
goto try_again;
}
--- linux-2.4.5-ac17/mm/vmscan.c.unlazy Sun Jun 24 19:03:03 2001
+++ linux-2.4.5-ac17/mm/vmscan.c Sun Jun 24 19:05:36 2001
@@ -397,6 +397,7 @@
goto out;

found_page:
+ memory_pressure++;
del_page_from_inactive_clean_list(page);
UnlockPage(page);
page->age = PAGE_AGE_START;
@@ -406,7 +407,6 @@
out:
spin_unlock(&pagemap_lru_lock);
spin_unlock(&pagecache_lock);
- memory_pressure++;
return page;
}

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:55    [W:0.031 / U:0.160 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site