diff options
author | Rik van Riel <[email protected]> | 2014-02-18 17:12:44 -0500 |
---|---|---|
committer | Thomas Gleixner <[email protected]> | 2014-02-21 21:27:10 +0100 |
commit | 3cf1962cdbf6b3a9e3ef21116d215bbab350ea37 (patch) | |
tree | eb6a13b68e96e4be4f1da403b720db17849150c6 | |
parent | 495163420ab5398c84af96ca3eae2c6aa4a140da (diff) |
sched,numa: add cond_resched to task_numa_work
Normally task_numa_work scans over a fairly small amount of memory,
but it is possible to run into a large unpopulated part of virtual
memory, with no pages mapped. In that case, task_numa_work can run
for a while, and it may make sense to reschedule as required.
Cc: [email protected]
Cc: Andrea Arcangeli <[email protected]>
Signed-off-by: Rik van Riel <[email protected]>
Reported-by: Xing Gang <[email protected]>
Tested-by: Chegu Vinod <[email protected]>
Signed-off-by: Peter Zijlstra <[email protected]>
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Thomas Gleixner <[email protected]>
-rw-r--r-- | kernel/sched/fair.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c index 966cc2bfcb77..78157099b167 100644 --- a/kernel/sched/fair.c +++ b/kernel/sched/fair.c @@ -1757,6 +1757,8 @@ void task_numa_work(struct callback_head *work) start = end; if (pages <= 0) goto out; + + cond_resched(); } while (end != vma->vm_end); } |