dma-mapping: add a dma_ops_bypass flag to struct device
authorChristoph Hellwig <hch@lst.de>
Mon, 23 Mar 2020 17:19:30 +0000 (18:19 +0100)
committerChristoph Hellwig <hch@lst.de>
Sun, 19 Jul 2020 07:29:29 +0000 (09:29 +0200)
commitd35834c64820c7ef397f8a244061d4450720540e
tree5a2df279a26c6175bfc9dbf9859c52468967aa70
parent2f9237d4f6df49b74c51cdac555b0a9979d0c237
dma-mapping: add a dma_ops_bypass flag to struct device

Several IOMMU drivers have a bypass mode where they can use a direct
mapping if the devices DMA mask is large enough.  Add generic support
to the core dma-mapping code to do that to switch those drivers to
a common solution.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Tested-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru>
include/linux/device.h
kernel/dma/Kconfig
kernel/dma/mapping.c