lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 26 Apr 2016 11:13:46 +1000
From:	Stephen Rothwell <sfr@...b.auug.org.au>
To:	Bjorn Helgaas <bhelgaas@...gle.com>
Cc:	linux-next@...r.kernel.org, linux-kernel@...r.kernel.org,
	Jacek Lawrynowicz <jacek.lawrynowicz@...el.com>,
	Joerg Roedel <jroedel@...e.de>
Subject: linux-next: build failure after merge of the pci tree

Hi Bjorn,

After merging the pci tree, today's linux-next build (x86_64 allmodconfig)
failed like this:

drivers/iommu/amd_iommu.c: In function 'get_alias':
drivers/iommu/amd_iommu.c:266:22: error: 'PCI_DEV_FLAGS_DMA_ALIAS_DEVFN' undeclared (first use in this function)
   pdev->dev_flags |= PCI_DEV_FLAGS_DMA_ALIAS_DEVFN;
                      ^
drivers/iommu/amd_iommu.c:266:22: note: each undeclared identifier is reported only once for each function it appears in
drivers/iommu/amd_iommu.c:267:7: error: 'struct pci_dev' has no member named 'dma_alias_devfn'  
   pdev->dma_alias_devfn = ivrs_alias & 0xff;
       ^

Caused by commit

  338c3149a221 ("PCI: Add support for multiple DMA aliases")

interacting with commit

  e3156048346c ("iommu/amd: Fix checking of pci dma aliases")

from Linus' tree (added before v4.6-rc5).

I added the following merge fix patch (which makes it build, but may need
more work):

From: Stephen Rothwell <sfr@...b.auug.org.au>
Date: Tue, 26 Apr 2016 11:07:25 +1000
Subject: [PATCH] iommu/amd: fix up for aliases API change

Signed-off-by: Stephen Rothwell <sfr@...b.auug.org.au>
---
 drivers/iommu/amd_iommu.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/iommu/amd_iommu.c b/drivers/iommu/amd_iommu.c
index 5efadad4615b..3839fd2865a6 100644
--- a/drivers/iommu/amd_iommu.c
+++ b/drivers/iommu/amd_iommu.c
@@ -263,8 +263,7 @@ static u16 get_alias(struct device *dev)
 	 */
 	if (pci_alias == devid &&
 	    PCI_BUS_NUM(ivrs_alias) == pdev->bus->number) {
-		pdev->dev_flags |= PCI_DEV_FLAGS_DMA_ALIAS_DEVFN;
-		pdev->dma_alias_devfn = ivrs_alias & 0xff;
+		pci_add_dma_alias(pdev, ivrs_alias & 0xff);
 		pr_info("AMD-Vi: Added PCI DMA alias %02x.%d for %s\n",
 			PCI_SLOT(ivrs_alias), PCI_FUNC(ivrs_alias),
 			dev_name(dev));
-- 
2.7.0

-- 
Cheers,
Stephen Rothwell

Powered by blists - more mailing lists