From: Michael Ellerman <mpe@ellerman.id.au>
To: "Cédric Le Goater" <clg@kaod.org>
Cc: linuxppc-dev@lists.ozlabs.org, "Greg Kurz" <groug@kaod.org>,
"Cédric Le Goater" <clg@kaod.org>
Subject: Re: [PATCH] powerpc/xive: Prevent page fault issues in the machine crash handler
Date: Tue, 12 Nov 2019 23:44:24 +1100 [thread overview]
Message-ID: <871rud2riv.fsf@mpe.ellerman.id.au> (raw)
In-Reply-To: <20191031063100.3864-1-clg@kaod.org>
Cédric Le Goater <clg@kaod.org> writes:
> When the machine crash handler is invoked, all interrupts are masked
> but interrupts which have not been started yet do not have an ESB page
> mapped in the Linux address space. This crashes the 'crash kexec'
> sequence on sPAPR guests.
This sounds like it needs a Fixes/stable tag?
I used these:
Fixes: 243e25112d06 ("powerpc/xive: Native exploitation of the XIVE interrupt controller")
Cc: stable@vger.kernel.org # v4.12+
Please tell me if you think that's wrong.
cheers
> diff --git a/arch/powerpc/sysdev/xive/common.c b/arch/powerpc/sysdev/xive/common.c
> index df832b09e3e9..f5fadbd2533a 100644
> --- a/arch/powerpc/sysdev/xive/common.c
> +++ b/arch/powerpc/sysdev/xive/common.c
> @@ -1035,6 +1035,15 @@ static int xive_irq_alloc_data(unsigned int virq, irq_hw_number_t hw)
> xd->target = XIVE_INVALID_TARGET;
> irq_set_handler_data(virq, xd);
>
> + /*
> + * Turn OFF by default the interrupt being mapped. A side
> + * effect of this check is the mapping the ESB page of the
> + * interrupt in the Linux address space. This prevents page
> + * fault issues in the crash handler which masks all
> + * interrupts.
> + */
> + xive_esb_read(xd, XIVE_ESB_SET_PQ_01);
> +
> return 0;
> }
>
> --
> 2.21.0
next prev parent reply other threads:[~2019-11-12 12:49 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-31 6:31 [PATCH] powerpc/xive: Prevent page fault issues in the machine crash handler Cédric Le Goater
2019-10-31 8:43 ` Greg Kurz
2019-11-12 12:44 ` Michael Ellerman [this message]
2019-11-12 12:48 ` Cédric Le Goater
2019-11-14 9:08 ` Michael Ellerman
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=871rud2riv.fsf@mpe.ellerman.id.au \
--to=mpe@ellerman.id.au \
--cc=clg@kaod.org \
--cc=groug@kaod.org \
--cc=linuxppc-dev@lists.ozlabs.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.