Really?
In my kernel it is:
void __free_page(struct page *page)
{
if (!PageReserved(page) && atomic_dec_and_test(&page->count)) {
if (PageSwapCache(page))
panic ("Freeing swap cache page");
page->flags &= ~(1 << PG_referenced);
free_pages_ok(page - mem_map, 0);
return;
}
}
which is very understandable IMHO, and probably answers your later
questions. Perhaps you were looking at the wrong __free_page ?
BTW, even the low level free_pages_ok code isn't that hard to understand if you
look up the buddy allocator algorithm in some text book like the Knuth.
-Andi
-- This is like TV. I don't like TV.- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/