public inbox for linuxppc-dev@ozlabs.org 
 help / color / mirror / Atom feed
From: Michael Ellerman <patch-notifications@ellerman•id.au>
To: Breno Leitao <leitao@debian•org>, linuxppc-dev@lists•ozlabs.org
Cc: Breno Leitao <leitao@debian•org>
Subject: Re: powerpc/xmon: Fix invocation inside lock region
Date: Sat,  8 Dec 2018 00:07:01 +1100 (AEDT)	[thread overview]
Message-ID: <43BCRT1lMvz9s8J@ozlabs.org> (raw)
In-Reply-To: <1541697162-1926-1-git-send-email-leitao@debian.org>

On Thu, 2018-11-08 at 17:12:42 UTC, Breno Leitao wrote:
> Currently xmon needs to get devtree_lock (through rtas_token()) during its
> invocation (at crash time). If there is a crash while devtree_lock is being
> held, then xmon tries to get the lock but spins forever and never get into
> the interactive debugger, as in the following case:
> 
> 	int *ptr = NULL;
> 	raw_spin_lock_irqsave(&devtree_lock, flags);
> 	*ptr = 0xdeadbeef;
> 
> This patch avoids calling rtas_token(), thus trying to get the same lock,
> at crash time. This new mechanism proposes getting the token at
> initialization time (xmon_init()) and just consuming it at crash time.
> 
> This would allow xmon to be possible invoked independent of devtree_lock
> being held or not.
> 
> Signed-off-by: Breno Leitao <leitao@debian•org>
> Reviewed-by: Thiago Jung Bauermann <bauerman@linux•ibm.com>

Applied to powerpc next, thanks.

https://git.kernel.org/powerpc/c/8d4a862276a9c30a269d368d324fb5

cheers

      parent reply	other threads:[~2018-12-07 13:26 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-11-08 17:12 [PATCH] powerpc/xmon: Fix invocation inside lock region Breno Leitao
2018-11-09 16:22 ` Thiago Jung Bauermann
2018-12-07 13:07 ` Michael Ellerman [this message]

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=43BCRT1lMvz9s8J@ozlabs.org \
    --to=patch-notifications@ellerman$(echo .)id.au \
    --cc=leitao@debian$(echo .)org \
    --cc=linuxppc-dev@lists$(echo .)ozlabs.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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