printk: __pr_flush: use srcu console list iterator
authorJohn Ogness <john.ogness@linutronix.de>
Wed, 16 Nov 2022 16:21:28 +0000 (17:27 +0106)
committerPetr Mladek <pmladek@suse.com>
Fri, 2 Dec 2022 10:25:00 +0000 (11:25 +0100)
commiteb7f1ed2509c6223d960a7d69644a8eb506b13d0
treeecd6a939f5050316b7ecf741d188d283f3886138
parentfc956ae0de7fa25f99114609f21b76e7d38dc25c
printk: __pr_flush: use srcu console list iterator

Use srcu console list iteration for console list traversal.

Document why the console_lock is still necessary. Note that this
is a preparatory change for when console_lock no longer provides
synchronization for the console list.

Signed-off-by: John Ogness <john.ogness@linutronix.de>
Reviewed-by: Petr Mladek <pmladek@suse.com>
Signed-off-by: Petr Mladek <pmladek@suse.com>
Link: https://lore.kernel.org/r/20221116162152.193147-17-john.ogness@linutronix.de
kernel/printk/printk.c