Re: task_numa_fault() && TASK_DEAD

From: Hugh Dickins
Date: Thu Sep 04 2014 - 15:16:45 EST


On Thu, 4 Sep 2014, Oleg Nesterov wrote:
> On 09/04, Peter Zijlstra wrote:
> > On Wed, Sep 03, 2014 at 06:08:19PM +0200, Oleg Nesterov wrote:
> >
> > > And a stupid (really, I don't understand this code) question:
> > >
> > > /* for example, ksmd faulting in a user's mm */
> > > if (!p->mm)
> > > return;

I don't understand your difficulty with that, I thought the comment
was helpful enough. Does the original commit comment help?

commit 2832bc19f6668fd00116f61f821105040599ef8b
Author: Hugh Dickins <hughd@xxxxxxxxxx>
Date: Wed Dec 19 17:42:16 2012 -0800

sched: numa: ksm: fix oops in task_numa_placment()

task_numa_placement() oopsed on NULL p->mm when task_numa_fault() got
called in the handling of break_ksm() for ksmd. That might be a
peculiar case, which perhaps KSM could takes steps to avoid? but it's
more robust if task_numa_placement() allows for such a possibility.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/