public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Martin Peres <martin.peres@linux.intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>, intel-gfx@lists.freedesktop.org
Cc: martin.peres@free.fr
Subject: Re: [PATCH] kernel/panic: Show the stacktrace after additional notifier messages
Date: Tue, 4 Sep 2018 11:55:38 +0300	[thread overview]
Message-ID: <03f11244-82b5-e5b9-2533-64bdb287ca09@linux.intel.com> (raw)
In-Reply-To: <20180903131745.30593-1-chris@chris-wilson.co.uk>

On 03/09/2018 16:17, Chris Wilson wrote:
> Most systems keep the last messages from the panic, and we value the
> stacktrace most, so dump it last in order to preserve it for
> post-mortems.

Thanks a lot for doing this Chris! I am hopping we'll get a lot of
usable traces out of that!

Acked-by: Martin Peres <martin.peres@linux.intel.com>
> 
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> ---
>  kernel/panic.c | 15 ++++++++-------
>  1 file changed, 8 insertions(+), 7 deletions(-)
> 
> diff --git a/kernel/panic.c b/kernel/panic.c
> index 8b2e002d52eb..c0334516cb15 100644
> --- a/kernel/panic.c
> +++ b/kernel/panic.c
> @@ -176,13 +176,6 @@ void panic(const char *fmt, ...)
>  	vsnprintf(buf, sizeof(buf), fmt, args);
>  	va_end(args);
>  	pr_emerg("Kernel panic - not syncing: %s\n", buf);
> -#ifdef CONFIG_DEBUG_BUGVERBOSE
> -	/*
> -	 * Avoid nested stack-dumping if a panic occurs during oops processing
> -	 */
> -	if (!test_taint(TAINT_DIE) && oops_in_progress <= 1)
> -		dump_stack();
> -#endif
>  
>  	/*
>  	 * If we have crashed and we have a crash kernel loaded let it handle
> @@ -217,6 +210,14 @@ void panic(const char *fmt, ...)
>  	 */
>  	atomic_notifier_call_chain(&panic_notifier_list, 0, buf);
>  
> +#ifdef CONFIG_DEBUG_BUGVERBOSE
> +	/*
> +	 * Avoid nested stack-dumping if a panic occurs during oops processing
> +	 */
> +	if (!test_taint(TAINT_DIE) && oops_in_progress <= 1)
> +		dump_stack();
> +#endif
> +
>  	/* Call flush even twice. It tries harder with a single online CPU */
>  	printk_safe_flush_on_panic();
>  	kmsg_dump(KMSG_DUMP_PANIC);
> 
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  parent reply	other threads:[~2018-09-04  8:56 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-09-03 13:17 [PATCH] kernel/panic: Show the stacktrace after additional notifier messages Chris Wilson
2018-09-03 13:52 ` ✓ Fi.CI.BAT: success for " Patchwork
2018-09-03 19:46 ` ✓ Fi.CI.IGT: " Patchwork
2018-09-04  8:55 ` Martin Peres [this message]
2018-09-04  8:58   ` [PATCH] " Chris Wilson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=03f11244-82b5-e5b9-2533-64bdb287ca09@linux.intel.com \
    --to=martin.peres@linux.intel.com \
    --cc=chris@chris-wilson.co.uk \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=martin.peres@free.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox