From: Brice Goglin <brice@myri.com>
To: linux-pci@atrey.karlin.mff.cuni.cz
Cc: LKML <linux-kernel@vger.kernel.org>
Subject: [PATCH 5/8] Whitelist non-PCI-E chipsets that are known to support MSI
Date: Sun, 18 Jun 2006 21:09:14 -0400 [thread overview]
Message-ID: <20060619010913.GF29950@myri.com> (raw)
In-Reply-To: <20060619010544.GA29950@myri.com>
[PATCH 5/8] Whitelist non-PCI-E chipsets that are known to support MSI
With MSI being disabled by default on non-PCI-E chipsets, we have
to explicitely whitelist chipsets that support MSI and set the
PCI_BUS_FLAGS_MSI flag.
Add a generic quirk quirk_msi_supported() to do so, and enable it
for all Intel chipsets.
Signed-off-by: Brice Goglin <brice@myri.com>
---
drivers/pci/quirks.c | 12 ++++++++++++
include/linux/pci.h | 1 +
2 files changed, 13 insertions(+)
Index: linux-mm/drivers/pci/quirks.c
===================================================================
--- linux-mm.orig/drivers/pci/quirks.c 2006-06-17 23:07:41.000000000 -0400
+++ linux-mm/drivers/pci/quirks.c 2006-06-17 23:11:01.000000000 -0400
@@ -1556,6 +1556,18 @@
}
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x1460, quirk_p64h2_1k_io);
+/* Mark MSI bus flags on chipset that are known to support it */
+static void __devinit quirk_msi_supported(struct pci_dev *dev)
+{
+ if (dev->subordinate) {
+ printk(KERN_WARNING "PCI: MSI quirk detected. "
+ "PCI_BUS_FLAGS_MSI set for %s subordinate bus.\n",
+ pci_name(dev));
+ dev->subordinate->bus_flags |= PCI_BUS_FLAGS_MSI;
+ }
+}
+DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, PCI_ANY_ID, quirk_msi_supported);
+
/* Returns 1 if the HT MSI capability is found and enabled */
static pci_bus_flags_t __devinit msi_ht_cap_enabled(struct pci_dev *dev)
{
Index: linux-mm/include/linux/pci.h
===================================================================
--- linux-mm.orig/include/linux/pci.h 2006-06-17 22:11:04.000000000 -0400
+++ linux-mm/include/linux/pci.h 2006-06-17 23:11:30.000000000 -0400
@@ -97,6 +97,7 @@
typedef unsigned short __bitwise pci_bus_flags_t;
enum pci_bus_flags {
PCI_BUS_FLAGS_NO_MSI = (__force pci_bus_flags_t) 1,
+ PCI_BUS_FLAGS_MSI = (__force pci_bus_flags_t) 2,
};
struct pci_cap_saved_state {
next prev parent reply other threads:[~2006-06-19 1:09 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-06-19 1:05 [PATCH 0/8] Improve MSI detection v2 Brice Goglin
2006-06-19 1:07 ` [PATCH 1/8] Rename PCI_CAP_ID_HT_IRQCONF into PCI_CAP_ID_HT Brice Goglin
2006-06-19 1:08 ` [PATCH 2/8] Factorize common MSI detection code from pci_enable_msi() and msix() Brice Goglin
2006-06-19 1:08 ` [PATCH 3/8] Blacklist PCI-E chipsets depending on Hypertransport MSI capabality Brice Goglin
2006-06-19 1:08 ` [PATCH 4/8] Stop inheriting bus flags and check root chipset bus flags instead Brice Goglin
2006-06-19 1:09 ` Brice Goglin [this message]
2006-06-19 1:09 ` [PATCH 6/8] Disable MSI by default on non-PCI-E chipset Brice Goglin
2006-06-19 1:09 ` [PATCH 7/8] Drop existing quirks that disable MSI on some non PCI-E chipsets Brice Goglin
2006-06-19 1:10 ` [PATCH 8/8] Drop pci_msi_quirk Brice Goglin
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=20060619010913.GF29950@myri.com \
--to=brice@myri.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@atrey.karlin.mff.cuni.cz \
/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