linux/arch/um/kernel
John Ogness 3860e7c57f um: kmsg_dump: only dump when no output console available
The initial intention of the UML kmsg_dumper is to dump the kernel
buffers to stdout if there is no console available to perform the
regular crash output.

However, if ttynull was registered as a console, no crash output was
seen. Commit e23fe90dec ("um: kmsg_dumper: always dump when not tty
console") tried to fix this by performing the kmsg_dump unless the
stdio console was behind /dev/console or enabled. But this allowed
kmsg dumping to occur even if other non-stdio consoles will output
the crash output. Also, a console being the driver behind
/dev/console has nothing to do with a crash scenario.

Restore the initial intention by dumping the kernel buffers to stdout
only if a non-ttynull console is registered and enabled. Also add
detailed comments so that it is clear why these rules are applied.

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-8-john.ogness@linutronix.de
2022-12-02 11:24:59 +01:00
..
skas Peter Zijlstra says: 2022-01-11 17:24:45 -08:00
asm-offsets.c um: get rid of pointless include "..." where include <...> will do 2012-10-09 22:28:45 +02:00
config.c.in um: Add SPDX headers to files in arch/um/kernel/ 2019-09-15 21:37:17 +02:00
dtb.c um: Fix order of dtb unflatten/early init 2022-03-11 10:44:43 +01:00
dyn.lds.S UML: add support for KASAN under x86_64 2022-07-17 23:35:22 +02:00
early_printk.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
exec.c ptrace/um: Replace PT_DTRACE with TIF_SINGLESTEP 2022-05-11 14:33:33 -05:00
exitcode.c proc: convert everything to "struct proc_ops" 2020-02-04 03:05:26 +00:00
gprof_syms.c um: Add SPDX headers to files in arch/um/kernel/ 2019-09-15 21:37:17 +02:00
initrd.c um: Extract load file helper from initrd.c 2021-12-22 20:32:36 +01:00
ioport.c um: add PCI over virtio emulation driver 2021-06-17 21:45:43 +02:00
irq.c um: add PCI over virtio emulation driver 2021-06-17 21:45:43 +02:00
kmsg_dump.c um: kmsg_dump: only dump when no output console available 2022-12-02 11:24:59 +01:00
ksyms.c um: rename set_signals() to um_set_signals() 2021-12-21 21:13:44 +01:00
load_file.c um: Extract load file helper from initrd.c 2021-12-22 20:32:36 +01:00
maccess.c maccess: rename probe_kernel_{read,write} to copy_{from,to}_kernel_nofault 2020-06-17 10:57:41 -07:00
Makefile um: Add devicetree support 2021-12-22 20:35:01 +01:00
mem.c - The usual batches of cleanups from Baoquan He, Muchun Song, Miaohe 2022-08-05 16:32:45 -07:00
physmem.c um: Fix comment typo 2022-09-19 23:05:46 +02:00
process.c treewide: use prandom_u32_max() when possible, part 1 2022-10-11 17:42:55 -06:00
ptrace.c ptrace/um: Replace PT_DTRACE with TIF_SINGLESTEP 2022-05-11 14:33:33 -05:00
reboot.c um: Add SPDX headers to files in arch/um/kernel/ 2019-09-15 21:37:17 +02:00
sigio.c um: Support dynamic IRQ allocation 2020-12-13 22:22:08 +01:00
signal.c ptrace/um: Replace PT_DTRACE with TIF_SINGLESTEP 2022-05-11 14:33:33 -05:00
stacktrace.c UML: add support for KASAN under x86_64 2022-07-17 23:35:22 +02:00
sysrq.c um: Prevent KASAN splats in dump_stack() 2022-09-19 22:58:48 +02:00
time.c um: time-travel/signals: fix ndelay() in interrupt 2021-06-17 21:44:52 +02:00
tlb.c um: remove vma linked list walk 2022-09-26 19:46:20 -07:00
trap.c mm: avoid unnecessary page fault retires on shared memory types 2022-06-16 19:48:27 -07:00
um_arch.c This pull request contains the following changes for UML: 2022-10-14 18:14:48 -07:00
um_arch.h um: Add devicetree support 2021-12-22 20:35:01 +01:00
umid.c uml: Remove the initialization of statics to 0 2022-09-19 23:10:07 +02:00
uml.lds.S arch: um: Fix build for statically linked UML w/ constructors 2022-07-17 23:14:34 +02:00
vmlinux.lds.S