summaryrefslogtreecommitdiffstats
path: root/arch/mips/loongson64
diff options
context:
space:
mode:
authorAlexander Duyck2016-12-15 00:04:58 +0100
committerLinus Torvalds2016-12-15 01:04:07 +0100
commit9f318d470e37a470d65449f94a06165ea72dbce1 (patch)
tree03e6e15a8998785507f793c05500d09554e4e334 /arch/mips/loongson64
parentarch/microblaze: add option to skip DMA sync as a part of map and unmap (diff)
downloadkernel-qcow2-linux-9f318d470e37a470d65449f94a06165ea72dbce1.tar.gz
kernel-qcow2-linux-9f318d470e37a470d65449f94a06165ea72dbce1.tar.xz
kernel-qcow2-linux-9f318d470e37a470d65449f94a06165ea72dbce1.zip
arch/mips: add option to skip DMA sync as a part of map and unmap
This change allows us to pass DMA_ATTR_SKIP_CPU_SYNC which allows us to avoid invoking cache line invalidation if the driver will just handle it via a sync_for_cpu or sync_for_device call. Link: http://lkml.kernel.org/r/20161110113513.76501.32321.stgit@ahduyck-blue-test.jf.intel.com Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Keguang Zhang <keguang.zhang@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/mips/loongson64')
-rw-r--r--arch/mips/loongson64/common/dma-swiotlb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/mips/loongson64/common/dma-swiotlb.c b/arch/mips/loongson64/common/dma-swiotlb.c
index 1a80b6f73ab2..aab4fd681e1f 100644
--- a/arch/mips/loongson64/common/dma-swiotlb.c
+++ b/arch/mips/loongson64/common/dma-swiotlb.c
@@ -61,7 +61,7 @@ static int loongson_dma_map_sg(struct device *dev, struct scatterlist *sg,
int nents, enum dma_data_direction dir,
unsigned long attrs)
{
- int r = swiotlb_map_sg_attrs(dev, sg, nents, dir, 0);
+ int r = swiotlb_map_sg_attrs(dev, sg, nents, dir, attrs);
mb();
return r;