Merge tag 'trace-v4.19' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt...
[muen/linux.git] / kernel / trace / trace.c
index 4ecd8950b513b2c2db59712eff2909023281ebc3..bf6f1d70484dc02a449fa71b73b753649b698715 100644 (file)
@@ -8291,6 +8291,7 @@ void ftrace_dump(enum ftrace_dump_mode oops_dump_mode)
        tracing_off();
 
        local_irq_save(flags);
+       printk_nmi_direct_enter();
 
        /* Simulate the iterator */
        trace_init_global_iter(&iter);
@@ -8370,7 +8371,8 @@ void ftrace_dump(enum ftrace_dump_mode oops_dump_mode)
        for_each_tracing_cpu(cpu) {
                atomic_dec(&per_cpu_ptr(iter.trace_buffer->data, cpu)->disabled);
        }
-       atomic_dec(&dump_running);
+       atomic_dec(&dump_running);
+       printk_nmi_direct_exit();
        local_irq_restore(flags);
 }
 EXPORT_SYMBOL_GPL(ftrace_dump);