linux-stable/arch/powerpc/kexec
John Ogness 85e3e7fbbb printk: remove NMI tracking
All NMI contexts are handled the same as the safe context: store the
message and defer printing. There is no need to have special NMI
context tracking for this. Using in_nmi() is enough.

There are several parts of the kernel that are manually calling into
the printk NMI context tracking in order to cause general printk
deferred printing:

    arch/arm/kernel/smp.c
    arch/powerpc/kexec/crash.c
    kernel/trace/trace.c

For arm/kernel/smp.c and powerpc/kexec/crash.c, provide a new
function pair printk_deferred_enter/exit that explicitly achieves the
same objective.

For ftrace, remove the printk context manipulation completely. It was
added in commit 03fc7f9c99 ("printk/nmi: Prevent deadlock when
accessing the main log buffer in NMI"). The purpose was to enforce
storing messages directly into the ring buffer even in NMI context.
It really should have only modified the behavior in NMI context.
There is no need for a special behavior any longer. All messages are
always stored directly now. The console deferring is handled
transparently in vprintk().

Signed-off-by: John Ogness <john.ogness@linutronix.de>
[pmladek@suse.com: Remove special handling in ftrace.c completely.
Signed-off-by: Petr Mladek <pmladek@suse.com>
Link: https://lore.kernel.org/r/20210715193359.25946-5-john.ogness@linutronix.de
2021-07-26 15:09:44 +02:00
..
core.c mm: replace CONFIG_NEED_MULTIPLE_NODES with CONFIG_NUMA 2021-06-29 10:53:55 -07:00
core_32.c
core_64.c powerpc/book3s64/keys/kuap: Reset AMR/IAMR values on kexec 2020-07-20 22:57:59 +10:00
crash.c printk: remove NMI tracking 2021-07-26 15:09:44 +02:00
elf_64.c powerpc: If kexec_build_elf_info() fails return immediately from elf64_load() 2021-04-26 16:28:26 -05:00
file_load.c powerpc: Delete unused function delete_fdt_mem_rsv() 2021-03-08 12:06:30 -07:00
file_load_64.c powerpc/kexec_file: Use current CPU info while setting up FDT 2021-05-04 22:26:57 +10:00
Makefile powerpc: Move arch independent ima kexec functions to drivers/of/kexec.c 2021-03-08 12:06:29 -07:00
ranges.c powerpc/kexec_file: Avoid stomping memory used by special regions 2020-07-29 23:47:53 +10:00
relocate_32.S