summaryrefslogtreecommitdiff
path: root/kernel/printk.c
diff options
context:
space:
mode:
authorPaul E. McKenney <paulmck@linux.vnet.ibm.com>2012-10-15 21:35:59 -0700
committerBen Hutchings <ben@decadent.org.uk>2014-04-02 00:59:00 +0100
commitd8db5f989887fe1d37757d02caf47cbc6cc49199 (patch)
treee1e9b0fe09e3b81f368b52c21bcb7541842cadae /kernel/printk.c
parent7f4d7e8fe42d3a34994055355694236f489c874f (diff)
printk: Fix scheduling-while-atomic problem in console_cpu_notify()
commit 85eae82a0855d49852b87deac8653e4ebc8b291f upstream. The console_cpu_notify() function runs with interrupts disabled in the CPU_DYING case. It therefore cannot block, for example, as will happen when it calls console_lock(). Therefore, remove the CPU_DYING leg of the switch statement to avoid this problem. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Reviewed-by: Srivatsa S. Bhat <srivatsa.bhat@linux.vnet.ibm.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Diffstat (limited to 'kernel/printk.c')
-rw-r--r--kernel/printk.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/kernel/printk.c b/kernel/printk.c
index 16688ecc918e..8fac434b0bcc 100644
--- a/kernel/printk.c
+++ b/kernel/printk.c
@@ -1165,7 +1165,6 @@ static int __cpuinit console_cpu_notify(struct notifier_block *self,
switch (action) {
case CPU_ONLINE:
case CPU_DEAD:
- case CPU_DYING:
case CPU_DOWN_FAILED:
case CPU_UP_CANCELED:
console_lock();