aboutsummaryrefslogtreecommitdiff
path: root/kernel/exit.h
diff options
context:
space:
mode:
authorJohn Ogness2024-02-07 14:46:59 +0106
committerPetr Mladek2024-02-07 17:23:18 +0100
commitb1c4c67a5e90db8fbdb5b5504fe16e17b564cca8 (patch)
tree0047ff01ef33dd17258710727fbc2c31aa052688 /kernel/exit.h
parentac7d7844c64d15603daa3e905a311ddcfbb4bc91 (diff)
printk: ringbuffer: Skip non-finalized records in panic
Normally a reader will stop once reaching a non-finalized record. However, when a panic happens, writers from other CPUs (or an interrupted context on the panic CPU) may have been writing a record and were unable to finalize it. The panic CPU will reserve/commit/finalize its panic records, but these will be located after the non-finalized records. This results in panic() not flushing the panic messages. Extend _prb_read_valid() to skip over non-finalized records if on the panic CPU. Fixes: 896fbe20b4e2 ("printk: use the lockless ringbuffer") Signed-off-by: John Ogness <john.ogness@linutronix.de> Reviewed-by: Petr Mladek <pmladek@suse.com> Link: https://lore.kernel.org/r/20240207134103.1357162-11-john.ogness@linutronix.de Signed-off-by: Petr Mladek <pmladek@suse.com>
Diffstat (limited to 'kernel/exit.h')
0 files changed, 0 insertions, 0 deletions