All of lore.kernel.org
 help / color / mirror / Atom feed
From: tip-bot for Jiang Liu <tipbot@zytor.com>
To: linux-tip-commits@vger.kernel.org
Cc: bhelgaas@google.com, tglx@linutronix.de, tony.luck@intel.com,
	lv.zheng@intel.com, linux@eikelenboom.it, hpa@zytor.com,
	linux-kernel@vger.kernel.org, david.vrabel@citrix.com,
	konrad.wilk@oracle.com, mingo@kernel.org,
	jiang.liu@linux.intel.com, graeme.gregory@linaro.org
Subject: [tip:x86/urgent] x86/xen: Override ACPI IRQ management callback __acpi_unregister_gsi
Date: Tue, 20 Jan 2015 02:50:02 -0800	[thread overview]
Message-ID: <tip-8abb850a03a3a8b11a0e92949e5b99d9cc178e35@git.kernel.org> (raw)
In-Reply-To: <1421720467-7709-4-git-send-email-jiang.liu@linux.intel.com>

Commit-ID:  8abb850a03a3a8b11a0e92949e5b99d9cc178e35
Gitweb:     http://git.kernel.org/tip/8abb850a03a3a8b11a0e92949e5b99d9cc178e35
Author:     Jiang Liu <jiang.liu@linux.intel.com>
AuthorDate: Tue, 20 Jan 2015 10:21:07 +0800
Committer:  Thomas Gleixner <tglx@linutronix.de>
CommitDate: Tue, 20 Jan 2015 11:44:41 +0100

x86/xen: Override ACPI IRQ management callback __acpi_unregister_gsi

Xen overrides __acpi_register_gsi and leaves __acpi_unregister_gsi as is.
That means, an IRQ allocated by acpi_register_gsi_xen_hvm() or
acpi_register_gsi_xen() will be freed by acpi_unregister_gsi_ioapic(),
which may cause undesired effects. So override __acpi_unregister_gsi to
NULL for safety.

Signed-off-by: Jiang Liu <jiang.liu@linux.intel.com>
Tested-by: Sander Eikelenboom <linux@eikelenboom.it>
Cc: Tony Luck <tony.luck@intel.com>
Cc: xen-devel@lists.xenproject.org
Cc: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Cc: David Vrabel <david.vrabel@citrix.com>
Cc: Bjorn Helgaas <bhelgaas@google.com>
Cc: Graeme Gregory <graeme.gregory@linaro.org>
Cc: Lv Zheng <lv.zheng@intel.com>
Link: http://lkml.kernel.org/r/1421720467-7709-4-git-send-email-jiang.liu@linux.intel.com
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
---
 arch/x86/include/asm/acpi.h | 1 +
 arch/x86/pci/xen.c          | 2 ++
 2 files changed, 3 insertions(+)

diff --git a/arch/x86/include/asm/acpi.h b/arch/x86/include/asm/acpi.h
index 0ab4f9f..3a45668 100644
--- a/arch/x86/include/asm/acpi.h
+++ b/arch/x86/include/asm/acpi.h
@@ -50,6 +50,7 @@ void acpi_pic_sci_set_trigger(unsigned int, u16);
 
 extern int (*__acpi_register_gsi)(struct device *dev, u32 gsi,
 				  int trigger, int polarity);
+extern void (*__acpi_unregister_gsi)(u32 gsi);
 
 static inline void disable_acpi(void)
 {
diff --git a/arch/x86/pci/xen.c b/arch/x86/pci/xen.c
index 6e5e89c..9098d88 100644
--- a/arch/x86/pci/xen.c
+++ b/arch/x86/pci/xen.c
@@ -458,6 +458,7 @@ int __init pci_xen_hvm_init(void)
 	 * just how GSIs get registered.
 	 */
 	__acpi_register_gsi = acpi_register_gsi_xen_hvm;
+	__acpi_unregister_gsi = NULL;
 #endif
 
 #ifdef CONFIG_PCI_MSI
@@ -482,6 +483,7 @@ int __init pci_xen_initial_domain(void)
 	pci_msi_ignore_mask = 1;
 #endif
 	__acpi_register_gsi = acpi_register_gsi_xen;
+	__acpi_unregister_gsi = NULL;
 	/* Pre-allocate legacy irqs */
 	for (irq = 0; irq < nr_legacy_irqs(); irq++) {
 		int trigger, polarity;

  parent reply	other threads:[~2015-01-20 10:50 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-20  2:21 [Bugfix 0/3] Xen IRQ related hotfixes for v3.19 Jiang Liu
2015-01-20  2:21 ` [Bugfix 1/3] xen/pci: Kill function xen_setup_acpi_sci() Jiang Liu
2015-01-20  2:21 ` Jiang Liu
2015-01-20  9:54   ` David Vrabel
2015-01-20  9:54     ` David Vrabel
2015-01-20  9:54   ` David Vrabel
2015-01-20 10:49   ` [tip:x86/urgent] x86/xen: Treat SCI interrupt as normal GSI interrupt tip-bot for Jiang Liu
2015-01-20  2:21 ` [Bugfix 2/3] xen/irq, ACPI: Fix regression in xen PCI passthrough caused by cffe0a2b5a34 Jiang Liu
2015-01-20 10:49   ` [tip:x86/urgent] ACPI: pci: Do not clear pci_dev-> irq in acpi_pci_irq_disable() tip-bot for Jiang Liu
2015-01-20  2:21 ` [Bugfix 3/3] xen/irq: Override ACPI IRQ management callback __acpi_unregister_gsi Jiang Liu
2015-01-20  9:56   ` David Vrabel
2015-01-20  9:56   ` David Vrabel
2015-01-20 10:50   ` tip-bot for Jiang Liu [this message]
2015-01-20  2:21 ` Jiang Liu
2015-02-05 20:07 ` [Bugfix 0/3] Xen IRQ related hotfixes for v3.19 Sander Eikelenboom
2015-02-09  9:47   ` Stefan Bader
2015-02-09 12:12     ` Jiang Liu
2015-02-09 12:29       ` Stefan Bader
2015-02-09 16:09         ` Stefan Bader
2015-02-09 16:55           ` Sander Eikelenboom
2015-02-09 19:15           ` Sander Eikelenboom
2015-02-10 13:31             ` Stefan Bader
2015-02-09 12:17     ` Sander Eikelenboom

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=tip-8abb850a03a3a8b11a0e92949e5b99d9cc178e35@git.kernel.org \
    --to=tipbot@zytor.com \
    --cc=bhelgaas@google.com \
    --cc=david.vrabel@citrix.com \
    --cc=graeme.gregory@linaro.org \
    --cc=hpa@zytor.com \
    --cc=jiang.liu@linux.intel.com \
    --cc=konrad.wilk@oracle.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tip-commits@vger.kernel.org \
    --cc=linux@eikelenboom.it \
    --cc=lv.zheng@intel.com \
    --cc=mingo@kernel.org \
    --cc=tglx@linutronix.de \
    --cc=tony.luck@intel.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.