summaryrefslogtreecommitdiffstats
path: root/include/linux/dma-mapping.h
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2018-05-28 12:47:57 +0200
committerChristoph Hellwig <hch@lst.de>2018-05-28 12:48:25 +0200
commit0ead51c3fbd15a4bc91e984f1b18b5c9422fbb02 (patch)
treead7bf76bbc559ce3fa320ae03ce562e286d2ddc4 /include/linux/dma-mapping.h
parent098afd981744061d37eb4d40bc3f755438570afb (diff)
downloadlinux-0ead51c3fbd15a4bc91e984f1b18b5c9422fbb02.tar.gz
linux-0ead51c3fbd15a4bc91e984f1b18b5c9422fbb02.tar.bz2
linux-0ead51c3fbd15a4bc91e984f1b18b5c9422fbb02.zip
x86/pci-dma: switch the VIA 32-bit DMA quirk to use the struct device flag
Instead of globally disabling > 32bit DMA using the arch_dma_supported hook walk the PCI bus under the actually affected bridge and mark every device with the dma_32bit_limit flag. This also gets rid of the arch_dma_supported hook entirely. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'include/linux/dma-mapping.h')
-rw-r--r--include/linux/dma-mapping.h11
1 files changed, 0 insertions, 11 deletions
diff --git a/include/linux/dma-mapping.h b/include/linux/dma-mapping.h
index 15e4b4e9cc20..f9cc309507d9 100644
--- a/include/linux/dma-mapping.h
+++ b/include/linux/dma-mapping.h
@@ -572,14 +572,6 @@ static inline int dma_mapping_error(struct device *dev, dma_addr_t dma_addr)
return 0;
}
-/*
- * This is a hack for the legacy x86 forbid_dac and iommu_sac_force. Please
- * don't use this in new code.
- */
-#ifndef arch_dma_supported
-#define arch_dma_supported(dev, mask) (1)
-#endif
-
static inline void dma_check_mask(struct device *dev, u64 mask)
{
if (sme_active() && (mask < (((u64)sme_get_me_mask() << 1) - 1)))
@@ -592,9 +584,6 @@ static inline int dma_supported(struct device *dev, u64 mask)
if (!ops)
return 0;
- if (!arch_dma_supported(dev, mask))
- return 0;
-
if (!ops->dma_supported)
return 1;
return ops->dma_supported(dev, mask);