Skip to contentSkip to conversation

swap_out() question...

DISCUSSION Zlatko Calusic 1 participant 1 message Jan 7, 2001 Memory management

lore
Share & tools
lore
#0 lore raw

In the swap_out() function in mm/vmscan.c there is this chunk of code:

	onlist = PageActive(page);
	/* Don't look at this pte if it's been accessed recently. */
	if (ptep_test_and_clear_young(page_table)) {
		age_page_up(page);
		goto out_failed;
	}
	if (!onlist)
		/* The page is still mapped, so it can't be freeable... */
		age_page_down_ageonly(page);

Now I don't understand the last comment. It speaks about mapped page but we have only tested if a page is active or no. Also if ageing the page gets it age down to zero page will be freeable indeed. What's wrong with that comment?

Also why are we aging page down only if it is not active?

Rik and other mm guys, could you comment on this?

Signature · 5 lines
Zlatko
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to [email protected].  For more info on Linux MM,
see: http://www.linux.eu.org/Linux-MM/