[PATCH 0/1]: (Was: kmod: avoid propagating PF_NO_SETAFFINITY intouserspace child)

From: Oleg Nesterov
Date: Thu Nov 14 2013 - 06:54:36 EST


On 11/14, Oleg Nesterov wrote:
>
> Yes, but kernel_thread() is called by the worker thread which has
> PF_NO_SETAFFINITY, this flag is copied to child->flags.

Hmm, and it seems that create_worker() needs a minor fix, please see
the patch.

> Looks like Zhang is right... But I'd suggest to change flush_old_exec()
> instead (see "current->flags &= ...").

Yes.


But... May be we should (also?) change copy_flags() to clear
PF_NO_SETAFFINITY? Probably not, this can lead to the subtle behaviour
changes. But I am wondering if there is any kthread() which relies on
PF_NO_SETAFFINITY copied by kernel_thread().

Oleg.

--
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/