Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1343098

Re: [linux-next, x86_64] no backtrace after "printk/nmi: generic solution for safe printk in NMI"

From Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com>
Newsgroups linux.kernel
Subject Re: [linux-next, x86_64] no backtrace after "printk/nmi: generic solution for safe printk in NMI"
Date 2016-02-25 11:40 +0100
Message-ID <r61uW-2sM-25@gated-at.bofh.it> (permalink)
References <r60Ix-1NY-15@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On (02/25/16 18:46), Sergey Senozhatsky wrote:
> Hello Petr,
> 
> seem that commit b927968830676373caf4241e80d8b447133f84b2
> 	Author: Petr Mladek <pmladek@suse.com>
> 	Date:   Thu Feb 25 13:00:35 2016 +1100
> 
> 	    printk/nmi: generic solution for safe printk in NMI
>     
> 	    printk() takes some locks and could not be used a safe way in NMI context.
>     
> 	    The chance of a deadlock is real especially when printing stacks from all
> 	    CPUs.  This particular problem has been addressed on x86 by the commit
> 	    a9edc8809328 ("x86/nmi: Perform a safe NMI stack trace on all CPUs").
>     
> 	    The patchset brings two big advantages.  First, it makes the NMI
> 	    backtraces safe on all architectures for free.  Second, it makes all NMI
> 	    messages almost safe on all architectures (the temporary buffer is
> 	    limited.  We still should keep the number of messages in NMI context at
> 	    minimum).
> 	[..]
> 
> 
> makes my x86_64 boxen unhappy, I see no CPU backtraces and no panic messages
> on HARDLOCKUPs (CONFIG_BOOTPARAM_HARDLOCKUP_PANIC_VALUE=1).
> 
> does it work for you?

just for note,

I reverted (next-20160225) the following commits:

bdcdb76696402e1a0821db6bcccb2b4de4049f27
7ad17383fa428d1c89d2be95d00806f33df69dfd
054a26c149a5add6d27d154f2025ee2605d9f25d
c2dbc8fd415835a71b0dee0f3f3a353d116f8731
3fd57f62ac2a8de6b402bf5f6aeb3a7d1e3f11a3
3ff0033c1e878b8bd8fce6efcd1b432b24f1d321

-- still no HARDLOCKUP panic backtraces on a console.

reverting of

b927968830676373caf4241e80d8b447133f84b2  (plus MIPS config conflict resolution)

-- fixed the problem for me. I've tested several times.


the sample code that I use for testing is very simple (well.. but it
does the job):

---

       u64 s, e;
       unsigned long flags;

       local_irq_save(flags);
       s = local_clock() >> 31UL;
       pr_err(">>>>>>>>>>>>>>>>>START_THE_TEST\n");
       while (1) {
               e = local_clock() >> 31UL;
               if (e - s > %%YOUR_WATCHDOG_THRESHOLD%%)
                       goto out;
       }
out:
       pr_err(">>>>>>>>>>>>>>>>>END_THE_TEST\n");
       local_irq_restore(flags);

---



most likely I'll be able to reply only tomorrow (in case if there will be any questions).


	-ss

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[linux-next, x86_64] no backtrace after "printk/nmi: generic  solution for safe printk in NMI" Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2016-02-25 10:50 +0100
  Re: [linux-next, x86_64] no backtrace after "printk/nmi: generic  solution for safe printk in NMI" Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2016-02-25 11:40 +0100
    Re: [linux-next, x86_64] no backtrace after "printk/nmi: generic  solution for safe printk in NMI" Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2016-02-26 04:40 +0100

csiph-web