aboutsummaryrefslogtreecommitdiffstats
path: root/mm/oom_kill.c
diff options
context:
space:
mode:
authorAndrew Morton <akpm@osdl.org>2006-03-02 05:54:28 -0500
committerLinus Torvalds <torvalds@g5.osdl.org>2006-03-02 11:33:07 -0500
commit140ffcec4def3ee3af7565b2cf1d3b2580f7e180 (patch)
tree466da398c345f5b6f2760c124beec84403b35655 /mm/oom_kill.c
parentb1e2d907cb748ef40b180184f36e594d35f12ba6 (diff)
[PATCH] out_of_memory() locking fix
I seem to have lost this read_unlock(). While we're there, let's turn that interruptible sleep unto uninterruptible, so we don't get a busywait if signal_pending(). (Again. We seem to have a habit of doing this). Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'mm/oom_kill.c')
-rw-r--r--mm/oom_kill.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/mm/oom_kill.c b/mm/oom_kill.c
index c86c737d2433..78747afad6b0 100644
--- a/mm/oom_kill.c
+++ b/mm/oom_kill.c
@@ -355,6 +355,7 @@ retry:
355 } 355 }
356 356
357out: 357out:
358 read_unlock(&tasklist_lock);
358 cpuset_unlock(); 359 cpuset_unlock();
359 if (mm) 360 if (mm)
360 mmput(mm); 361 mmput(mm);
@@ -364,5 +365,5 @@ out:
364 * retry to allocate memory unless "p" is current 365 * retry to allocate memory unless "p" is current
365 */ 366 */
366 if (!test_thread_flag(TIF_MEMDIE)) 367 if (!test_thread_flag(TIF_MEMDIE))
367 schedule_timeout_interruptible(1); 368 schedule_timeout_uninterruptible(1);
368} 369}