On Tue, 20 Feb 2007, Rik van Riel wrote:
Nono, I try to remove the swap space occupied by pages that
go back onto the active list. Regardless of whether they
were already there, or whether they started out on the
inactive list.
Ok then do it for all pages that go back not just for those leftover from the moving of pages to the inactive list (why would you move those???)
Maybe the hunk does apply in a different location than I thought.
If you do that in the loop over the pages on active list then it would make sense. But in that case you need another piece of it doing the same to the pages that are released at the end of shrink_active_list().