Re: [RFC] per thread page reservation patch
From: Hugh Dickins <hidden>
Date: 2005-01-08 13:44:44
Also in:
lkml
From: Hugh Dickins <hidden>
Date: 2005-01-08 13:44:44
Also in:
lkml
On Sat, 8 Jan 2005, Nikita Danilov wrote:
Andrew Morton [off-list ref] writes:quoted
__alloc_pages(GFP_KERNEL, ...) doesn't return NULL. It'll either succeed or never return ;) That behaviour may change at any time of course, but itHmm... it used to, when I wrote that code.
And still does, if OOM decides to kill _your_ task: OOM sets PF_MEMDIE,
and then you don't get to go the retry route at all:
/* This allocation should allow future memory freeing. */
if ((p->flags & (PF_MEMALLOC | PF_MEMDIE)) && !in_interrupt()) {
/* go through the zonelist yet again, ignoring mins */
for (i = 0; (z = zones[i]) != NULL; i++) {
page = buffered_rmqueue(z, order, gfp_mask);
if (page)
goto got_pg;
}
goto nopage;
}
....
nopage:
....
return NULL;
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"aart@kvack.org"> aart@kvack.org </a>