summaryrefslogtreecommitdiff
path: root/crypto/camellia_generic.c
diff options
context:
space:
mode:
authorAlex Smith <alex.smith@imgtec.com>2015-07-30 14:03:42 +0300
committerRalf Baechle <ralf@linux-mips.org>2015-09-03 13:08:01 +0300
commit8c172467be36f7c9591e59b647e4cd342ce2ef41 (patch)
tree741969a23012f1875758f4f4b1b9175d1d5fd55e /crypto/camellia_generic.c
parentc4687b15a8487e8ef028814a301a88958baf72bc (diff)
downloadlinux-8c172467be36f7c9591e59b647e4cd342ce2ef41.tar.xz
MIPS: Add implementation of dma_map_ops.mmap()
The generic implementation of dma_map_ops.mmap(), dma_common_mmap(), is not correct for non-coherent devices. It expects to be passed a virtual address previously returned by dma_alloc_coherent(), which for a non-coherent device will return a KSEG1 address. It then attempts to convert that virtual address to a physical address using virt_to_page() which will yield an incorrect address. Also, dma_common_mmap() does not handle the DMA_ATTR_WRITE_COMBINE attribute, and therefore dma_mmap_writecombine() will not actually set the appropriate pgprot_t flags for write combining. This patch adds an implementation of dma_map_ops.mmap() that correctly handles KSEG1 addresses, and enables write combining when requested. Signed-off-by: Alex Smith <alex.smith@imgtec.com> Cc: Sadegh Abbasi <Sadegh.Abbasi@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/10808/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'crypto/camellia_generic.c')
0 files changed, 0 insertions, 0 deletions