--- /usr/src/linux/mm/filemap.c.orig Sat Jun 3 19:09:16 2000 +++ /usr/src/linux/mm/filemap.c Wed Jun 7 01:21:19 2000 @@ -332,6 +332,14 @@ if (page->age) goto dispose_continue; + /* + * Page is from a zone we don't care about. + * Don't drop page cache entries in vain. + * Must be done before count - or do a count++ + */ + if (page->zone->free_pages > page->zone->pages_high) + goto dispose_continue; + count--; /* * Avoid unscalable SMP locking for pages we can @@ -367,13 +375,6 @@ goto made_buffer_progress; } } - - /* - * Page is from a zone we don't care about. - * Don't drop page cache entries in vain. - */ - if (page->zone->free_pages > page->zone->pages_high) - goto unlock_continue; /* Take the pagecache_lock spinlock held to avoid other tasks to notice the page while we are looking at its