]> git.baikalelectronics.ru Git - kernel.git/commit
dma-mapping: explicitly wire up ->mmap and ->get_sgtable
authorChristoph Hellwig <hch@lst.de>
Tue, 6 Aug 2019 12:01:50 +0000 (15:01 +0300)
committerChristoph Hellwig <hch@lst.de>
Wed, 4 Sep 2019 09:13:18 +0000 (11:13 +0200)
commit0c463499ec85b59402112c63d309798eb8648af4
tree021c07b01f104492a5d049a885bc8fb931839c34
parentdebb8283b9015ac37c81cabbb2bea55381f7ff2b
dma-mapping: explicitly wire up ->mmap and ->get_sgtable

While the default ->mmap and ->get_sgtable implementations work for the
majority of our dma_map_ops impementations they are inherently safe
for others that don't use the page allocator or CMA and/or use their
own way of remapping not covered by the common code.  So remove the
defaults if these methods are not wired up, but instead wire up the
default implementations for all safe instances.

Fixes: fc34f2e2ceed ("dma-mapping: always provide the dma_map_ops based implementation")
Signed-off-by: Christoph Hellwig <hch@lst.de>
15 files changed:
arch/alpha/kernel/pci_iommu.c
arch/ia64/hp/common/sba_iommu.c
arch/ia64/sn/pci/pci_dma.c
arch/mips/jazz/jazzdma.c
arch/powerpc/kernel/dma-iommu.c
arch/powerpc/platforms/ps3/system-bus.c
arch/powerpc/platforms/pseries/vio.c
arch/s390/pci/pci_dma.c
arch/x86/kernel/amd_gart_64.c
arch/x86/kernel/pci-calgary_64.c
drivers/iommu/amd_iommu.c
drivers/iommu/intel-iommu.c
drivers/parisc/ccio-dma.c
drivers/parisc/sba_iommu.c
kernel/dma/mapping.c