X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=lib%2Fnmi_backtrace.c;h=06410209197aee05849a696c1edde35060fdee98;hb=refs%2Fheads%2Faccepted%2Ftizen_8.0_unified;hp=f9e89001b52ebdc08e3f5e6afa8c44fbf576844d;hpb=eadeb06e7645f7a7ddbcfac39480be3892a60ae3;p=platform%2Fkernel%2Flinux-rpi.git diff --git a/lib/nmi_backtrace.c b/lib/nmi_backtrace.c index f9e8900..06410209 100644 --- a/lib/nmi_backtrace.c +++ b/lib/nmi_backtrace.c @@ -75,6 +75,12 @@ void nmi_trigger_cpumask_backtrace(const cpumask_t *mask, touch_softlockup_watchdog(); } + /* + * Force flush any remote buffers that might be stuck in IRQ context + * and therefore could not run their irq_work. + */ + printk_trigger_flush(); + clear_bit_unlock(0, &backtrace_flag); put_cpu(); } @@ -93,7 +99,7 @@ bool nmi_cpu_backtrace(struct pt_regs *regs) * Allow nested NMI backtraces while serializing * against other CPUs. */ - printk_cpu_lock_irqsave(flags); + raw_printk_cpu_lock_irqsave(flags); if (!READ_ONCE(backtrace_idle) && regs && cpu_in_idle(instruction_pointer(regs))) { pr_warn("NMI backtrace for cpu %d skipped: idling at %pS\n", cpu, (void *)instruction_pointer(regs)); @@ -104,7 +110,7 @@ bool nmi_cpu_backtrace(struct pt_regs *regs) else dump_stack(); } - printk_cpu_unlock_irqrestore(flags); + raw_printk_cpu_unlock_irqrestore(flags); cpumask_clear_cpu(cpu, to_cpumask(backtrace_mask)); return true; }