linux/kernel
Paul Jackson 505970b96e [PATCH] cpuset oom lock fix
The problem, reported in:

  http://bugzilla.kernel.org/show_bug.cgi?id=5859

and by various other email messages and lkml posts is that the cpuset hook
in the oom (out of memory) code can try to take a cpuset semaphore while
holding the tasklist_lock (a spinlock).

One must not sleep while holding a spinlock.

The fix seems easy enough - move the cpuset semaphore region outside the
tasklist_lock region.

This required a few lines of mechanism to implement.  The oom code where
the locking needs to be changed does not have access to the cpuset locks,
which are internal to kernel/cpuset.c only.  So I provided a couple more
cpuset interface routines, available to the rest of the kernel, which
simple take and drop the lock needed here (cpusets callback_sem).

Signed-off-by: Paul Jackson <pj@sgi.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-01-14 18:27:10 -08:00
..
irq
power
.gitignore
acct.c [PATCH] move capable() to capability.h 2006-01-11 18:42:13 -08:00
audit.c
auditsc.c
capability.c [PATCH] move capable() to capability.h 2006-01-11 18:42:13 -08:00
compat.c
configs.c
cpu.c
cpuset.c [PATCH] cpuset oom lock fix 2006-01-14 18:27:10 -08:00
dma.c
exec_domain.c
exit.c [PATCH] Unlinline a bunch of other functions 2006-01-14 18:27:06 -08:00
extable.c
fork.c [PATCH] x86_64: Inclusion of ScaleMP vSMP architecture patches - vsmp_align 2006-01-11 19:05:01 -08:00
futex.c
hrtimer.c [hrtimer] Enforce resolution as lower limit of intervals 2006-01-12 11:47:34 +01:00
intermodule.c
itimer.c
kallsyms.c
Kconfig.hz
Kconfig.preempt
kexec.c [PATCH] move capable() to capability.h 2006-01-11 18:42:13 -08:00
kfifo.c
kmod.c
kprobes.c [PATCH] kprobes: fix unloading of self probed module 2006-01-11 18:42:12 -08:00
ksysfs.c
kthread.c
Makefile
module.c [PATCH] move capable() to capability.h 2006-01-11 18:42:13 -08:00
mutex-debug.c
mutex-debug.h
mutex.c
mutex.h
panic.c
params.c
pid.c
posix-cpu-timers.c
posix-timers.c [PATCH] Unlinline a bunch of other functions 2006-01-14 18:27:06 -08:00
printk.c
profile.c
ptrace.c [PATCH] move capable() to capability.h 2006-01-11 18:42:13 -08:00
rcupdate.c
rcutorture.c
resource.c
sched.c [PATCH] Unlinline a bunch of other functions 2006-01-14 18:27:06 -08:00
seccomp.c
signal.c [PATCH] Unlinline a bunch of other functions 2006-01-14 18:27:06 -08:00
softirq.c
softlockup.c
spinlock.c
stop_machine.c
sys_ni.c
sys.c [PATCH] move capable() to capability.h 2006-01-11 18:42:13 -08:00
sysctl.c [PATCH] s390: spinlock fixes 2006-01-14 18:27:09 -08:00
time.c [PATCH] move capable() to capability.h 2006-01-11 18:42:13 -08:00
timer.c
uid16.c [PATCH] move capable() to capability.h 2006-01-11 18:42:13 -08:00
user.c
wait.c
workqueue.c [PATCH] Unlinline a bunch of other functions 2006-01-14 18:27:06 -08:00