mirror of
https://github.com/torvalds/linux.git
synced 2024-12-25 20:32:22 +00:00
33f2ac5451
Split the common dma.c which shared by Loongson-2E and Loongson-2F, since the code in 'common' directory is assumed be shared by all 64bit Loongson platforms (but Loongson-3 doesn't use it now). By the way, Loongson-2E and Loongson-2F have already dropped 32bit kernel support, so CONFIG_64BIT isn't needed. Signed-off-by: Huacai Chen <chenhc@lemote.com> Signed-off-by: Paul Burton <paul.burton@mips.com> Patchwork: https://patchwork.linux-mips.org/patch/20302/ Cc: Ralf Baechle <ralf@linux-mips.org> Cc: James Hogan <jhogan@kernel.org> Cc: linux-mips@linux-mips.org Cc: Fuxin Zhang <zhangfx@lemote.com> Cc: Zhangjin Wu <wuzhangjin@gmail.com> Cc: Huacai Chen <chenhuacai@gmail.com>
13 lines
266 B
C
13 lines
266 B
C
// SPDX-License-Identifier: GPL-2.0
|
|
#include <linux/dma-direct.h>
|
|
|
|
dma_addr_t __phys_to_dma(struct device *dev, phys_addr_t paddr)
|
|
{
|
|
return paddr | 0x80000000;
|
|
}
|
|
|
|
phys_addr_t __dma_to_phys(struct device *dev, dma_addr_t dma_addr)
|
|
{
|
|
return dma_addr & 0x7fffffff;
|
|
}
|