From: David Woodhouse Date: Sun, 9 Mar 2014 23:31:06 +0000 (-0700) Subject: iommu/vt-d: Remove pdev from intel_iommu_attach_device() X-Git-Tag: firefly_0821_release~176^2~4013^2^2~10 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=7207d8f925a74578a544f5beff8f840cfeebd12e;p=firefly-linux-kernel-4.4.55.git iommu/vt-d: Remove pdev from intel_iommu_attach_device() Signed-off-by: David Woodhouse --- diff --git a/drivers/iommu/intel-iommu.c b/drivers/iommu/intel-iommu.c index 0f5e6c911e85..37ce54b188f3 100644 --- a/drivers/iommu/intel-iommu.c +++ b/drivers/iommu/intel-iommu.c @@ -4147,13 +4147,12 @@ static int intel_iommu_attach_device(struct iommu_domain *domain, struct device *dev) { struct dmar_domain *dmar_domain = domain->priv; - struct pci_dev *pdev = to_pci_dev(dev); struct intel_iommu *iommu; int addr_width; u8 bus, devfn; - /* normally pdev is not mapped */ - if (unlikely(domain_context_mapped(&pdev->dev))) { + /* normally dev is not mapped */ + if (unlikely(domain_context_mapped(dev))) { struct dmar_domain *old_domain; old_domain = find_domain(dev);