aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/include/linux/dma-direct.h
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2018-08-16 15:30:39 +0300
committerChristoph Hellwig <hch@lst.de>2018-10-19 08:43:46 +0200
commitdff8d6c1ed584de65aac40494d3e7468c50980c3 (patch)
tree998f71d7b0951479f511df2ac236eaf850120a06 /include/linux/dma-direct.h
parentswiotlb: do not panic on mapping failures (diff)
downloadwireguard-linux-dff8d6c1ed584de65aac40494d3e7468c50980c3.tar.xz
wireguard-linux-dff8d6c1ed584de65aac40494d3e7468c50980c3.zip
swiotlb: remove the overflow buffer
Like all other dma mapping drivers just return an error code instead of an actual memory buffer. The reason for the overflow buffer was that at the time swiotlb was invented there was no way to check for dma mapping errors, but this has long been fixed. Signed-off-by: Christoph Hellwig <hch@lst.de> Acked-by: Catalin Marinas <catalin.marinas@arm.com> Reviewed-by: Robin Murphy <robin.murphy@arm.com> Reviewed-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Diffstat (limited to 'include/linux/dma-direct.h')
-rw-r--r--include/linux/dma-direct.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/dma-direct.h b/include/linux/dma-direct.h
index fbca184ff5a0..bd73e7a91410 100644
--- a/include/linux/dma-direct.h
+++ b/include/linux/dma-direct.h
@@ -5,6 +5,8 @@
#include <linux/dma-mapping.h>
#include <linux/mem_encrypt.h>
+#define DIRECT_MAPPING_ERROR 0
+
#ifdef CONFIG_ARCH_HAS_PHYS_TO_DMA
#include <asm/dma-direct.h>
#else