提交 9b43fb6b 编写于 作者: T Thomas Bogendoerfer 提交者: Ralf Baechle

[MIPS] Fix dma_sync_*_for_device() functions

Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
上级 40139bd4
......@@ -246,10 +246,10 @@ void dma_sync_single_for_device(struct device *dev, dma_addr_t dma_handle,
{
BUG_ON(direction == DMA_NONE);
if (cpu_is_noncoherent_r10000(dev)) {
if (!plat_device_is_coherent(dev)) {
unsigned long addr;
addr = plat_dma_addr_to_phys(dma_handle);
addr = PAGE_OFFSET + plat_dma_addr_to_phys(dma_handle);
__dma_sync(addr, size, direction);
}
}
......@@ -276,7 +276,7 @@ void dma_sync_single_range_for_device(struct device *dev, dma_addr_t dma_handle,
{
BUG_ON(direction == DMA_NONE);
if (cpu_is_noncoherent_r10000(dev)) {
if (!plat_device_is_coherent(dev)) {
unsigned long addr;
addr = PAGE_OFFSET + plat_dma_addr_to_phys(dma_handle);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册