On 06/12, Ingo Molnar wrote: > > * Linus Torvalds <torva...@linux-foundation.org> wrote: > > > So I think the only issue is that ->mm can become NULL when the thread group > > leader dies - a non-NULL mm should always be shared among all threads. > > Indeed, we do that in exit_mm().
Yes, > So we could add tsk->mm_leader or so, No, no, please do not. Just do something like for_each_process(p) { for_each_thread(p, t) { if (t->mm) { do_something(t->mm); break; } } } But either way I don't understand what protects this ->mm. Perhaps this needs find_lock_task_mm(). Oleg. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/