Re: [PATCH] mm,oom: use per signal_struct flag rather than clear TIF_MEMDIE
From: Oleg Nesterov <oleg@redhat.com>
Date: 2016-07-03 13:24:53
On 06/30, Michal Hocko wrote:
On Wed 29-06-16 22:14:09, Oleg Nesterov wrote:quoted
On 06/28, Michal Hocko wrote:quoted
Could you point me to where it depends on that? I mean if we are past exit_mm then we have unmapped the address space most probably but why should we care about that in the scheduler? There shouldn't be any further access to the address space by that point. I can see that context_switch() checks task->mm but it should just work when it sees it non NULL, right?But who will do the final mmdrop() then? I am not saying this is impossible to change, say we do this in finish_task_switch(TASK_DEAD) or even in free_task(), but we do not want this?I thought it could be done somewhere in release_task after we unhash the process
No, we can't do this. Note that release_task() can be called right after exit_notify() by its parent ot by the exiting thread itself. It can still run after that and it needs ->active_mm. Oleg. -- 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:"dont@kvack.org"> email@kvack.org </a>