aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Documentation/scheduler
diff options
context:
space:
mode:
authorLai Jiangshan <laijs@cn.fujitsu.com>2014-06-04 16:25:15 +0800
committerIngo Molnar <mingo@kernel.org>2014-09-09 06:47:27 +0200
commit5cd038f53ed9ec7a17ab7d536a727363080f4210 (patch)
tree69516cf3b08e4bf060bd45dd0545646dea724c17 /Documentation/scheduler
parentsched, time: Atomically increment stime & utime (diff)
downloadwireguard-linux-5cd038f53ed9ec7a17ab7d536a727363080f4210.tar.xz
wireguard-linux-5cd038f53ed9ec7a17ab7d536a727363080f4210.zip
sched: Migrate waking tasks
Current code can fail to migrate a waking task (silently) when TTWU_QUEUE is enabled. When a task is waking, it is pending on the wake_list of the rq, but it is not queued (task->on_rq == 0). In this case, set_cpus_allowed_ptr() and __migrate_task() will not migrate it because its invisible to them. This behavior is incorrect, because the task has been already woken, it will be running on the wrong CPU without correct placement until the next wake-up or update for cpus_allowed. To fix this problem, we need to finish the wakeup (so they appear on the runqueue) before we migrate them. Reported-by: Sasha Levin <sasha.levin@oracle.com> Reported-by: Jason J. Herne <jjherne@linux.vnet.ibm.com> Tested-by: Jason J. Herne <jjherne@linux.vnet.ibm.com> Signed-off-by: Lai Jiangshan <laijs@cn.fujitsu.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Link: http://lkml.kernel.org/r/538ED7EB.5050303@cn.fujitsu.com Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'Documentation/scheduler')
0 files changed, 0 insertions, 0 deletions