]> www.infradead.org Git - linux.git/commitdiff
dma-mapping: remove <asm/dma-contiguous.h>
authorChristoph Hellwig <hch@lst.de>
Fri, 11 Sep 2020 09:04:43 +0000 (11:04 +0200)
committerChristoph Hellwig <hch@lst.de>
Tue, 6 Oct 2020 05:07:05 +0000 (07:07 +0200)
Just provide a weak default definition of dma_contiguous_early_fixup and
let arm override it.

Signed-off-by: Christoph Hellwig <hch@lst.de>
arch/arm/include/asm/dma-contiguous.h [deleted file]
arch/arm/mm/dma-mapping.c
include/asm-generic/Kbuild
include/asm-generic/dma-contiguous.h [deleted file]
include/linux/dma-map-ops.h
kernel/dma/contiguous.c

diff --git a/arch/arm/include/asm/dma-contiguous.h b/arch/arm/include/asm/dma-contiguous.h
deleted file mode 100644 (file)
index d785187..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0 */
-#ifndef ASMARM_DMA_CONTIGUOUS_H
-#define ASMARM_DMA_CONTIGUOUS_H
-
-#ifdef __KERNEL__
-#ifdef CONFIG_DMA_CMA
-
-#include <linux/types.h>
-
-void dma_contiguous_early_fixup(phys_addr_t base, unsigned long size);
-
-#endif
-#endif
-
-#endif
index 154c24cec94c74cbe568c041e9593d40ad4d13e0..911fc6ea26071eda7e2256d41cfdd70b3b9a9f21 100644 (file)
@@ -34,7 +34,6 @@
 #include <asm/dma-iommu.h>
 #include <asm/mach/map.h>
 #include <asm/system_info.h>
-#include <asm/dma-contiguous.h>
 #include <xen/swiotlb-xen.h>
 
 #include "dma.h"
index 74b0612601dd1bdbf2918a56978b097106d57bf3..62ebdc731ee23934d6f898b4fb26c7008770feed 100644 (file)
@@ -16,7 +16,6 @@ mandatory-y += current.h
 mandatory-y += delay.h
 mandatory-y += device.h
 mandatory-y += div64.h
-mandatory-y += dma-contiguous.h
 mandatory-y += dma-mapping.h
 mandatory-y += dma.h
 mandatory-y += emergency-restart.h
diff --git a/include/asm-generic/dma-contiguous.h b/include/asm-generic/dma-contiguous.h
deleted file mode 100644 (file)
index f24b0f9..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0 */
-#ifndef _ASM_GENERIC_DMA_CONTIGUOUS_H
-#define _ASM_GENERIC_DMA_CONTIGUOUS_H
-
-#include <linux/types.h>
-
-static inline void
-dma_contiguous_early_fixup(phys_addr_t base, unsigned long size) { }
-
-#endif
index 474fc81bd4921c0daae3c4b34a2f218a62887b3f..7912f5d00ed95007f66f10c17e817fdabf37f1d2 100644 (file)
@@ -116,6 +116,8 @@ bool dma_release_from_contiguous(struct device *dev, struct page *pages,
                                 int count);
 struct page *dma_alloc_contiguous(struct device *dev, size_t size, gfp_t gfp);
 void dma_free_contiguous(struct device *dev, struct page *page, size_t size);
+
+void dma_contiguous_early_fixup(phys_addr_t base, unsigned long size);
 #else /* CONFIG_DMA_CMA */
 static inline struct cma *dev_get_cma_area(struct device *dev)
 {
index 6bfb763fff6fca9d138ce3382362f509abbf93ce..a2ee330a3749ecc8ecd52e294cc7aacb943567d4 100644 (file)
@@ -44,7 +44,6 @@
 #endif
 
 #include <asm/page.h>
-#include <asm/dma-contiguous.h>
 
 #include <linux/memblock.h>
 #include <linux/err.h>
@@ -212,6 +211,11 @@ void __init dma_contiguous_reserve(phys_addr_t limit)
        }
 }
 
+void __weak
+dma_contiguous_early_fixup(phys_addr_t base, unsigned long size)
+{
+}
+
 /**
  * dma_contiguous_reserve_area() - reserve custom contiguous area
  * @size: Size of the reserved area (in bytes),