sdm660: adsprpc: Map uncached buffers as non-coherent

Map un-cached buffers as non io-coherent to avoid snooping overhead.

Change-Id: Iddbde76d6d8a13cd48c737f1046a53a2bc1ef2a5
Acked-by: Viswanatham Paduchuri <vpaduchu@qti.qualcomm.com>
Signed-off-by: Tharun Kumar Merugu <mtharu@codeaurora.org>
This commit is contained in:
c_mtharu 2017-06-09 14:53:48 +05:30 committed by Gerrit - the friendly Code Review server
parent c1a2472056
commit 71733cb184

View file

@ -670,7 +670,8 @@ static int fastrpc_mmap_create(struct fastrpc_file *fl, int fd, unsigned attr,
init_dma_attrs(&attrs);
dma_set_attr(DMA_ATTR_EXEC_MAPPING, &attrs);
if (map->attr & FASTRPC_ATTR_NON_COHERENT)
if ((map->attr & FASTRPC_ATTR_NON_COHERENT) ||
(sess->smmu.coherent && map->uncached))
dma_set_attr(DMA_ATTR_FORCE_NON_COHERENT,
&attrs);
else if (map->attr & FASTRPC_ATTR_COHERENT)