2.4.19 ( try_to_swap_out) does not set page->mapping to NULL

From: Bourne (bourne@ToughGuy.net)
Date: Thu Dec 12 2002 - 22:29:26 EST

Hi all, A small piece of code in mm/vmscan.c kept me confused. Please
could some one explain this ?

File: mm/vmscan.c , try_to_swap_out()

drop_pte: mm->rss--
                return freeable;
    goto drop_pte;

What i can get is if page->mapping is NOT NULL , then do a
page_cache_release(). This boils down to __free_pages_ok(). Here the
code snippet is if(page->mapping) BUG();

So if try_to_swap_out wants to drop a page which can be brought in
always ( i.e , not dirty ), then what is the harm in setting it to NULL ?



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 : Sun Dec 15 2002 - 22:00:25 EST