linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Nicholas Piggin <npiggin@gmail.com>
To: Mahesh J Salgaonkar <mahesh@linux.vnet.ibm.com>
Cc: linuxppc-dev <linuxppc-dev@ozlabs.org>,
	Benjamin Herrenschmidt <benh@kernel.crashing.org>,
	Paul Mackerras <paulus@samba.org>
Subject: Re: [RFC PATCH 5/7] powerpc/book3s: Don't turn on the MSR[ME] bit until opal processes the reason.
Date: Tue, 21 Feb 2017 12:47:28 +1000	[thread overview]
Message-ID: <20170221124728.675af9f9@roar.ozlabs.ibm.com> (raw)
In-Reply-To: <148764197591.19289.17096730042146758117.stgit@jupiter.in.ibm.com>

On Tue, 21 Feb 2017 07:22:56 +0530
Mahesh J Salgaonkar <mahesh@linux.vnet.ibm.com> wrote:

> From: Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com>
> 
> Delay it until we are done with machine_check_early() call. Turn on MSR[ME]
> once opal is done with processing MCE.

Why? This seems like quite a regression -- the MCE handler today
has about 60 instructions and 30 l/st with ME clear.


> 
> Signed-off-by: Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com>
> ---
>  arch/powerpc/kernel/exceptions-64s.S |   12 ++++++------
>  1 file changed, 6 insertions(+), 6 deletions(-)
> 
> diff --git a/arch/powerpc/kernel/exceptions-64s.S b/arch/powerpc/kernel/exceptions-64s.S
> index d39d611..fa768a7 100644
> --- a/arch/powerpc/kernel/exceptions-64s.S
> +++ b/arch/powerpc/kernel/exceptions-64s.S
> @@ -238,6 +238,12 @@ BEGIN_FTR_SECTION
>  	std	r9,_CCR(r1)		/* Save CR in stackframe */
>  	/* Save r9 through r13 from EXMC save area to stack frame. */
>  	EXCEPTION_PROLOG_COMMON_2(PACA_EXMC)
> +	std	r0,GPR0(r1)	/* Save r0 */
> +	EXCEPTION_PROLOG_COMMON_3(0x200)
> +	bl	save_nvgprs
> +	addi	r3,r1,STACK_FRAME_OVERHEAD
> +	bl	machine_check_early
> +	std	r3,RESULT(r1)	/* Save result */
>  	mfmsr	r11			/* get MSR value */
>  	ori	r11,r11,MSR_ME		/* turn on ME bit */
>  	ori	r11,r11,MSR_RI		/* turn on RI bit */
> @@ -345,12 +351,6 @@ EXC_COMMON_BEGIN(machine_check_common)
>  	 * ME=1, MMU (IR=0 and DR=0) off and using MC emergency stack.
>  	 */
>  EXC_COMMON_BEGIN(machine_check_handle_early)
> -	std	r0,GPR0(r1)	/* Save r0 */
> -	EXCEPTION_PROLOG_COMMON_3(0x200)
> -	bl	save_nvgprs
> -	addi	r3,r1,STACK_FRAME_OVERHEAD
> -	bl	machine_check_early
> -	std	r3,RESULT(r1)	/* Save result */
>  	ld	r12,_MSR(r1)
>  #ifdef	CONFIG_PPC_P7_NAP
>  	/*
> 

  reply	other threads:[~2017-02-21  2:47 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-21  1:51 [RFC PATCH 0/7] Machine check handling for Power9 with bacward compatibility Mahesh J Salgaonkar
2017-02-21  1:51 ` [RFC PATCH 1/7] powerpc/book3s: Move machine check event structure to opal-api.h Mahesh J Salgaonkar
2017-02-21  2:35   ` Nicholas Piggin
2017-02-21  6:51     ` Mahesh Jagannath Salgaonkar
2017-02-21  1:52 ` [RFC PATCH 2/7] powerpc/book3s: mce: Call opal mce handler to extract MCE error reason Mahesh J Salgaonkar
2017-02-21  1:52 ` [RFC PATCH 3/7] powerpc/book3s: mce: Process the MCE event and recover if possible Mahesh J Salgaonkar
2017-02-21  1:52 ` [RFC PATCH 4/7] powerpc/book3s: Print additional MCE errors introduced in power9 Mahesh J Salgaonkar
2017-02-21  1:52 ` [RFC PATCH 5/7] powerpc/book3s: Don't turn on the MSR[ME] bit until opal processes the reason Mahesh J Salgaonkar
2017-02-21  2:47   ` Nicholas Piggin [this message]
2017-02-21  4:17     ` Mahesh Jagannath Salgaonkar
2017-02-21  4:43       ` Nicholas Piggin
2017-02-21  1:53 ` [RFC PATCH 6/7] powerpc/book3s: Display more info for MCE error console log Mahesh J Salgaonkar
2017-02-21  1:53 ` [RFC PATCH 7/7] powerpc/book3s: Display task info for MCE error in user mode Mahesh J Salgaonkar

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=20170221124728.675af9f9@roar.ozlabs.ibm.com \
    --to=npiggin@gmail.com \
    --cc=benh@kernel.crashing.org \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=mahesh@linux.vnet.ibm.com \
    --cc=paulus@samba.org \
    /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;
as well as URLs for NNTP newsgroup(s).