Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b253d5f3 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull PCI fix from Bjorn Helgaas:
 "If an IOMMU is present, ignore the P2PDMA whitelist we added for v5.2
  because we don't yet know how to support P2PDMA in that case (Logan
  Gunthorpe)"

* tag 'pci-v5.2-fixes-1' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci:
  PCI/P2PDMA: Ignore root complex whitelist when an IOMMU is present
parents f4102766 6dbbd053
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -18,6 +18,7 @@
#include <linux/percpu-refcount.h>
#include <linux/random.h>
#include <linux/seq_buf.h>
#include <linux/iommu.h>

struct pci_p2pdma {
	struct gen_pool *pool;
@@ -299,6 +300,9 @@ static bool root_complex_whitelist(struct pci_dev *dev)
	struct pci_dev *root = pci_get_slot(host->bus, PCI_DEVFN(0, 0));
	unsigned short vendor, device;

	if (iommu_present(dev->dev.bus))
		return false;

	if (!root)
		return false;