summaryrefslogtreecommitdiff
path: root/kernel/printk/nbcon.c
diff options
context:
space:
mode:
authorPetr Mladek <pmladek@suse.com>2025-12-01 14:16:28 +0100
committerPetr Mladek <pmladek@suse.com>2025-12-01 14:16:28 +0100
commit3a9a3f5fb224155bb719c337527ffdffca0c1d7f (patch)
tree59c1e3dfc5d87e92442891e53d8d1fb566e1eeb3 /kernel/printk/nbcon.c
parentb1e6c41ef9daf5a975a677c3570c5f805c6c7514 (diff)
parent66e7c1e0ee08cfb6db64f8f3f6e5a3cc930145c8 (diff)
Merge branch 'rework/suspend-fixes' into for-linus
Diffstat (limited to 'kernel/printk/nbcon.c')
-rw-r--r--kernel/printk/nbcon.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/kernel/printk/nbcon.c b/kernel/printk/nbcon.c
index 89c182007b20..0bbb03fde35d 100644
--- a/kernel/printk/nbcon.c
+++ b/kernel/printk/nbcon.c
@@ -1302,6 +1302,13 @@ void nbcon_kthreads_wake(void)
if (!printk_kthreads_running)
return;
+ /*
+ * It is not allowed to call this function when console irq_work
+ * is blocked.
+ */
+ if (WARN_ON_ONCE(console_irqwork_blocked))
+ return;
+
cookie = console_srcu_read_lock();
for_each_console_srcu(con) {
if (!(console_srcu_read_flags(con) & CON_NBCON))
@@ -1892,7 +1899,7 @@ void nbcon_device_release(struct console *con)
if (console_trylock())
console_unlock();
} else if (ft.legacy_offload) {
- printk_trigger_flush();
+ defer_console_output();
}
}
console_srcu_read_unlock(cookie);