Merge branches 'pci/aer', 'pci/hotplug', 'pci/misc', 'pci/msi', 'pci/resource' and 'pci/virtualization' into next
* pci/aer: PCI/AER: Clear error status registers during enumeration and restore * pci/hotplug: PCI: pciehp: Queue power work requests in dedicated function * pci/misc: PCI: Turn off Request Attributes to avoid Chelsio T5 Completion erratum x86/PCI: Make pci_subsys_init() static PCI: Add builtin_pci_driver() to avoid registration boilerplate PCI: Remove unnecessary "if" statement * pci/msi: x86/PCI: Don't alloc pcibios-irq when MSI is enabled PCI/MSI: Export all remapped MSIs to sysfs attributes PCI: Disable MSI on SiS 761 * pci/resource: sparc/PCI: Add mem64 resource parsing for root bus PCI: Expand Enhanced Allocation BAR output PCI: Make Enhanced Allocation bitmasks more obvious PCI: Handle Enhanced Allocation capability for SR-IOV devices PCI: Add support for Enhanced Allocation devices PCI: Add Enhanced Allocation register entries PCI: Handle IORESOURCE_PCI_FIXED when assigning resources PCI: Handle IORESOURCE_PCI_FIXED when sizing resources PCI: Clear IORESOURCE_UNSET when reverting to firmware-assigned address * pci/virtualization: PCI: Fix sriov_enable() error path for pcibios_enable_sriov() failures PCI: Wait 1 second between disabling VFs and clearing NumVFs PCI: Reorder pcibios_sriov_disable() PCI: Remove VFs in reverse order if virtfn_add() fails PCI: Remove redundant validation of SR-IOV offset/stride registers PCI: Set SR-IOV NumVFs to zero after enumeration PCI: Enable SR-IOV ARI Capable Hierarchy before reading TotalVFs PCI: Don't try to restore VF BARs
This commit is contained in:
@@ -2230,6 +2230,7 @@ DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_VT3336, quirk_disab
|
||||
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_VT3351, quirk_disable_all_msi);
|
||||
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_VT3364, quirk_disable_all_msi);
|
||||
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_8380_0, quirk_disable_all_msi);
|
||||
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_SI, 0x0761, quirk_disable_all_msi);
|
||||
|
||||
/* Disable MSI on chipsets that are known to not support it */
|
||||
static void quirk_disable_msi(struct pci_dev *dev)
|
||||
@@ -3691,6 +3692,63 @@ DECLARE_PCI_FIXUP_CLASS_EARLY(0x1797, 0x6868, PCI_CLASS_NOT_DEFINED, 8,
|
||||
DECLARE_PCI_FIXUP_CLASS_EARLY(0x1797, 0x6869, PCI_CLASS_NOT_DEFINED, 8,
|
||||
quirk_tw686x_class);
|
||||
|
||||
/*
|
||||
* Per PCIe r3.0, sec 2.2.9, "Completion headers must supply the same
|
||||
* values for the Attribute as were supplied in the header of the
|
||||
* corresponding Request, except as explicitly allowed when IDO is used."
|
||||
*
|
||||
* If a non-compliant device generates a completion with a different
|
||||
* attribute than the request, the receiver may accept it (which itself
|
||||
* seems non-compliant based on sec 2.3.2), or it may handle it as a
|
||||
* Malformed TLP or an Unexpected Completion, which will probably lead to a
|
||||
* device access timeout.
|
||||
*
|
||||
* If the non-compliant device generates completions with zero attributes
|
||||
* (instead of copying the attributes from the request), we can work around
|
||||
* this by disabling the "Relaxed Ordering" and "No Snoop" attributes in
|
||||
* upstream devices so they always generate requests with zero attributes.
|
||||
*
|
||||
* This affects other devices under the same Root Port, but since these
|
||||
* attributes are performance hints, there should be no functional problem.
|
||||
*
|
||||
* Note that Configuration Space accesses are never supposed to have TLP
|
||||
* Attributes, so we're safe waiting till after any Configuration Space
|
||||
* accesses to do the Root Port fixup.
|
||||
*/
|
||||
static void quirk_disable_root_port_attributes(struct pci_dev *pdev)
|
||||
{
|
||||
struct pci_dev *root_port = pci_find_pcie_root_port(pdev);
|
||||
|
||||
if (!root_port) {
|
||||
dev_warn(&pdev->dev, "PCIe Completion erratum may cause device errors\n");
|
||||
return;
|
||||
}
|
||||
|
||||
dev_info(&root_port->dev, "Disabling No Snoop/Relaxed Ordering Attributes to avoid PCIe Completion erratum in %s\n",
|
||||
dev_name(&pdev->dev));
|
||||
pcie_capability_clear_and_set_word(root_port, PCI_EXP_DEVCTL,
|
||||
PCI_EXP_DEVCTL_RELAX_EN |
|
||||
PCI_EXP_DEVCTL_NOSNOOP_EN, 0);
|
||||
}
|
||||
|
||||
/*
|
||||
* The Chelsio T5 chip fails to copy TLP Attributes from a Request to the
|
||||
* Completion it generates.
|
||||
*/
|
||||
static void quirk_chelsio_T5_disable_root_port_attributes(struct pci_dev *pdev)
|
||||
{
|
||||
/*
|
||||
* This mask/compare operation selects for Physical Function 4 on a
|
||||
* T5. We only need to fix up the Root Port once for any of the
|
||||
* PFs. PF[0..3] have PCI Device IDs of 0x50xx, but PF4 is uniquely
|
||||
* 0x54xx so we use that one,
|
||||
*/
|
||||
if ((pdev->device & 0xff00) == 0x5400)
|
||||
quirk_disable_root_port_attributes(pdev);
|
||||
}
|
||||
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_CHELSIO, PCI_ANY_ID,
|
||||
quirk_chelsio_T5_disable_root_port_attributes);
|
||||
|
||||
/*
|
||||
* AMD has indicated that the devices below do not support peer-to-peer
|
||||
* in any system where they are found in the southbridge with an AMD
|
||||
|
Reference in New Issue
Block a user