Skip to content

Commit 90f7816

Browse files
author
Christoph Hellwig
committed
unicore32: use generic swiotlb_ops
These are identical to the unicore32 ops, and would also support CMA if enabled on unicore32. Signed-off-by: Christoph Hellwig <[email protected]> Acked-by: Christian König <[email protected]>
1 parent 35bd507 commit 90f7816

File tree

4 files changed

+2
-58
lines changed

4 files changed

+2
-58
lines changed

arch/unicore32/include/asm/dma-mapping.h

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,18 +12,11 @@
1212
#ifndef __UNICORE_DMA_MAPPING_H__
1313
#define __UNICORE_DMA_MAPPING_H__
1414

15-
#ifdef __KERNEL__
16-
17-
#include <linux/mm_types.h>
18-
#include <linux/scatterlist.h>
1915
#include <linux/swiotlb.h>
2016

21-
extern const struct dma_map_ops swiotlb_dma_map_ops;
22-
2317
static inline const struct dma_map_ops *get_arch_dma_ops(struct bus_type *bus)
2418
{
25-
return &swiotlb_dma_map_ops;
19+
return &swiotlb_dma_ops;
2620
}
2721

28-
#endif /* __KERNEL__ */
2922
#endif

arch/unicore32/mm/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ config CPU_TLB_SINGLE_ENTRY_DISABLE
4242

4343
config SWIOTLB
4444
def_bool y
45+
select DMA_DIRECT_OPS
4546

4647
config IOMMU_HELPER
4748
def_bool SWIOTLB

arch/unicore32/mm/Makefile

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,6 @@
66
obj-y := extable.o fault.o init.o pgd.o mmu.o
77
obj-y += flush.o ioremap.o
88

9-
obj-$(CONFIG_SWIOTLB) += dma-swiotlb.o
10-
119
obj-$(CONFIG_MODULES) += proc-syms.o
1210

1311
obj-$(CONFIG_ALIGNMENT_TRAP) += alignment.o

arch/unicore32/mm/dma-swiotlb.c

Lines changed: 0 additions & 48 deletions
This file was deleted.

0 commit comments

Comments
 (0)