[PATCH] vm_swap_full bogus

From: Hugh Dickins (hugh@veritas.com)
Date: Fri Nov 02 2001 - 17:29:58 EST


Just noticed bogus vm_swap_full() macro since 2.4.10:
swapper_space.nrpages counts _cached_ swap, not used swap.
Either I'm confused again, or... please apply!

Hugh

--- 2.4.14-pre7/mm/memory.c Fri Nov 2 06:22:15 2001
+++ linux/mm/memory.c Fri Nov 2 22:13:19 2001
@@ -1068,7 +1068,7 @@
 
 /* Swap 80% full? Release the pages as they are paged in.. */
 #define vm_swap_full() \
- (swapper_space.nrpages*5 > total_swap_pages*4)
+ (nr_swap_pages*5 < total_swap_pages)
 
 /*
  * We hold the mm semaphore and the page_table_lock on entry and

-
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/



This archive was generated by hypermail 2b29 : Wed Nov 07 2001 - 21:00:20 EST