diff options
author | Andrey Konovalov <andrey.konovalov@linaro.org> | 2015-10-08 21:58:05 +0300 |
---|---|---|
committer | Andrey Konovalov <andrey.konovalov@linaro.org> | 2015-10-08 21:58:05 +0300 |
commit | af31ff8a1496c68089c3a2ff50d45c64ec765d34 (patch) | |
tree | 5671465bb6ba3a17b66ce04eb7fab4220c70a73b /arch/arm/mm/dma-mapping.c | |
parent | 535f95d0a6164c60f3c34a0864d653e016decde1 (diff) | |
parent | 52bddd7cb59adbc9ce56ebd03ad63936cf7cd1e5 (diff) |
Automatically merging tracking-integration-linux-qcomlt into merge-linux-linaroll-20151008.0
Conflicting files:
arch/arm64/configs/defconfig
Diffstat (limited to 'arch/arm/mm/dma-mapping.c')
-rw-r--r-- | arch/arm/mm/dma-mapping.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/arch/arm/mm/dma-mapping.c b/arch/arm/mm/dma-mapping.c index 1a7815e5421b..7e2b75f8b046 100644 --- a/arch/arm/mm/dma-mapping.c +++ b/arch/arm/mm/dma-mapping.c @@ -2126,6 +2126,15 @@ void arch_setup_dma_ops(struct device *dev, u64 dma_base, u64 size, struct dma_map_ops *dma_ops; dev->archdata.dma_coherent = coherent; + + /* + * Don't override the dma_ops if they have already been set. Ideally + * this should be the only location where dma_ops are set, remove this + * check when all other callers of set_dma_ops will have disappeared. + */ + if (dev->archdata.dma_ops) + return; + if (arm_setup_iommu_dma_ops(dev, dma_base, size, iommu)) dma_ops = arm_get_iommu_dma_map_ops(coherent); else |