Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Revert "printk: wake up all waiters"

This reverts commit 938ba4084abcf6fdd21d9078513c52f8fb9b00d0.

The wait queue @log_wait never has exclusive waiters, so there
is no need to use wake_up_interruptible_all(). Using
wake_up_interruptible() was the correct function to wake all
waiters.

Since there are no exclusive waiters, erroneously changing
wake_up_interruptible() to wake_up_interruptible_all() did not
result in any behavior change. However, using
wake_up_interruptible_all() on a wait queue without exclusive
waiters is fundamentally wrong.

Go back to using wake_up_interruptible() to wake all waiters.

Signed-off-by: John Ogness <john.ogness@linutronix.de>
Acked-by: Steven Rostedt (Google) <rostedt@goodmis.org>
Signed-off-by: Petr Mladek <pmladek@suse.com>
Link: https://lore.kernel.org/r/20220526203056.81123-1-john.ogness@linutronix.de

authored by

John Ogness and committed by
Petr Mladek
809631e2 537e62c8

+1 -1
+1 -1
kernel/printk/printk.c
··· 3904 3904 } 3905 3905 3906 3906 if (pending & PRINTK_PENDING_WAKEUP) 3907 - wake_up_interruptible_all(&log_wait); 3907 + wake_up_interruptible(&log_wait); 3908 3908 } 3909 3909 3910 3910 static DEFINE_PER_CPU(struct irq_work, wake_up_klogd_work) =