summaryrefslogtreecommitdiff
path: root/include/linux/printk.h
diff options
context:
space:
mode:
authorJohn Ogness <john.ogness@linutronix.de>2022-07-15 08:16:42 +0206
committerPetr Mladek <pmladek@suse.com>2022-07-15 10:52:11 +0200
commit9023ca0866250d268b047f21e1392e7a81277a54 (patch)
treece45ae54cb0696dc167787b35ba4df28e6017458 /include/linux/printk.h
parent07a22b61946f0b80065b0ddcc703b715f84355f5 (diff)
printk: do not wait for consoles when suspended
The console_stop() and console_start() functions call pr_flush(). When suspending, these functions are called by the serial subsystem while the serial port is suspended. In this scenario, if there are any pending messages, a call to pr_flush() will always result in a timeout because the serial port cannot make forward progress. This causes longer suspend and resume times. Add a check in pr_flush() so that it will immediately timeout if the consoles are suspended. Fixes: 3b604ca81202 ("printk: add pr_flush()") Reported-by: Todd Brandt <todd.e.brandt@linux.intel.com> Signed-off-by: John Ogness <john.ogness@linutronix.de> Tested-by: Todd Brandt <todd.e.brandt@linux.intel.com> Signed-off-by: Petr Mladek <pmladek@suse.com> Link: https://lore.kernel.org/r/20220715061042.373640-2-john.ogness@linutronix.de
Diffstat (limited to 'include/linux/printk.h')
0 files changed, 0 insertions, 0 deletions