diff options
author | Alexander Duyck <alexander.h.duyck@intel.com> | 2009-03-05 13:57:28 -0500 |
---|---|---|
committer | Matthew Wilcox <willy@linux.intel.com> | 2009-03-12 15:09:41 -0400 |
commit | 649426efcfbc67a8b033497151816cbac9fd0cfa (patch) | |
tree | ee73b86fa404171dbddba24751944c1557d1b280 /drivers | |
parent | 16b71fdf97599f1b1b7f38418ee9922d9f117396 (diff) |
PCI: Add PCI quirk to disable L0s ASPM state for 82575 and 82598
This patch is intended to disable L0s ASPM link state for 82598 (ixgbe)
parts due to the fact that it is possible to corrupt TX data when coming
back out of L0s on some systems. The workaround had been added for 82575
(igb) previously, but did not use the ASPM api. This quirk uses the ASPM
api to prevent the ASPM subsystem from re-enabling the L0s state.
Instead of adding the fix in igb to the ixgbe driver as well it was
decided to move it into a pci quirk. It is necessary to move the fix out
of the driver and into a pci quirk in order to prevent the issue from
occuring prior to driver load to handle the possibility of the device being
passed to a VM via direct assignment.
Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
CC: Jesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: Matthew Wilcox <willy@linux.intel.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/pci/quirks.c | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c index f20d55368edb..1a7c48d71dc7 100644 --- a/drivers/pci/quirks.c +++ b/drivers/pci/quirks.c | |||
@@ -23,6 +23,7 @@ | |||
23 | #include <linux/acpi.h> | 23 | #include <linux/acpi.h> |
24 | #include <linux/kallsyms.h> | 24 | #include <linux/kallsyms.h> |
25 | #include <linux/dmi.h> | 25 | #include <linux/dmi.h> |
26 | #include <linux/pci-aspm.h> | ||
26 | #include "pci.h" | 27 | #include "pci.h" |
27 | 28 | ||
28 | int isa_dma_bridge_buggy; | 29 | int isa_dma_bridge_buggy; |
@@ -1749,6 +1750,30 @@ static void __devinit quirk_e100_interrupt(struct pci_dev *dev) | |||
1749 | } | 1750 | } |
1750 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, PCI_ANY_ID, quirk_e100_interrupt); | 1751 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, PCI_ANY_ID, quirk_e100_interrupt); |
1751 | 1752 | ||
1753 | /* | ||
1754 | * The 82575 and 82598 may experience data corruption issues when transitioning | ||
1755 | * out of L0S. To prevent this we need to disable L0S on the pci-e link | ||
1756 | */ | ||
1757 | static void __devinit quirk_disable_aspm_l0s(struct pci_dev *dev) | ||
1758 | { | ||
1759 | dev_info(&dev->dev, "Disabling L0s\n"); | ||
1760 | pci_disable_link_state(dev, PCIE_LINK_STATE_L0S); | ||
1761 | } | ||
1762 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x10a7, quirk_disable_aspm_l0s); | ||
1763 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x10a9, quirk_disable_aspm_l0s); | ||
1764 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x10b6, quirk_disable_aspm_l0s); | ||
1765 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x10c6, quirk_disable_aspm_l0s); | ||
1766 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x10c7, quirk_disable_aspm_l0s); | ||
1767 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x10c8, quirk_disable_aspm_l0s); | ||
1768 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x10d6, quirk_disable_aspm_l0s); | ||
1769 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x10db, quirk_disable_aspm_l0s); | ||
1770 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x10dd, quirk_disable_aspm_l0s); | ||
1771 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x10e1, quirk_disable_aspm_l0s); | ||
1772 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x10ec, quirk_disable_aspm_l0s); | ||
1773 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x10f1, quirk_disable_aspm_l0s); | ||
1774 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x10f4, quirk_disable_aspm_l0s); | ||
1775 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x1508, quirk_disable_aspm_l0s); | ||
1776 | |||
1752 | static void __devinit fixup_rev1_53c810(struct pci_dev* dev) | 1777 | static void __devinit fixup_rev1_53c810(struct pci_dev* dev) |
1753 | { | 1778 | { |
1754 | /* rev 1 ncr53c810 chips don't set the class at all which means | 1779 | /* rev 1 ncr53c810 chips don't set the class at all which means |