From: Andrew Cooper <andrew.cooper3@citrix.com>
To: Keir Fraser <keir.xen@gmail.com>
Cc: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>,
Jan Beulich <JBeulich@novell.com>
Subject: Re: [PATCH 2 of 7] KEXEC BUG: nmi_shootdown_cpus doesn't look after the interrupt flag [Reformatted]
Date: Wed, 15 Jun 2011 12:01:09 +0100 [thread overview]
Message-ID: <4DF890F5.9090304@citrix.com> (raw)
In-Reply-To: <CA1CEC81.1C266%keir.xen@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 47 bytes --]
Reformatted as per Keir's suggestion.
~Andrew
[-- Attachment #2: kexec-fix-interrupts.patch --]
[-- Type: text/x-patch, Size: 1060 bytes --]
KEXEC BUG: nmi_shootdown_cpus doesn't look after the interrupt flag
nmi_shootdown_cpus is part of the kexec path, coming from a panic, and
as such can be called both with interrupts enabled or disabled. We
really dont want to accidentally set IF.
Therefore, use save/restore in preference to disable/enable.
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
diff -r a6f5c3a474e3 xen/arch/x86/crash.c
--- a/xen/arch/x86/crash.c Wed Jun 15 11:47:12 2011 +0100
+++ b/xen/arch/x86/crash.c Wed Jun 15 11:57:12 2011 +0100
@@ -57,7 +57,7 @@ static void nmi_shootdown_cpus(void)
{
unsigned long msecs;
- local_irq_disable();
+ BUG_ON(local_irq_is_enabled());
crashing_cpu = smp_processor_id();
local_irq_count(crashing_cpu) = 0;
@@ -79,14 +79,14 @@ static void nmi_shootdown_cpus(void)
__stop_this_cpu();
disable_IO_APIC();
-
- local_irq_enable();
}
void machine_crash_shutdown(void)
{
crash_xen_info_t *info;
+ local_irq_disable();
+
nmi_shootdown_cpus();
info = kexec_crash_save_info();
[-- Attachment #3: Type: text/plain, Size: 138 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
next prev parent reply other threads:[~2011-06-15 11:01 UTC|newest]
Thread overview: 43+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-06-13 17:02 [PATCH 0 of 7] Fix kexec in Xen (take 4) Andrew Cooper
2011-06-13 17:02 ` [PATCH 1 of 7] APIC BUG: fix potential Protection Fault during shutdown Andrew Cooper
2011-06-14 8:44 ` Jan Beulich
2011-06-14 9:44 ` Andrew Cooper
2011-06-13 17:02 ` [PATCH 2 of 7] KEXEC BUG: nmi_shootdown_cpus doesn't look after the interrupt flag Andrew Cooper
2011-06-14 8:46 ` Jan Beulich
2011-06-14 9:46 ` Keir Fraser
2011-06-15 11:01 ` Andrew Cooper [this message]
2011-06-14 9:51 ` Andrew Cooper
2011-06-13 17:02 ` [PATCH 3 of 7] IOMMU: Sanitise pointer work Andrew Cooper
2011-06-13 18:13 ` Keir Fraser
2011-06-14 9:53 ` Andrew Cooper
2011-06-14 11:51 ` Keir Fraser
2011-06-13 17:02 ` [PATCH 4 of 7] APIC: record local APIC state on boot Andrew Cooper
2011-06-14 8:57 ` Jan Beulich
2011-06-14 10:48 ` Ian Campbell
2011-06-14 11:21 ` Jan Beulich
2011-06-15 12:33 ` [PATCH 4 of 7] APIC: record local APIC state on boot [Reformatted] Andrew Cooper
2011-06-15 12:42 ` Keir Fraser
2011-06-15 13:38 ` Andrew Cooper
2011-06-15 14:49 ` Andrew Cooper
2011-06-15 12:50 ` Jan Beulich
2011-06-13 17:02 ` [PATCH 5 of 7] IOMMU VTD BUG: disable Extended Interrupt Mode when disabling Interupt Remapping Andrew Cooper
2011-06-14 9:02 ` Jan Beulich
2011-06-14 9:59 ` Andrew Cooper
2011-06-14 21:20 ` Kay, Allen M
2011-06-15 6:48 ` Jan Beulich
2011-06-15 7:45 ` Ian Campbell
2011-06-15 14:49 ` [PATCH 5 of 7] IOMMU VTD BUG: disable Extended Interrupt Mode when disabling Interupt Remapping [Reformatted] Andrew Cooper
2011-06-14 21:45 ` [PATCH 5 of 7] IOMMU VTD BUG: disable Extended Interrupt Mode when disabling Interupt Remapping Kay, Allen M
2011-06-13 17:02 ` [PATCH 6 of 7] IOMMU: add crash_shutdown iommu_op Andrew Cooper
2011-06-14 12:10 ` Keir Fraser
2011-06-15 12:50 ` Andrew Cooper
2011-06-14 22:15 ` Kay, Allen M
2011-06-15 13:06 ` Andrew Cooper
2011-06-15 16:39 ` Kay, Allen M
2011-06-15 15:00 ` [PATCH 6 of 7] IOMMU: add crash_shutdown iommu_op [Reformatted] Andrew Cooper
2011-06-13 17:02 ` [PATCH 7 of 7] KEXEC: correctly revert x2apic state when kexecing Andrew Cooper
2011-06-14 12:11 ` Keir Fraser
2011-06-14 13:05 ` Andrew Cooper
2011-06-13 18:15 ` [PATCH 0 of 7] Fix kexec in Xen (take 4) Keir Fraser
2011-06-16 13:05 ` Andrew Cooper
2011-06-16 13:13 ` Keir Fraser
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=4DF890F5.9090304@citrix.com \
--to=andrew.cooper3@citrix.com \
--cc=JBeulich@novell.com \
--cc=keir.xen@gmail.com \
--cc=xen-devel@lists.xensource.com \
/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.