diff options
author | Christoph Hellwig <hch@lst.de> | 2018-06-15 13:08:51 +0200 |
---|---|---|
committer | Paul Burton <paul.burton@mips.com> | 2018-06-24 09:27:27 -0700 |
commit | faef87723ace12e5f685437c1e68cbecb69a7a89 (patch) | |
tree | 98429f9c5bb8960e95fe7063c0c5017dc98c518e /include/linux/dma-noncoherent.h | |
parent | c5e2bbb45d28d53d278f25068142a283a0a74f7a (diff) | |
download | linux-stable-faef87723ace12e5f685437c1e68cbecb69a7a89.tar.gz linux-stable-faef87723ace12e5f685437c1e68cbecb69a7a89.tar.bz2 linux-stable-faef87723ace12e5f685437c1e68cbecb69a7a89.zip |
dma-noncoherent: add a arch_sync_dma_for_cpu_all hook
The MIPS bmips platform needs a global flush when transferring ownership
back to the CPU. Add a hook for that to the dma-noncoherent
implementation.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Patchwork: https://patchwork.linux-mips.org/patch/19549/
Signed-off-by: Paul Burton <paul.burton@mips.com>
Cc: Florian Fainelli <f.fainelli@gmail.com>
Cc: David Daney <david.daney@cavium.com>
Cc: Kevin Cernekee <cernekee@gmail.com>
Cc: Jiaxun Yang <jiaxun.yang@flygoat.com>
Cc: Tom Bogendoerfer <tsbogend@alpha.franken.de>
Cc: Huacai Chen <chenhc@lemote.com>
Cc: iommu@lists.linux-foundation.org
Cc: linux-mips@linux-mips.org
Diffstat (limited to 'include/linux/dma-noncoherent.h')
-rw-r--r-- | include/linux/dma-noncoherent.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/include/linux/dma-noncoherent.h b/include/linux/dma-noncoherent.h index 10b2654d549b..a0aa00cc909d 100644 --- a/include/linux/dma-noncoherent.h +++ b/include/linux/dma-noncoherent.h @@ -44,4 +44,12 @@ static inline void arch_sync_dma_for_cpu(struct device *dev, } #endif /* ARCH_HAS_SYNC_DMA_FOR_CPU */ +#ifdef CONFIG_ARCH_HAS_SYNC_DMA_FOR_CPU_ALL +void arch_sync_dma_for_cpu_all(struct device *dev); +#else +static inline void arch_sync_dma_for_cpu_all(struct device *dev) +{ +} +#endif /* CONFIG_ARCH_HAS_SYNC_DMA_FOR_CPU_ALL */ + #endif /* _LINUX_DMA_NONCOHERENT_H */ |