mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 10:41:38 -04:00
exec: avoid propagating PF_NO_SETAFFINITY into userspace child
Userspace process doesn't want the PF_NO_SETAFFINITY, but its parent may be a kernel worker thread which has PF_NO_SETAFFINITY set, and this worker thread can do kernel_thread() to create the child. Clearing this flag in usersapce child to enable its migrating capability. Signed-off-by: Zhang Yi <[email protected]> Acked-by: Oleg Nesterov <[email protected]> Cc: Tejun Heo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
8d38f203b4
commit
b88fae644e
1 changed files with 2 additions and 2 deletions
|
|
@ -1087,8 +1087,8 @@ int flush_old_exec(struct linux_binprm * bprm)
|
|||
bprm->mm = NULL; /* We're using it now */
|
||||
|
||||
set_fs(USER_DS);
|
||||
current->flags &=
|
||||
~(PF_RANDOMIZE | PF_FORKNOEXEC | PF_KTHREAD | PF_NOFREEZE);
|
||||
current->flags &= ~(PF_RANDOMIZE | PF_FORKNOEXEC | PF_KTHREAD |
|
||||
PF_NOFREEZE | PF_NO_SETAFFINITY);
|
||||
flush_thread();
|
||||
current->personality &= ~bprm->per_clear;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue