Adding support for Relaxed ordering on a non-root device

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi

I am writing to you regarding your commits titled: 
1. a99b646afa8a PCI: Disable PCIe Relaxed Ordering if unsupported 
2. 87e09cdec4da PCI: Disable Relaxed Ordering for some Intel processors

While adding support to relaxed ordering on Mellanox Ethernet driver I
tried to avoid the Intel's bug with pcie_relaxed_ordering_enabled.
Expecting this to return False on Haswell and Broadwell CPU. I run
this API on: Intel(R) Xeon(R) CPU E5-2650 v3 @ 2.30GHz (I think it is
a Haswell, right?) and the API returned True. What am I missing?

In addition, I saw your comment in pci_configure_relaxed_ordering
(pasted below) the non-root ports are not handled since Peer-to-Peer
DMA is another can of warms. Could you elaborate on the complexity?
What is the effort to extend this to non-root ports?

Thanks,
Aya

---------------------------------------------------------------------
static void pci_configure_relaxed_ordering(struct pci_dev *dev)
{
	struct pci_dev *root;

	/* PCI_EXP_DEVICE_RELAX_EN is RsvdP in VFs */
	if (dev->is_virtfn)
		return;

	if (!pcie_relaxed_ordering_enabled(dev))
		return;

	/*
	 * For now, we only deal with Relaxed Ordering issues with Root
	 * Ports. Peer-to-Peer DMA is another can of worms.
	 */
	root = pci_find_pcie_root_port(dev);
	if (!root)
		return;

	if (root->dev_flags & PCI_DEV_FLAGS_NO_RELAXED_ORDERING) {
		pcie_capability_clear_word(dev, PCI_EXP_DEVCTL,
					   PCI_EXP_DEVCTL_RELAX_EN);
		pci_info(dev, "Relaxed Ordering disabled because the Root Port didn't support it\n");
	}
}





[Index of Archives]     [DMA Engine]     [Linux Coverity]     [Linux USB]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Greybus]

  Powered by Linux